NPE on no request body
When using spring mockmvc, if I submit a GET with no content set - which is valid - I get an NPE in the swagger validation as it tries to read the body.
Comments (10)
-
-
reporter Sure, it is pretty obvious actually. Version 1.2.1
MockMvcRequest
Line 98. If request has no body, reader is null andreader.readLine()
is NPE. -
Ahh, thanks, I see. Perhaps if we tickle @daknin he can take a look at that without obligation.
-
-
When will this fix be available for usage?
-
@daknin, when is this going to be released? I have been expecting a 1.2.2 release to come out with this fix in.. thanks
-
Apologies - that was my bad. I merged the PR but failed to notice the release didn't go out. Trying to sort it out now.
-
@badge-service , thanks.. let us know when it is available please..
-
@endlergc can you please re-test with the v1.2.2+ and let me know how it goes.
-
- changed status to resolved
- Log in to comment
Hi Arash.
Do you have a stack trace? Or at least the line this is happening? Which version of the Swagger Request Validator are you using?
Kind regards