Workspace shading.type crash #58756

Closed
opened 2018-12-05 00:53:41 +01:00 by David Webb · 5 comments

System Information
Operating system: Windows 10
Graphics card: GTX 1080

Blender Version
2.80.35

Short description of error
Switching shading.type of an inactive workspace VIEW_3D crashes blender.

Exact steps for others to reproduce the error
Change 'my_workspace' to an active workspace name and run (works as expected and changes to wireframe),
then change 'my_workspace' to an inactive workspace name and run (crash occurs here).

  for area in bpy.data.workspaces['my_workspace'].screens[0].areas:
      if area.type == 'VIEW_3D':
          for spaces in area.spaces:
              if spaces.type == 'VIEW_3D':
                  spaces.shading.type = 'WIREFRAME'
**System Information** Operating system: Windows 10 Graphics card: GTX 1080 **Blender Version** 2.80.35 **Short description of error** Switching shading.type of an inactive workspace VIEW_3D crashes blender. **Exact steps for others to reproduce the error** Change 'my_workspace' to an active workspace name and run (works as expected and changes to wireframe), then change 'my_workspace' to an inactive workspace name and run (crash occurs here). ``` for area in bpy.data.workspaces['my_workspace'].screens[0].areas: if area.type == 'VIEW_3D': for spaces in area.spaces: if spaces.type == 'VIEW_3D': spaces.shading.type = 'WIREFRAME'
Author

Added subscriber: @Way2Close-2

Added subscriber: @Way2Close-2
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

Confirmed.

rna_3DViewShading_scene(ptr) returns NULL in rna_3DViewShading_type_itemf() in this case.

1   BLI_findstring               listbase.c        607  0x2eb3aca      
2   RE_engines_find              external_engine.c 116  0x22fbaa3      
3   rna_3DViewShading_type_itemf rna_space.c       749  0x2dee24e      
4   RNA_property_enum_items_ex   rna_access.c      1429 0x2c80be2      
5   RNA_property_enum_items      rna_access.c      1455 0x2c80d08      
6   RNA_property_enum_value      rna_access.c      1586 0x2c812fe      
7   pyrna_string_to_enum         bpy_rna.c         1206 0x2325c48      
8   pyrna_py_to_prop             bpy_rna.c         1839 0x232747d      
9   pyrna_struct_setattro        bpy_rna.c         4324 0x232d285      
10  PyObject_SetAttr                                    0x7ffff7a2dc38 
11  _PyEval_EvalFrameDefault                            0x7ffff7a351af 
12  _PyEval_EvalCodeWithName                            0x7ffff797d138 
13  PyEval_EvalCodeEx                                   0x7ffff797dfe3 
14  PyEval_EvalCode                                     0x7ffff797e00b 
15  python_script_exec           bpy_interface.c   475  0x2322113     
Confirmed. `rna_3DViewShading_scene(ptr) `returns NULL in `rna_3DViewShading_type_itemf()` in this case. ``` 1 BLI_findstring listbase.c 607 0x2eb3aca 2 RE_engines_find external_engine.c 116 0x22fbaa3 3 rna_3DViewShading_type_itemf rna_space.c 749 0x2dee24e 4 RNA_property_enum_items_ex rna_access.c 1429 0x2c80be2 5 RNA_property_enum_items rna_access.c 1455 0x2c80d08 6 RNA_property_enum_value rna_access.c 1586 0x2c812fe 7 pyrna_string_to_enum bpy_rna.c 1206 0x2325c48 8 pyrna_py_to_prop bpy_rna.c 1839 0x232747d 9 pyrna_struct_setattro bpy_rna.c 4324 0x232d285 10 PyObject_SetAttr 0x7ffff7a2dc38 11 _PyEval_EvalFrameDefault 0x7ffff7a351af 12 _PyEval_EvalCodeWithName 0x7ffff797d138 13 PyEval_EvalCodeEx 0x7ffff797dfe3 14 PyEval_EvalCode 0x7ffff797e00b 15 python_script_exec bpy_interface.c 475 0x2322113 ```

This issue was referenced by be359fc6e5

This issue was referenced by be359fc6e51a98143961cb01901761d059aaacfd

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
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
4 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#58756
No description provided.