Disallow duplicate regulators #60
Labels
No labels
bug
design
duplicate
enhancement
maintenance
prospective
question
todo
ui
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Depends on
#55 Introduce curvature regulators
StudioInfinity/dyna3
Reference: StudioInfinity/dyna3#60
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
As of pull request #46, it's possible to add two regulators of the same kind with the same subjects. For the kinds of regulators we're currently envisioning, duplication isn't useful, and it can lead to surprising or annoying behavior when duplicate regulators have conflicting set points. We should prevent duplicate regulators from being created.
If we become confident that we'll never want duplicate regulators of any kind, we might consider storing regulators in a hash map, using each regulator's kind and subjects as its key. The prohibition of duplicate regulators would then be built into the data structure. Whether this is a good idea might depend on how we address issue #55.
@Vectornaut wrote in glen/dyna3#60 (comment):
It's my expectation that we won't ever want duplicates. But if you want to wait to address this issue until after we resolve #55, go ahead and set the dependencies however represents that. Not 100% sure if you make this dependent on #55 or vice versa, but I think the former.