Closed davisagli closed 8 months ago
Name | Link |
---|---|
Latest commit | f21126438286aada268ffe2d45f687dad0590cee |
Latest deploy log | https://app.netlify.com/sites/plone-restapi/deploys/654162942888b40008785ce9 |
@davisagli thanks for creating this Pull Request and helping to improve Plone!
TL;DR: Finish pushing changes, pass all other checks, then paste a comment:
@jenkins-plone-org please run jobs
To ensure that these changes do not break other parts of Plone, the Plone test suite matrix needs to pass, but it takes 30-60 min. Other CI checks are usually much faster and the Plone Jenkins resources are limited, so when done pushing changes and all other checks pass either start all Jenkins PR jobs yourself, or simply add the comment above in this PR to start all the jobs automatically.
Happy hacking!
@jenkins-plone-org please run jobs
For the record, I confirm that with this PR a POST to the @login
endpoint still works, regardless of whether you set a Content-Type header or not, as long as you either set an Accept header or use the ++api++
namespace.
@mauritsvanrees The Accept header doesn't sound relevant to me. That tells the server what content-type the client hopes to receive in the response, not what content-type it is sending in the request.
I confirmed that uploading large files in Volto still triggers the error, but that's expected. I guess we can catch BadRequest here, but I think that just hides the problem.
To really fix it for Volto, we need to:
I think this is a good path forward but it's not going to happen overnight.
This is good to go, I merge. Would be good to have this in a release soon. I may do that today, unless @tisto or @davisagli is earlier.
Before release, please approve and merge PR #1729.
Alternative to #1726
We should only try to parse the request body as JSON if there's a request header saying it's JSON.