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

Version 2.0 #29

Merged
merged 37 commits into from
Mar 5, 2021
Merged

Version 2.0 #29

merged 37 commits into from
Mar 5, 2021

Conversation

vladmunteanu
Copy link
Owner

@vladmunteanu vladmunteanu commented Dec 2, 2020

Version 2.0 proposal:

  • BaseResource.get_all renamed to BaseResource.get_many
  • Require starlette >= 0.14.2 to install, for the functools.partial support
  • Remove handle_{get, patch, delete, get_many, post} in favor of partials
  • Marked id argument of get, patch, delete as required, because the framework already expects and passes it.
  • Catch and handle errors from before_request and after_request hooks
  • Added request_context to BaseResource.handle_error and BaseRelationshipResource.handle_error
  • Added _BaseResourceHandler and moved / refactored common logic
  • Made JSONAPIException serialize its detail even if a list of errors is given
  • Relationships will serialize by default, removing the need to specify include_resource_linkage=True when creating a JSONAPIRelationship
  • Sparse Fields handling has been fixed, refactored (no longer async) and should now be easier to override in subclasses
  • BaseResource.register_routes now optionally accepts base_path
  • BaseResource.prepare_relations renamed to BaseResource.include_relations

@vladmunteanu vladmunteanu added the wip Work in progress label Dec 2, 2020
@vladmunteanu
Copy link
Owner Author

Python 3.8 tests failing because of: encode/starlette#1106

@vladmunteanu vladmunteanu marked this pull request as draft December 3, 2020 16:08
@vladmunteanu vladmunteanu marked this pull request as ready for review March 5, 2021 11:07
@vladmunteanu vladmunteanu removed the wip Work in progress label Mar 5, 2021
@vladmunteanu vladmunteanu merged commit b5762e9 into master Mar 5, 2021
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.

1 participant