freestyle crashes blender #44404

Closed
opened 2015-04-15 20:25:08 +02:00 by Daniel Grauer · 21 comments
Member

System Information
OS: windows 8 64bit
GPU: nvidia gtx 860m

Blender Version
Broken: official 2.74
Worked: (optional)

Short description of error
when rendering a animation with freestyle and "line set" options enabled blender crashes

Exact steps for others to reproduce the error
Based on a (as simple as possible) attached .blend file with minimum amount of steps

1.open the blend file test01.blend
2. make sure freestyle is enabled
3. render the animation a couple of times (till blender crashes)

# Blender 2.74 (sub 4), Commit date: 2015-04-10 18:20, Hash 465a5d2

# backtrace
27: PyInit_mathutils_noise_types - 0xC22CE050
26: fftw_assertion_failed - 0xC1CD27F0
25: fftw_assertion_failed - 0xC1CD27F0
24: UnhandledExceptionFilter - 0x62A01AD0
23: memset - 0x65694D00
22: _C_specific_handler - 0x656823C0
21: _chkstk - 0x65693A30
20: RtlRaiseException - 0x656574A0
19: KiUserExceptionDispatcher - 0x65692C20
18: PyMapping_Length - 0x77C12B80
17: PyMapping_Length - 0x77C12B80
16: fftw_assertion_failed - 0xC1CD27F0
15: PyInit_mathutils_noise_types - 0xC22CE050
14: PyInit_mathutils_noise_types - 0xC22CE050
13: PyInit_mathutils_noise_types - 0xC22CE050
12: fftw_assertion_failed - 0xC1CD27F0
11: fftw_assertion_failed - 0xC1CD27F0
10: fftw_assertion_failed - 0xC1CD27F0
9: fftw_assertion_failed - 0xC1CD27F0
8: fftw_assertion_failed - 0xC1CD27F0
7: fftw_assertion_failed - 0xC1CD27F0
6: fftw_assertion_failed - 0xC1CD27F0
5: fftw_assertion_failed - 0xC1CD27F0
4: sched_get_priority_max - 0x5F8412FD
3: sched_get_priority_max - 0x5F8412FD
2: sched_get_priority_max - 0x5F8412FD
1: BaseThreadInitThunk - 0x64B813B0
0: RtlUserThreadStart - 0x6566E920

there are also a couple of error messages when rendering when all "selection by" are disabled:
note that when these are disabled blender does not crash so i guess the crash is somehow caused by these options
pasted_file

Traceback (most recent call last):
  File "D:\SVN\Laser\blend\test01.blend\LineSet", line 1, in <module>
  File "D:\SVN\BlenderAddons\build\Blender_trunk_vs2013\bin\Release\2.74\scripts\freestyle\modules\parameter_editor.py",
 line 992, in process
    upred = AndUP1D(*selection_criteria)
  File "D:\SVN\BlenderAddons\build\Blender_trunk_vs2013\bin\Release\2.74\scripts\freestyle\modules\freestyle\predicates.
py", line 239, in __init__
    raise ValueError("Expected one or more UnaryPredicate1D, got ", len(predicates))
ValueError: ('Expected one or more UnaryPredicate1D, got ', 0)

location: <unknown location>:-1

location: <unknown location>:-1

Error

