-
Notifications
You must be signed in to change notification settings - Fork 13
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
NoMethodError: undefined method `strip' for nil:NilClass #43
Comments
This is something to do with the format of the cookie. I think it might not have a value after the equals sign. https://github.com/rack/rack/blob/2.2.3/lib/rack/mock.rb#L260 |
Can you please share your pact file @sergioa ? |
May that be breaking the parsing? |
I'm getting the same problem. In my case I have two
And my contract is:
|
Digging a little bit more into it, we've found that having equals sign as part of the cookie value may cause failure and was fixed: Any chance, that rack version could be updated to prevent that failure, which it is actually the one that we are facing? |
That would be amazing, right now we just stopped our PACT integration because of this error |
we are blocked as well, we are unable to rollout the integration with PACT just because of this issue. @mefellows @bethesque is this something you may consider? |
I have just realized that rack I don't have any idea on how to fix this. |
I don't have a proposal how to fix it on the Ruby side, but I would suggest (given it looks as though your use case for these cookies is authentication) that in the meantime you consider an alternative approach for that specific aspect of your contract testing initiative. |
It looks like this change is released in rack 3.x https://github.com/rack/rack/releases/tag/v3.0.7 I wonder what is stopping us moving to a later version of rack? Ruby 2.x -> 3.x things? @sergioa how are you progressing these days, are you able to use the rust backed verifier to see if that plays out differently |
we are waiting on a PR to be merged see - pact-foundation/pact-provider-verifier#122 we may need to vendor, in order to allow these to proceed (which would be nice, as there are better things to be thinking about it life) |
- fixes issue #43 - update to rack-test 2.1.0
Hey @sergioa, hope you are well I'm pleased to say this is now resolved I've now vendored the above change, and the pact-provider-verifier (ruby based) which is available via the It is released as https://github.com/pact-foundation/pact-ruby-cli/releases/tag/1.4.0.1 , as part of this pull request - #140 full repro details and resolution shown. It is worth noting to anyone also reading this in the future - you can use the newer rust based verifier available as a docker image at https://hub.docker.com/r/pactfoundation/pact-ref-verifier/tags the source of which is here https://github.com/pact-foundation/pact-reference/tree/master/rust/pact_verifier_cli |
Hi,
My PACT verify is failing while replaying the interaction with the following error:
After some further analysis it seems to be related to the provider setting the header
set-cookie
.Going through the commit log in
rack
, we've seen this commit: rack/rack@d3225f7May that be related to the hash not being initialised properly?
If so, are there any plans to release a new version of both
pact-provider-verifier
andpact-ruby-cli
.We are using
pactfoundation/pact-cli:0.50.0.20
.The text was updated successfully, but these errors were encountered: