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

Ensure that status message is included on status line #69

Merged
merged 2 commits into from
Jan 12, 2024

Conversation

pdw-mb
Copy link

@pdw-mb pdw-mb commented Jan 26, 2023

This fixes a bug where all API errors would result in an internal server error under Apache's mod_wsgi.

The code currently returns a status line consisting of just the numeric code, i.e. 400 rather than 400 BAD REQUEST. This results in an error of ValueError: no space following status code from mod_wsgi.

This PR fixes this by casting the status to an integer if it is just an integer, which prompts Flask to fill in the rest of the status line.

Copy link
Collaborator

@mahenzon mahenzon left a comment

Choose a reason for hiding this comment

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

looks good

@roman-adcombo roman-adcombo merged commit 3cfff98 into AdCombo:master Jan 12, 2024
@boyarzun
Copy link

@roman-adcombo Will you lunch a new release with these changes? When I run pip install I'm not getting the last changes 🤔

@VerusK
Copy link

VerusK commented May 17, 2024

@roman-adcombo Will you lunch a new release with these changes? When I run pip install I'm not getting the last changes 🤔

sure, we need to fix deploy :)

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

Successfully merging this pull request may close these issues.

5 participants