**System Information** OS: windows 8 64bit GPU: nvidia gtx 860m **Blender Version** Broken: official 2.74 Worked: (optional) **Short description of error** when rendering a animation with freestyle and "line set" options enabled blender crashes **Exact steps for others to reproduce the error** Based on a (as simple as possible) attached .blend file with minimum amount of steps 1.open the blend file [test01.blend](https://archive.blender.org/developer/F162453/test01.blend) 2. make sure freestyle is enabled 3. render the animation a couple of times (till blender crashes) ``` # Blender 2.74 (sub 4), Commit date: 2015-04-10 18:20, Hash 465a5d2 # backtrace 27: PyInit_mathutils_noise_types - 0xC22CE050 26: fftw_assertion_failed - 0xC1CD27F0 25: fftw_assertion_failed - 0xC1CD27F0 24: UnhandledExceptionFilter - 0x62A01AD0 23: memset - 0x65694D00 22: _C_specific_handler - 0x656823C0 21: _chkstk - 0x65693A30 20: RtlRaiseException - 0x656574A0 19: KiUserExceptionDispatcher - 0x65692C20 18: PyMapping_Length - 0x77C12B80 17: PyMapping_Length - 0x77C12B80 16: fftw_assertion_failed - 0xC1CD27F0 15: PyInit_mathutils_noise_types - 0xC22CE050 14: PyInit_mathutils_noise_types - 0xC22CE050 13: PyInit_mathutils_noise_types - 0xC22CE050 12: fftw_assertion_failed - 0xC1CD27F0 11: fftw_assertion_failed - 0xC1CD27F0 10: fftw_assertion_failed - 0xC1CD27F0 9: fftw_assertion_failed - 0xC1CD27F0 8: fftw_assertion_failed - 0xC1CD27F0 7: fftw_assertion_failed - 0xC1CD27F0 6: fftw_assertion_failed - 0xC1CD27F0 5: fftw_assertion_failed - 0xC1CD27F0 4: sched_get_priority_max - 0x5F8412FD 3: sched_get_priority_max - 0x5F8412FD 2: sched_get_priority_max - 0x5F8412FD 1: BaseThreadInitThunk - 0x64B813B0 0: RtlUserThreadStart - 0x6566E920 ``` there are also a couple of error messages when rendering when all "selection by" are disabled: note that when these are disabled blender does not crash so i guess the crash is somehow caused by these options ![pasted_file](https://archive.blender.org/developer/F162456/pasted_file) ``` Traceback (most recent call last): File "D:\SVN\Laser\blend\test01.blend\LineSet", line 1, in <module> File "D:\SVN\BlenderAddons\build\Blender_trunk_vs2013\bin\Release\2.74\scripts\freestyle\modules\parameter_editor.py", line 992, in process upred = AndUP1D(*selection_criteria) File "D:\SVN\BlenderAddons\build\Blender_trunk_vs2013\bin\Release\2.74\scripts\freestyle\modules\freestyle\predicates. py", line 239, in __init__ raise ValueError("Expected one or more UnaryPredicate1D, got ", len(predicates)) ValueError: ('Expected one or more UnaryPredicate1D, got ', 0) location: <unknown location>:-1 location: <unknown location>:-1 Error ```
Author
Member

Changed status to: 'Open'

Changed status to: 'Open'
Author
Member

Added subscriber: @DanielGrauer

Added subscriber: @DanielGrauer

Added subscriber: @mont29

Added subscriber: @mont29

Main issue (crash with weird BT) is not specific to Freestyle, we have other similar reports, will merge this one in it.

Main issue (crash with weird BT) is not specific to Freestyle, we have other similar reports, will merge this one in it.

Closed as duplicate of #44238

Closed as duplicate of #44238

Added subscriber: @Psy-Fi

Added subscriber: @Psy-Fi

I don't think merging is the correct thing to do, the backtrace does not work on release builds, and will display the exact same thing almost everywhere, regardless of the crash.

I don't think merging is the correct thing to do, the backtrace does not work on release builds, and will display the exact same thing almost everywhere, regardless of the crash.

Changed status from 'Duplicate' to: 'Open'

Changed status from 'Duplicate' to: 'Open'

Added subscriber: @kjym3

Added subscriber: @kjym3

Many thanks @Psy-Fi for the notes on incorrect backtrace on release builds. I guess I was one of many who got confused by a backtrace that apparently makes no sense. I could reproduce the reported bug by a RelWithDebInfo build within VS 2013 (the bug was not reproducible in a Debug build). Here is a backtrace from the debugger.

 	python34.dll!0000000063f1c583()	Unknown
 	python34.dll!0000000063edfd93()	Unknown
>	blender-app.exe!BPY_text_free_code(Text * text) Line 183	C

 	blender-app.exe!BKE_text_free(Text * text) Line 172	C
 	blender-app.exe!BKE_libblock_free_ex(Main * bmain, void * idv, bool do_id_user) Line 982	C
 	blender-app.exe!FRS_do_stroke_rendering(Render * re, SceneRenderLayer * srl, int render) Line 643	C++
 	blender-app.exe!add_freestyle(Render * re, int render) Line 2088	C
 	blender-app.exe!do_render_3d(Render * re) Line 1451	C
 	blender-app.exe!do_render_fields_blur_3d(Render * re) Line 1736	C
 	blender-app.exe!do_render_composite_fields_blur_3d(Render * re) Line 2396	C
 	blender-app.exe!do_render_all_options(Render * re) Line 2643	C
 	blender-app.exe!RE_BlenderAnim(Render * re, Main * bmain, Scene * scene, Object * camera_override, unsigned int lay_override, int sfra, int efra, int tfra) Line 3569	C
 	blender-app.exe!render_startjob(void * rjv, short * stop, short * do_update, float * progress) Line 599	C
 	blender-app.exe!do_job_thread(void * job_v) Line 329	C
 	pthreadVC2.dll!000007feee0e627b()	Unknown
 	pthreadVC2.dll!000007feee0e8eb7()	Unknown
 	pthreadVC2.dll!000007feee0e9102()	Unknown
 	[External Code]	

I still need to further investigate the cause of bug. There is something wrong in the layer of the Python API, but debug symbols are not available in the backtrace above, which makes it difficult to identify the reason of the crash.

Anyway I will reopen the issue as confirmed.

Many thanks @Psy-Fi for the notes on incorrect backtrace on release builds. I guess I was one of many who got confused by a backtrace that apparently makes no sense. I could reproduce the reported bug by a RelWithDebInfo build within VS 2013 (the bug was not reproducible in a Debug build). Here is a backtrace from the debugger. ``` python34.dll!0000000063f1c583() Unknown python34.dll!0000000063edfd93() Unknown > blender-app.exe!BPY_text_free_code(Text * text) Line 183 C blender-app.exe!BKE_text_free(Text * text) Line 172 C blender-app.exe!BKE_libblock_free_ex(Main * bmain, void * idv, bool do_id_user) Line 982 C blender-app.exe!FRS_do_stroke_rendering(Render * re, SceneRenderLayer * srl, int render) Line 643 C++ blender-app.exe!add_freestyle(Render * re, int render) Line 2088 C blender-app.exe!do_render_3d(Render * re) Line 1451 C blender-app.exe!do_render_fields_blur_3d(Render * re) Line 1736 C blender-app.exe!do_render_composite_fields_blur_3d(Render * re) Line 2396 C blender-app.exe!do_render_all_options(Render * re) Line 2643 C blender-app.exe!RE_BlenderAnim(Render * re, Main * bmain, Scene * scene, Object * camera_override, unsigned int lay_override, int sfra, int efra, int tfra) Line 3569 C blender-app.exe!render_startjob(void * rjv, short * stop, short * do_update, float * progress) Line 599 C blender-app.exe!do_job_thread(void * job_v) Line 329 C pthreadVC2.dll!000007feee0e627b() Unknown pthreadVC2.dll!000007feee0e8eb7() Unknown pthreadVC2.dll!000007feee0e9102() Unknown [External Code] ``` I still need to further investigate the cause of bug. There is something wrong in the layer of the Python API, but debug symbols are not available in the backtrace above, which makes it difficult to identify the reason of the crash. Anyway I will reopen the issue as confirmed.
Tamito Kajiyama was assigned by Sergey Sharybin 2015-04-21 10:51:03 +02:00

Added subscriber: @Sergey

Added subscriber: @Sergey

Added subscriber: @ideasman42

Added subscriber: @ideasman42

Looks like this is caused by freeing compiled Python objects in a thread.

Suggest not to use Text data at all. Just allocate a buffer and call BPY_string_exec instead.

Looks like this is caused by freeing compiled Python objects in a thread. Suggest not to use `Text` data at all. Just allocate a buffer and call `BPY_string_exec` instead.

Wow thanks Campbell for the advice. I will try the suggested fix asap.

Wow thanks Campbell for the advice. I will try the suggested fix asap.

This issue was referenced by 85ae4b87af

This issue was referenced by 85ae4b87afa80527a36d3bd3164a9df6544f0c3b

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'

Closed by commit 85ae4b87af.

Closed by commit 85ae4b87af.
Author
Member

was this fix done in a branch? i still get the crash with the latest build but now the crashlog contains no more information except this

# Blender 2.74 (sub 5), Commit date: 2015-04-28 19:36, Hash cbb6013

# backtrace
Crash backtrace not supported on release builds

im building now a debug version and hopefully get more information about the crash, but im not a coder so i might need some help to do so.

EDIT: looks like its comming from a contrib addon "render_auto_save.py"

but i got a crashlog from a debug build so maybe that points to other problem

# Blender 2.74 (sub 5), Commit date: 2015-04-28 20:08, Hash f9d23b8

# backtrace
19: BLI_system_backtrace - 0xAF4ABA30
18: blender_crash_handler_backtrace - 0xAE286960
17: blender_crash_handler - 0xAE2869B0
16: windows_exception_handler - 0xAE286C30
15: UnhandledExceptionFilter - 0x6C311AD0
14: memset - 0x6F0A5140
13: _C_specific_handler - 0x6F092800
12: _chkstk - 0x6F0A3E70
11: RtlRaiseException - 0x6F063920
10: KiUserExceptionDispatcher - 0x6F0A3060
9: mesh_build_data - 0xAEFA1FA0
8: makeDerivedMesh - 0xAEF99400
7: BKE_object_handle_update_ex - 0xAEF3AB70
6: scene_update_object_func - 0xAEE51AA0
5: task_scheduler_thread_run - 0xAF5074A0
4: sched_get_priority_max - 0x63CD12FD
3: sched_get_priority_max - 0x63CD12FD
2: sched_get_priority_max - 0x63CD12FD
1: BaseThreadInitThunk - 0x6CA913B0
0: RtlUserThreadStart - 0x6F025410

was this fix done in a branch? i still get the crash with the latest build but now the crashlog contains no more information except this ``` # Blender 2.74 (sub 5), Commit date: 2015-04-28 19:36, Hash cbb6013 # backtrace Crash backtrace not supported on release builds ``` im building now a debug version and hopefully get more information about the crash, but im not a coder so i might need some help to do so. EDIT: looks like its comming from a contrib addon "render_auto_save.py" but i got a crashlog from a debug build so maybe that points to other problem ``` # Blender 2.74 (sub 5), Commit date: 2015-04-28 20:08, Hash f9d23b8 # backtrace 19: BLI_system_backtrace - 0xAF4ABA30 18: blender_crash_handler_backtrace - 0xAE286960 17: blender_crash_handler - 0xAE2869B0 16: windows_exception_handler - 0xAE286C30 15: UnhandledExceptionFilter - 0x6C311AD0 14: memset - 0x6F0A5140 13: _C_specific_handler - 0x6F092800 12: _chkstk - 0x6F0A3E70 11: RtlRaiseException - 0x6F063920 10: KiUserExceptionDispatcher - 0x6F0A3060 9: mesh_build_data - 0xAEFA1FA0 8: makeDerivedMesh - 0xAEF99400 7: BKE_object_handle_update_ex - 0xAEF3AB70 6: scene_update_object_func - 0xAEE51AA0 5: task_scheduler_thread_run - 0xAF5074A0 4: sched_get_priority_max - 0x63CD12FD 3: sched_get_priority_max - 0x63CD12FD 2: sched_get_priority_max - 0x63CD12FD 1: BaseThreadInitThunk - 0x6CA913B0 0: RtlUserThreadStart - 0x6F025410 ```

@DanielGrauer, it is likely to be a race condition between threads, so ideally we need to have backtrace of all threads. Any chance you can get those from IDE?

Also, did i understand correct that disabling autosave addon solves the crashes?

@DanielGrauer, it is likely to be a race condition between threads, so ideally we need to have backtrace of all threads. Any chance you can get those from IDE? Also, did i understand correct that disabling autosave addon solves the crashes?
Author
Member

@Sergey, can you tell me what i need to do to get the backtrace from IDE?
and yes if i disable the austosave then i can not get it to crash (at least in the ~30-40 times i tried)

@Sergey, can you tell me what i need to do to get the backtrace from IDE? and yes if i disable the austosave then i can not get it to crash (at least in the ~30-40 times i tried)

@DanielGrauer, not from a top of my head. Would probably be simplier to me to compile debug build and try to reproduce it first.

Also, it seems to be separate issue, so do you mind firing a new bug report and assigning to me?

@DanielGrauer, not from a top of my head. Would probably be simplier to me to compile debug build and try to reproduce it first. Also, it seems to be separate issue, so do you mind firing a new bug report and assigning to me?
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
7 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#44404
No description provided.