Log In
New Account
Home My Page Projects Blender 2.x BF release
Summary Activity Tracker SCM Files

Blender 2.6 Bug Tracker: Browse

[#24805] bpy operator runs in wrong order or is ignored at all

Date:
2010-11-19 04:36
Priority:
3
State:
Closed
Submitted by:
Daniel Salazar (zanqdo)
Assigned to:
Campbell Barton (campbellbarton)
Category:
Python
Status:
Fixed / Closed
Relates to:
Duplicates:
Patches:
 
Summary:
bpy operator runs in wrong order or is ignored at all
Detailed description
Run script 01: results in selected curve's U resolution correctly changed to 12

Run script 02: results in selected curves converted to mesh

Run script 03: silently fails to do change resolution in the first loop and succeeds to convert to mesh in the second loop

Run script 04: attempts to change resolution and convert to mesh in the same loop but does it in the wrong order: first converts and later tries to change the U resolution thus failing

Followup

Message
  • Date: 2010-11-22 18:35
  • Sender: Daniel Salazar
  • Thanks Cam, script 03 now runs perfectly. However script 04 fails with:

    AttributeError: 'Mesh' object has no attribute 'resolution_u'

    is that normal?
  • Date: 2010-11-22 22:37
  • Sender: Campbell Barton
  • what happens os the conversion operator runs on all selected objects, not just the active.
    so your script assumes the only one is converted when they all are.
    For this to work as you expect youll need to de-select, then re-select 1 by 1.
 

Attached Files:

Name Date Download
CurveAPI.blend 2010-11-19 04:36 Download

Changes:

Field Old Value Date By
close_date2010-11-22 23:032010-11-22 23:03zanqdo
ResolutionNone2010-11-22 22:37campbellbarton
close_date2010-11-22 22:372010-11-22 22:37campbellbarton
status_idOpen2010-11-22 22:37campbellbarton
File Added13677: CurveAPI.blend2010-11-19 04:36zanqdo