Maniphest T73446

Save ID-Properties for WorkSpaces
Closed, ResolvedDESIGN

Assigned To
Campbell Barton (campbellbarton)
Authored By
michal.wallace@gmail.com (tangentstorm)
Jan 28 2020, 3:04 AM
Tags
  • BF Blender
Subscribers
Bastien Montagne (mont29)
Campbell Barton (campbellbarton)
dupoxy (dupoxy)
Jacques Lucke (JacquesLucke)
Julian Eisel (Severin)
Kai Jægersen (kaio)
michal.wallace@gmail.com (tangentstorm)

Description

System Information
Operating system: windows 10
Graphics card: nvidia geforce

Blender Version
Broken: v 2.81a

Short description of error

The python API docs claim that custom properties will be saved with the blend file, but this does not appear to be the case for custom properties defined on workspace objects.

https://docs.blender.org/api/blender_python_api_current/info_quickstart.html#custom-properties

Exact steps for others to reproduce the error

from default startup (new general file),
open the active tool and workspace settings panel (screwdriver and wrench icon)
open the workspaces sub-panel
add any custom property
save the file
close and re-open it.
(the custom property won't be there)

Revisions and Commits

rB Blender

Related Objects

Event Timeline

michal.wallace@gmail.com (tangentstorm) created this task.Jan 28 2020, 3:04 AM
michal.wallace@gmail.com (tangentstorm) updated the task description.
michal.wallace@gmail.com (tangentstorm) added a subscriber: Kai Jægersen (kaio).Jan 28 2020, 3:11 AM

@Kai Jægersen (kaio) mentioned on https://devtalk.blender.org/t/scene-per-tab-event-handler-for-tab-switching/11517/6 that workspace and window settings are runtime-only... If that's the case, then I suppose this is a documentation bug... But if that's the case, why even expose a UI for workspace custom properties?

Jacques Lucke (JacquesLucke) added subscribers: Julian Eisel (Severin), Jacques Lucke (JacquesLucke).Jan 28 2020, 9:52 AM

I'm not sure how workspaces are implemented exactly. @Julian Eisel (Severin) might know more about workspaces are stored.

Campbell Barton (campbellbarton) renamed this task from workspace custom properties are not saved to Save ID-Properties for WorkSpaces.Jan 28 2020, 10:55 AM
Campbell Barton (campbellbarton) triaged this task as Low priority.
Campbell Barton (campbellbarton) changed the subtype of this task from "Report" to "Design".
Campbell Barton (campbellbarton) mentioned this in T63728: Data, Assets & I/O Module.
Campbell Barton (campbellbarton) added subscribers: Bastien Montagne (mont29), Campbell Barton (campbellbarton).Jan 28 2020, 11:03 AM

As far as I can see this can be supported, as with other windowing data, undo doesn't track this so STRUCT_NO_DATABLOCK_IDPROPERTIES would need to be set.

As long as there aren't any complications think this is OK to add.
Pinging @Bastien Montagne (mont29) for a second opinion.

Bastien Montagne (mont29) added a comment.Jan 29 2020, 3:59 PM

Am not sure why STRUCT_NO_DATABLOCK_IDPROPERTIES should be used? AFAIK this is used to actually forbid custom props on a structure that does have idprops storage? Screen ID does not have that at least…

In fact am not sure why customprops on WS are not saved, afaict only WM are explicitly excluded from that in write_iddata(). Screens and WorkSpaces should be written as any other ID (although indeed there would be no undo supported for those two).

dupoxy (dupoxy) added a subscriber: dupoxy (dupoxy).Jan 29 2020, 5:35 PM
Campbell Barton (campbellbarton) closed this task as Resolved by committing rBcc6defa24456: Fix T73446: WorkSpace ID properties not saved.Feb 12 2020, 8:20 AM
Campbell Barton (campbellbarton) claimed this task.
Campbell Barton (campbellbarton) added a commit: rBcc6defa24456: Fix T73446: WorkSpace ID properties not saved.