Skip to content

Duplicating blocks with shadows keep the same shadow id #926

@paulkaplan

Description

@paulkaplan

When you create two of the same block by dragging them out of the toolbox twice, you get different IDs for all the blocks (including the shadow)

different-ids

However, when you right-click and duplicate, you get a block with a different ID but the shadow has the same ID.

same-id

This is causing a bug in scratch-vm scratchfoundation/scratch-vm#589 because the vm-side block cache can be fooled by blocks with the same IDs (specifically, if you delete one of them and then try to read out the block XML, you get an error).

@rachel-fenichel is this a known / desired behavior?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions