Crash when trying to show a Workspace using a deleted Screen. #67004

Open
opened 2019-07-15 18:05:58 +02:00 by Bastien Montagne · 3 comments

If a Screen ID is deleted, and one then try to show a Worspace using it, Blender will crash.

Setting to low prio since deleting a Screen ID is not easy to do for end user currently (you'll have to use py console, e.g. bpy.data.batch_remove(ids=(bpy.data.screens- [x],))), but still, this is violating general design and expected sane behavior of ID handling.

Think solution should be either:

  • Deleting Screens IDs should be forbidden (not ideal, since it kind of breaks general ID design, but should be doable).
  • Deleting Screens IDs should also delete matching Workspace (not ideal either, there should not be that kind of relationships between IDs, but we already have similar things between objects and obdata...).
  • Or (probably the sanest thing to do) a Workspace should handle gracefully the case where it has no assigned Screen.
If a Screen ID is deleted, and one then try to show a Worspace using it, Blender will crash. Setting to low prio since deleting a Screen ID is not easy to do for end user currently (you'll have to use py console, e.g. `bpy.data.batch_remove(ids=(bpy.data.screens- [x],))`), but still, this is violating general design and expected sane behavior of ID handling. Think solution should be either: * Deleting Screens IDs should be forbidden (not ideal, since it kind of breaks general ID design, but should be doable). * Deleting Screens IDs should also delete matching Workspace (not ideal either, there should not be that kind of relationships between IDs, but we already have similar things between objects and obdata...). * Or (probably the sanest thing to do) a Workspace should handle gracefully the case where it has no assigned Screen.
Author
Owner

Added subscribers: @mont29, @brecht, @dfelinto, @ideasman42

Added subscribers: @mont29, @brecht, @dfelinto, @ideasman42
Member

Added subscribers: @WilliamReynish, @JulianEisel

Added subscribers: @WilliamReynish, @JulianEisel
Member

As a user I would expect an error message in this case, informing me that a screen is still referenced by some workspace. It could allow deleting that workspace too, but I guess it's better to just show the workspace name in the error message and let the user delete it manually if wanted.

Personally I don't think it's a big deal to violate the general ID design for Screens, simply because I see no good reason to keep them as IDs anymore. On a conceptual level their role was superseded by workspaces and they could "just" become regular workspace data by now (also see the WorkSpaceLayout wrapper). I see the workspace <-> screens relationship similar to the window-manager <-> windows one.
Obviously that is a bigger discussion to have.

As a user I would expect an error message in this case, informing me that a screen is still referenced by some workspace. It could allow deleting that workspace too, but I guess it's better to just show the workspace name in the error message and let the user delete it manually if wanted. Personally I don't think it's a big deal to violate the general ID design for Screens, simply because I see no good reason to keep them as IDs anymore. On a conceptual level their role was superseded by workspaces and they could "just" become regular workspace data by now (also see the `WorkSpaceLayout` wrapper). I see the workspace <-> screens relationship similar to the window-manager <-> windows one. Obviously that is a bigger discussion to have.
Philipp Oeser removed the
Interest
User Interface
label 2023-02-10 09:25:31 +01:00
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
2 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#67004
No description provided.