-
Notifications
You must be signed in to change notification settings - Fork 4
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
475 added acceptable content types #498
base: master
Are you sure you want to change the base?
Conversation
from spinta.commands.write import write | ||
store = prepare_manifest(context) | ||
manifest = store.manifest | ||
root = manifest.objects['ns'][''] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if access rights are checked here? We should limit client to only write to a specified namespace or model. And here, we just take root namespace, which probably gives permission to write data to any namespace?
# Conflicts: # spinta/commands/write.py # spinta/datasets/backends/csv/components.py # spinta/datasets/backends/helpers.py # spinta/formats/helpers.py
else: | ||
stream = _read_request_body( | ||
context, request, scope, action, params, stop_on_error, | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will never be called.
@@ -49,6 +52,7 @@ | |||
STREAMING_CONTENT_TYPES = [ | |||
'application/x-jsonlines', | |||
'application/x-ndjson', | |||
'application/json' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
application/json
should not be here, this is not a streaming content type.
No description provided.