Delayed persistant write for use of persist=True
CachedBLProperty
in write-restricted hot-paths #16
Labels
No Label
abstractions
architecture
bug
distribution
docs
duplicate
enhancement
feature
physical
proposal
question
simulation
tooling
tracker
unconfirmed
ux
wontfix
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: so-rose/oscillode#16
Loading…
Reference in New Issue
There is no content yet.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may exist for a short time before cleaning up, in most cases it CANNOT be undone. Continue?
In Blender, one generally cannot write to
bpy.types.Property
inside of particular "write-restricted" hot-paths. This isn't a bad thing; it protects from nuanced thread-related bugs.Unfortunately, we structure our
CachedBLProperty
code such that persistance caching happens in__get__
.Practically, this means that any property we want to be able to access from a
draw()
method cannot be persisted. This is rather unfortunate, but so far, not really a deal breaker. It would be a very nice breath of fresh air to get it fixed, though; finally make peace with the mass-recomputation-on-startup that challenges so many assumptions at once (some of which may, in valid ways, not quite still be the same as when they were saved).Some ideas could include:
__set__
: This presupposes that absolutely no write happens without going through__set__
. This may be harder than at first glance.