Kerim Borchaev (warkid)
User

Projects

User does not belong to any projects.

User Details

User Since
Dec 25 2016, 8:32 PM (73 w, 5 d)

Recent Activity

May 9 2017

Kerim Borchaev (warkid) created T51444: Python scripts executed from commandline don't have __main__ module's dict as their globals on Windows.
May 9 2017, 3:54 PM · BF Blender

Jan 21 2017

Kerim Borchaev (warkid) added a comment to T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.

Seems like ANY python thread might crash when RENDERED is being turned off. In my test I've simply added an operator that spawns a thread. Not using a renderengine callback(callbacks are empty). It crashes.

Just execute the 'Test Start Thread' operator and start pressing Shift-Z(using Test engine or Blender doesn't matter) - it crashes after a few iterations.

Jan 21 2017, 10:00 PM · Python, BF Blender

Jan 17 2017

Kerim Borchaev (warkid) added a comment to T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.
I *think* the issue here is that renderengine callabacks can be called from a job, i.e. from non-main Blender thread, if that’s the case those callbacks should definitively *never* use any python threading.
Jan 17 2017, 12:09 AM · Python, BF Blender

Jan 16 2017

Kerim Borchaev (warkid) added a comment to T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.

Yes, I'm aware that Blender context should not be used in a thread. But my examples I think are completely avoiding it. If I'm not mistaken ;)

Jan 16 2017, 8:34 PM · Python, BF Blender
Kerim Borchaev (warkid) added a comment to T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.

Is there a possible workaround? Does addon code have any chance to shutdown it's threads before shading mode is toggled? Or defer the toggle so it doesn't happens immediately when Shift-Z is pressed?

Jan 16 2017, 4:51 PM · Python, BF Blender
Kerim Borchaev (warkid) added a comment to T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.

Looks like python threads are just doomed to crash when Shading mode is toggled. It's not just about sleep/wait.
E.g. replacing sleep(0) in the example code with simple with lock: pass makes it crash immediately on second Shift-Z.

Jan 16 2017, 3:38 PM · Python, BF Blender

Dec 27 2016

Kerim Borchaev (warkid) added a comment to T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.

Not sure what to do anyway, unless you can show us that Blender is responsible for that.

Dec 27 2016, 5:36 PM · Python, BF Blender

Dec 25 2016

Kerim Borchaev (warkid) created T50308: RenderEngine - use of python threads with sleep(0)/wait(0) crash.
Dec 25 2016, 8:47 PM · Python, BF Blender