44 Commits

Author SHA1 Message Date
Sebastián Ramírez 62af6e0eeb ✨ Separate Pydantic's ValidationError handler and improve docs for error handling (#273)
* ✨ Implement separated ValidationError handlers and custom exceptions

* ✅ Add tutorial source examples and tests

* 📝 Add docs for custom exception handlers

* 📝 Update docs section titles
2019-05-29 16:27:55 +04:00
Sebastián Ramírez 703ade7967 🐛 Fix path in path parameters (#272) 2019-05-29 13:34:46 +04:00
Sebastián Ramírez a49d45eaa9 🐛 Fix response_model type to allow List[Model] (#266) 2019-05-27 21:56:20 +04:00
Sebastián Ramírez 7b63bc5551 ✨ Add include, exclude, and by_alias to path operation methods (#264)
* ✨ Make jsonable_encoder's include and exclude receive sequences

* ✨ Add include, exclude, and by_alias to app and router

* ✨ Add and update tutorial code with new parameters

* 📝 Update docs for new parameters and add docs for updating data

* ✅ Add tests for consistency in path operation methods

* ✅ Add tests for new parameters and update tests
2019-05-27 16:08:13 +04:00
William Hayes d8716f94ae ✨ Add skip_defaults support for path operations (for #242) (#248) 2019-05-25 19:35:57 +04:00
James Kaplan b087246f26 ✨ Add support for WebSockets with dependencies, params, etc #166 (#178) 2019-05-24 20:41:41 +04:00
Sebastián Ramírez e92b43b5c8 ✨ Add parameter dependencies to path operation decorators and include_router (#235)
* ✨ Implement dependencies in decorator and .include_router

* 📝 Add docs for parameter dependencies

* ✅ Add tests for dependencies parameter

* 🔥 Remove debugging prints in tests

* 📝 Update release notes
2019-05-16 18:07:00 +04:00
Ricardo Momm b0b88f9d5b 🔊 Raise from previous exception (#195) 2019-05-15 14:50:58 +04:00
Derek J. Lambert 4a1648b04e ✏️ Minor spelling fix in routing (#221) 2019-05-14 22:04:18 +04:00
Sebastián Ramírez 192ebba2a2 ♻️ Rename parameter content_type to response_class (#183) 2019-04-26 13:11:16 +04:00
Sebastián Ramírez 546d233dec ♻️ Update Pydantic usage, types, values, minor structure changes (#164) 2019-04-16 23:26:09 +04:00
Sebastián Ramírez 61dd36a945 ✨ Upgrade docstring Markdown parsing (#163)
* ✨ Upgrade docstring Markdown parsing

* 📝 Update release notes
2019-04-16 22:49:18 +04:00
Sebastián Ramírez aad6b123f7 ✨ Add support for multi-file uploads (#158) 2019-04-14 22:12:14 +04:00
Sebastián Ramírez c8df3ae57c 🐛 Fix handling additional responses in include_router (#140) 2019-04-05 20:06:40 +04:00
Sebastián Ramírez ad471307e2 ✨ Additional Responses (#97)
Add additional responses to OpenAPI, including Pydantic models or schemas directly, custom status codes, media types, extending `response_model`, etc.
2019-04-05 14:18:28 +04:00
Sebastián Ramírez 2bd775988f ✨ Add/refactor addditional responses, tests, docs 2019-04-05 13:54:00 +04:00
Sebastián Ramírez 9b04593260 ✨ Add support for BackgroundTasks parameters (#103)
* ✨ Add support for BackgroundTasks parameters

* 🐛 Fix type declaration in dependencies

* 🐛 Fix coverage of util in tests
2019-03-24 23:33:35 +04:00
euri10 6d77e2ac5f ✨ Add websocket to APIRouter (#100)
* Add websocket to APIRouter

* Restore upstream/master Pipfile.lock (git checkout upstream/master -- Pipfile.lock)

* Added tests for router with a prefix
2019-03-24 23:18:20 +04:00
Mohammed eda9b28338 files formatting 2019-03-23 13:10:45 +03:00
Mohammed 7514ac6fb0 100% test coverage 2019-03-23 13:01:53 +03:00
Mohammed 65568065e0 Remove extra code. 2019-03-23 00:47:32 +03:00
Mohammed 95679ca5e6 Fix: adding additional_responses on .include_router() 2019-03-23 00:37:10 +03:00
Mohammed 84a300ef84 Formatting according to guide 2019-03-22 22:54:48 +03:00
Mohammed c6d28c8209 Accept Multiple Additional Responses 2019-03-22 22:50:47 +03:00
Mohammed aa0bca7bb2 Additional Responses implementation 2019-03-22 22:40:07 +03:00
euri10 11c755bee3 ✨ Add tags parameter to app.include_router (#55) 2019-03-16 21:15:08 +04:00
Sebastián Ramírez 0b9fe62a10 Add support for UploadFile class annotations (#63)
* ✨ Add support for UploadFile annotations

* 📝 Update File upload docs with FileUpload class

* ✅ Add tests for UploadFile support

* 📝 Update UploadFile docs
2019-03-03 20:52:37 +04:00
euri10 5c9c088a2a Upgrade Starlette version (#17)
Upgrade Starlette version
2019-02-01 14:14:23 +04:00
Sebastián Ramírez 577c5a84db 🐛 Fix constrained bytes, from defaults in Pydantic
#2
2019-01-05 17:30:27 +04:00
Sebastián Ramírez a73709507c ✅ Add docs, tests and fixes for extra data types
including refactor of jsonable_encoder to allow other object and model types
2018-12-22 14:35:48 +04:00
Sebastián Ramírez 75407b9295 🚨 Fix mypy type errors 2018-12-22 09:05:13 +04:00
Sebastián Ramírez c25a71e352 🐛 Re-implement check for body as a workaround
while encode/starlette#287 is merged
2018-12-22 07:40:56 +04:00
Sebastián Ramírez 7da9625505 💚 Revert to flit install and re-format
As it has shown to be more reliable, and closer to final user environments
2018-12-18 22:36:04 +04:00
Sebastián Ramírez dcb076b752 🐛 Fix optional bodies raising an error
when not provided in the request
2018-12-18 21:11:24 +04:00
Sebastián Ramírez 948a39af95 🎨 Re-order parameters 2018-12-13 20:05:35 +04:00
Sebastián Ramírez 64e904b12e 🐛 Fix indentation bug 2018-12-10 18:20:55 +04:00
Sebastián Ramírez 9458d699cb 🐛 Un-hide inner HTTPException errors 2018-12-10 18:17:42 +04:00
Sebastián Ramírez 9a6fcdd13c 🔊 Log body parsing errors 2018-12-10 17:54:53 +04:00
Sebastián Ramírez da166b7967 🔒 Fix constraining return values to model 2018-12-10 16:46:40 +04:00
Sebastián Ramírez db3c270f8e ✨ Update requests with body, rename params 2018-12-08 11:55:36 +04:00
Sebastián Ramírez 0e19c24014 ✨ Update parameter names and order
fix mypy types, refactor, lint
2018-12-07 19:12:16 +04:00
Sebastián Ramírez addfa89b0f ✨ Refactor, update code, several features 2018-12-06 23:47:58 +04:00
Sebastián Ramírez b9d912c638 ♻️ Refactor, fix and update code 2018-12-06 20:24:50 +04:00
Sebastián Ramírez 406c092a3b 🎉 Start tracking messy initial stage
...before refactoring and breaking something
2018-12-05 10:56:50 +04:00