-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix all code that is using creatability as a proxy for persistability #4323
Labels
Milestone
Comments
This was referenced Feb 25, 2022
Testing
|
able edit properties for plans inside a Viper Plans and use another plan json. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Summary
Some of our code is using the
creatable
property of object types to determine whether an object can be persisted. Creatability and persistability are two different things. Thecreatable
property only tells you whether or not an object type appears in the Create menu and nothing else. An overlay plot can be created from the Create menu, but it can also be exposed as static JSON in the tree. Using creatability to determine whether the object can be persisted in this case will give a false impression, and will result in persistence errors if any mutation or persistence is attempted.We need to search our code base for instances where the .creatable attribute is being used to determine persistability, and replace it with a call to
openmct.object.isPersistable(domainObject)
.Here is an example of an instance where creatability is being used instead of persistability:
#4149 (comment)
This is of fairly marginal impact right now, but it will soon become critical when we start building change-controlled display layouts and exposing them as non-editable objects in the tree.
Impact Check List
The text was updated successfully, but these errors were encountered: