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

Remove duplicate assigned HTTP Status codes #2017

Merged
merged 1 commit into from Apr 9, 2024

Conversation

153957
Copy link
Contributor

@153957 153957 commented Apr 4, 2024

What does this change

Remove duplicate entries from http_assigned_codes.

What was wrong

Two values appeared twice in the list skewing the probabilities and making the list harder to maintain.

How this fixes it

Removed duplicate entries.

Remark

Would it be acceptable to replace this hard coded list by values from the http.HTTPStatus enum included in the Python standard library? (I understand if this repo prefers hard coded lists)
Also; that enum has changed in recent Python version, Python 3.9 added 3 additional status codes, including 418 – IM A TEAPOT which is not part of the current list because it is considered Unused by the RFC.

@fcurella
Copy link
Collaborator

fcurella commented Apr 5, 2024

I'd rather have a static list, so our dataset doesn't change across Python versions.

Copy link
Collaborator

@fcurella fcurella left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! Could you rebase against the current master branch?

Copy link
Collaborator

@fcurella fcurella left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@fcurella fcurella merged commit 89e2069 into joke2k:master Apr 9, 2024
28 checks passed
@153957 153957 deleted the http-status-codes branch April 9, 2024 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants