Description
PinStore.TrySet supports both creating a new pin and replacing an existing pin with the same name. This behavior is useful, but the current user feedback can make both cases look identical.
If a user pins a different object as player, existing Watch expressions using player immediately start resolving against the new object. That is correct, but it can be surprising if the UI only says "Pinned as player."
Why
Pin overwrites are a meaningful state change. A small wording difference helps users understand why watch values changed after pinning.
Suggested Fix
Make the pin set flow distinguish between create and update.
Possible API shape:
- Add
PinStore.Has(name) check before TrySet.
- Or have
TrySet return an enum/result indicating Created vs Updated.
Suggested output messages:
- New pin:
Pinned as player — reference it in Code / Watch as player.
- Existing pin updated:
Updated pin player — Code / Watch now resolve player to this value.
No confirmation dialog is required unless future feedback suggests accidental overwrites are common.
Acceptance Criteria
Description
PinStore.TrySetsupports both creating a new pin and replacing an existing pin with the same name. This behavior is useful, but the current user feedback can make both cases look identical.If a user pins a different object as
player, existing Watch expressions usingplayerimmediately start resolving against the new object. That is correct, but it can be surprising if the UI only says "Pinned as player."Why
Pin overwrites are a meaningful state change. A small wording difference helps users understand why watch values changed after pinning.
Suggested Fix
Make the pin set flow distinguish between create and update.
Possible API shape:
PinStore.Has(name)check beforeTrySet.TrySetreturn an enum/result indicatingCreatedvsUpdated.Suggested output messages:
Pinned as player — reference it in Code / Watch as player.Updated pin player — Code / Watch now resolve player to this value.No confirmation dialog is required unless future feedback suggests accidental overwrites are common.
Acceptance Criteria