-
Notifications
You must be signed in to change notification settings - Fork 622
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
Disabled procedure blocks are re-enabled after a change #2035
Comments
@johnnesky any interest in looking at this one next? |
Sure! |
Intended behavior: When core procedures are disabled, the enabled state of call blocks is recorded and the call blocks are forcibly disabled. When core procedures are enabled, call blocks are restored to their recorded state. (This recorded state is not serialized so this breaks on reload but that's not the problem being tracked here.) Bug: In the shareable procedure plugin, whenever any change is made to the procedure, the above actions are executed depending on whether the procedure is currently enabled, but if the procedure remains in the enabled state, then the call block will be "restored" to a state that was never properly recorded in the first place. We only really want to execute these actions when there is an actual change to the value of the enabled state of the procedure definition, rather than when there is any change to the definition. Currently looking for a solution. |
Hi, I'm not sure if it is 100% related, but when you serialize and then deserialize a disabled procedure block, it gets automatically re-enabled. |
google/blockly#7958 has been merged into blockly. When blockly v11.0.0 is published, then this procedure plugin can be updated to use the same system. |
@johnnesky if you want to fix this next, you can work off the rc/v11 branch of samples and submit the fix there. You can locally link blockly for testing and submit the change to that branch. When we release v11 of core we'll also release that branch so the fix can be published asap. |
With the migration to the new exports format in the package.json I've found linking to be a bit weird. The steps I've found to work are:
|
Check for duplicates
Component
plugins/block-shareable-procedures
Description
If a user disables procedure call blocks, they'll be re-enabled automatically when the matching definition block is modified (e.g. renamed or parameters added). This is undesirable.
Reproduction steps
Stack trace
No response
Screenshots
Oct-25-2023.11-40-18.mp4
The text was updated successfully, but these errors were encountered: