You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When adding constraints (m.backend.add_constraint) that do not apply anywhere because of the where, the backend is left in an inconsistent state:
The constraint does not appear in m.backend.constraints. But when you try to add a new version of the constraint with the same name, you will be notified that the constraint already exists. That's because it remains in the pyomo list created in _add_constraint_or_expression.
This list should be deleted if the constraint (/other optimisation problem element) does not apply anywhere.
Steps to reproduce the problem
Add a constraint with a where string does not apply anywhere.
Calliope version
v0.7dev
The text was updated successfully, but these errors were encountered:
Problem description
When adding constraints (m.backend.add_constraint) that do not apply anywhere because of the where, the backend is left in an inconsistent state:
The constraint does not appear in m.backend.constraints. But when you try to add a new version of the constraint with the same name, you will be notified that the constraint already exists. That's because it remains in the pyomo list created in _add_constraint_or_expression.
This list should be deleted if the constraint (/other optimisation problem element) does not apply anywhere.
Steps to reproduce the problem
Add a constraint with a where string does not apply anywhere.
Calliope version
v0.7dev
The text was updated successfully, but these errors were encountered: