Add_group() + outliner = bugsplat
-
What would be best ? Leaving it like that with the risk that people will try deleting/purging layers with Outline opened, and inevitably get bugsplats. Or start the operation after
temp=gents.add_group()
, so there would be 2 more transactions in the undo stack for everyone ? -
Try this just to be sure:
def self.deleteLayer(layer, delete_geometry=false) # disable_ui = true @model.start_operation( "jbb Op test", disable_ui ) # SU ver 7+ # group=@model.entities.add_group() # cp1 = group.entities.add_cpoint(ORIGIN) # group.layer=nil gents=group.entities temp=gents.add_group() ### <- It bugsplats here # cp2 = temp.entities.add_cpoint(ORIGIN) # # some code... # temp.entities.erase_entities(cp2) group.entities.erase_entities(cp1) # @model.commit_operation end#def
-
@jiminy-billy-bob said:
What would be best ? Leaving it like that with the risk that people will try deleting/purging layers with Outline opened, ...
Best to always use the
**disable_ui**
arg set totrue
during the operation. -
**disable_ui**
works like a charm !Thanks a lot Dan !
-
I'm not able to reproduce this.
Can you provide a full working example, so I can hit run and it calls the method with the exact arguments you do?
Also, does it crash only under Windows? Or also OSX?
Does it crash only on SU2013, or also older versions?Even though you found a workaround I would like to find the cause of this crash.
-
Install my plugin, and try to purge/delete layers from the dialog while having outliner opened. You'll get a bugsplat.
Tested on win7, SU8/13. -
I can reproduce this.
-
Ok, so no need to PM you the old version ?
If you're trying to reproduce it within the plugin, change line 100 to@model.start_operation("Delete layer", false)
, and line 465 to@model.start_operation("Purge unused layers", false)
-
@tt_su said:
(Also, what did you do to avoid the crash?)
What Dan told me above : Disable UI during the operation.
-
Yea, I realized that after posting. I've logged a bug internally.
-
Great, thanks !
Advertisement