Skip to content
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

Consider renaming solver.add_constraints and solver.add_costs #63

Closed
cmalinmayor opened this issue Nov 15, 2023 · 1 comment · Fixed by #108
Closed

Consider renaming solver.add_constraints and solver.add_costs #63

cmalinmayor opened this issue Nov 15, 2023 · 1 comment · Fixed by #108
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@cmalinmayor
Copy link
Contributor

The plural add_constraints implies that one can add multiple constraints, but it takes only one motile.Constraint. I understand that under the hood, it adds multiple ILP constraints, but from the user perspective, the function just adds one Constraint, and the function makes more sense to be called add_constraint. Same argument for add_costs.

Thoughts @funkey?

@cmalinmayor cmalinmayor added the enhancement New feature or request label Feb 29, 2024
@cmalinmayor
Copy link
Contributor Author

Discussed with @funkey - decided to rename add_costs -> add_cost and add_constraints -> add_constraint. Also rename Costs base class to Cost. Breaking API change :( but okay because before version 1 still.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant