Commit Graph

27 Commits

Author SHA1 Message Date
João Santos
44ea9336fe Connexion 2.0 (#619)
- App and Api options must be provided through the "options" argument (``old_style_options`` have been removed).
- You must specify a form content-type in 'consumes' in order to consume form data.
- The `Operation` interface has been formalized in the `AbstractOperation` class.
- The `Operation` class has been renamed to `Swagger2Operation`.
- Array parameter deserialization now follows the Swagger 2.0 spec more closely.
  In situations when a query parameter is passed multiple times, and the collectionFormat is either csv or pipes, the right-most value will be used.
  For example, `?q=1,2,3&q=4,5,6` will result in `q = [4, 5, 6]`.
  The old behavior is available by setting the collectionFormat to `multi`, or by importing `decorators.uri_parsing.AlwaysMultiURIParser` and passing `parser_class=AlwaysMultiURIParser` to your Api.
- The spec validator library has changed from `swagger-spec-validator` to `openapi-spec-validator`.
- Errors that previously raised `SwaggerValidationError` now raise the `InvalidSpecification` exception.
  All spec validation errors should be wrapped with `InvalidSpecification`.
- Support for nullable/x-nullable, readOnly and writeOnly/x-writeOnly has been added to the standard json schema validator.
- Custom validators can now be specified on api level (instead of app level).
- Added support for basic authentication and apikey authentication
- If unsupported security requirements are defined or ``x-tokenInfoFunc``/``x-tokenInfoUrl`` is missing, connexion now denies requests instead of allowing access without security-check.
- Accessing ``connexion.request.user`` / ``flask.request.user`` is no longer supported, use ``connexion.context['user']`` instead
2018-11-05 14:50:42 +01:00
Rafael Carício
1858c9d4a0 Flask required only if necessary (#424)
* Example with Flask support

* Only show import error when trying to use Flask

* Re-organize imports

* Move flask_utils next to related module

* Code style

* Change back to incentivizes

* Includes Flask by default

* Project clean up

* Update Rafael Caricio's e-mail address

* Fix conflicts
2017-04-04 20:48:08 +02:00
Diogo Dutra
3952ea2771 did changes requested by isort and flake8 2017-04-04 08:20:25 -03:00
Diogo Dutra
7c87126fc8 uncouple flask utils functions from utils module 2017-04-04 08:20:24 -03:00
Diogo Dutra
a7af62fbf0 Uncouple flask from App and Api. Created Abstract classes for theses modules. Fixed the tests 2017-04-04 08:20:23 -03:00
Patrick Williams
6eb5a6e969 Support the flask url variable converter "path" 2017-01-07 10:02:44 -05:00
Yoan Blanc
be437a980b Fix isort checks 2016-10-16 11:32:11 +02:00
Jens Finkhaeuser
e41f8c6d41 Add ability to add random string to endpoint names so that flask doesn't
complain about duplicate names.
2016-09-07 12:13:49 +02:00
David Hotham
851d04372e isort imports 2016-06-10 20:39:51 +01:00
João Santos
87afbfe6eb #218 Raise import errors on endpoint handling 2016-06-08 15:11:06 +02:00
Rafael Caricio
c30bdbb324 Fix import sorting in examples and tests 2016-04-08 14:33:27 +02:00
Rafael Caricio
a86b96c5e2 Sort imports in tests and examples 2016-04-08 14:33:27 +02:00
Rafael Caricio
6358c8c47d Adopt isort to ensure better code quality 2016-04-08 14:33:27 +02:00
Rafael Caricio
633dac8dd1 #127 handle boolean values 2016-02-01 17:11:37 +01:00
cyprien-g
41df524e61 Allow None value in boolean converter 2016-01-04 10:30:05 +01:00
cyprien-g
754c250f7e Case insensitive check for boolean validation 2015-12-28 16:18:49 +01:00
cyprien-g
811a226892 Allow True/False for query parameters 2015-12-28 14:02:02 +01:00
João Santos
6554de8dc3 #108 DRY and more cleanup 2015-12-10 16:01:15 +01:00
Henning Jacobs
0c56d1560b #104 support int/float path converter 2015-12-05 20:38:08 +01:00
Henning Jacobs
2c0c960a5d #101 add unit test to resolve static method 2015-12-05 19:06:48 +01:00
Henning Jacobs
f35dce3bd6 #48 validate integer, number and boolean query parameters 2015-08-26 18:35:57 +02:00
Henning Jacobs
5337df4601 add validation for "date" format 2015-07-31 19:52:28 +02:00
João Santos
69375f55cf Change datetime format validator to be compatible with python 2 2015-07-30 09:49:26 +02:00
Henning Jacobs
b0d481a7e8 fix missing time-secfrac 2015-07-23 18:42:09 +02:00
Henning Jacobs
99669024c5 fix date-time parsing for strings without milliseconds 2015-07-23 17:47:10 +02:00
Henning Jacobs
476cbe1a35 support paths with hyphen 2015-07-17 09:36:04 +02:00
João Santos
b40295aa48 https://github.com/zalando/connexion/issues/6 Test utils 2015-06-13 11:27:44 +02:00