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

If you aren't using classes for view_funcs, you can't tell Flask not to serve OPTIONS #1488

Closed
jrmccarthy opened this issue Jun 8, 2015 · 0 comments

Comments

@jrmccarthy
Copy link

We're using flask to serve mostly REST endpoints, and doing some setup at startup to create all the URL rules. Effectively, we're calling app.add_url_rule() for each method for each endpoint. This means that flask autogenerates an OPTIONS method and function for each ( https://github.com/mitsuhiko/flask/blob/master/flask/app.py#L1019 ), with no way to override.

Can provide_automatic_options be added as a kwarg to add_url_rule, in case nothing is specified on the view_func?

@jrmccarthy jrmccarthy changed the title If you aren't using classes for view_funcs, you can't tell If you aren't using classes for view_funcs, you can't tell Flask not to serve OPTIONS Jun 8, 2015
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 14, 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 a pull request may close this issue.

2 participants