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

Refactor Accept.best_match and fix test #1020

Closed
wants to merge 2 commits into from

Conversation

xthezealot
Copy link

Accept.best_match is now simpler and more performant (less assignments and earlier return).

test_accept_matches has been fixed according to the doc:

If two items have the same quality, the one is returned that comes first.

@Felk
Copy link
Contributor

Felk commented Feb 17, 2017

This changes best_match in a way that requires the following sentence in the docstring to be removed.

If two items have the same quality, the one is returned that comes first.

Which would be fine in a sense that this promise seems arbitrary and doesn't serve any purpose except documenting an implementation detail.

@mitsuhiko
Copy link
Contributor

Merged #1065 instead.

@mitsuhiko mitsuhiko closed this Dec 30, 2017
@davidism davidism added this to the 0.14 milestone Jan 3, 2018
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants