Hi all,I'm running into an issue that looks like a bug, but I'm unsure where it comes from. Could be in Dancer2, but maybe in Plack::Request, or even in Plack::Test, HTTP::Request, or somewhere else. I'm kinda lost in the woods. I was hoping that a mind greater than mine can shed some light on this.
I get an error "Route exception: Bad Content-Length: maybe client disconnect? (xx bytes remaining)" where xx is the total content length of the request body.
But only under the following conditions: - (valid) JSON POST to a Dancer2 app - the app is configured with serializer = JSON - in the route there's a call to: request->content - using Plack::Test and HTTP::Request Attached is a minimal test to demonstrate the issue. Test no 5 fails.I cannot reproduce this issue when using f.e. curl, this call works without errors:
curl --data-binary '{ "foo": "123" }' --header 'Content-type: application/json' http://localhost:3000/nok
I am using the latest version of Dancer (0.200003) and also latest CPAN versions of Plack and HTTP::Request.
Any insights? Thanks, Lennart
json_post_dancer2_test.pl
Description: Perl program
_______________________________________________ dancer-users mailing list [email protected] http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
