-
Couldn't load subscription status.
- Fork 95
Switch id request from get to put #12
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
Conversation
This makes it work... post doesn't work. BLARGH. Many bothans died over 3 hours to bring us this realization.
|
This is a bizarre one. I've been using Faraday 0.9.0 since August and only just started getting this so not sure if it's a change in Faraday. Just checked my gemspec and non of the dependencies have changed. |
|
Ah-- do you get it consistently? I read somebody saying he got it sporadically. Perhaps Salesforce have changed something on their end. I think this is the documentation for it: |
|
can we merge this? |
|
Looks fine to me. Will test this evening and merge. Thanks. |
|
👍 Confirming that we faced the same issue in our dev boxes, and @dchaley's fix solved the problem. |
|
forked @dchaley 's version and it works now!!!! |
|
👍 please merge and cut a gem! |
|
👍 for merging and releasing it soon |
|
Ran into this issue as well when the application suddenly stopped authenticating. Using @dchaley fix to solve the problem. |
|
Please merge and release soon 👍 Thank you! We really need this for our app to work and want to be able to set our get to just pull from: gem 'omniauth-salesforce' without specifying it to pull from docsend fork. Again thanks so much! |
|
👍 Please merge |
|
Please don't do this. Salesforce officially supports passing the auth token in the headers and not in the body. It should support both, but they have a bug in their latest release. This PR fixes it in a more supported way. Officially supporting what Salesforce recommends is the way to go #13 |
|
👍 for @sb8244's fix. |
|
Getting to this soon! Apologies for the delay! |
|
Just merged the fix #15 from @sb8244 to master. Sounds like the issue happens intermittently and I haven't been able to produce it. The current version also works fine for me so if someone who was seeing the issue could confirm that the current master branch solves this then i'll push out a new version to rubygmes later today. Sorry again for the delay. |
|
Just a heads up, this happens when the access_token contains a |
|
Master seems to have resolved the issue for me. I was getting it reasonably consistently across two apps. |
When the info request is a post, I consistently get this error:
(salesforce) Authentication failure! invalid_credentials: OAuth2::Error, Missing_OAuth_Token
This is despite the post having an oauth token parameter:
post https://login.salesforce.com/id/obfuscated/obfuscated?oauth_token=obfuscated
It seems that this request doesn't have to be a post in the first place, and changing it to a get consistently makes the request succeed. I confess to not having tracked down why, exactly, the change works.
This is using faraday (0.9.0). Perhaps it is a faraday compatibility issue with how the post request is constructed. This working sample:
https://github.com/takahiro-yonei/OmniAuth-Salesforce-Sample
uses Faraday 0.7.6.
e.g., it could be an error in how the Oauth2 gem is constructing its post request, by having it be a param rather than in the request body.
Sorry to not be more helpful on that part -- but can we at least focus on why it's a post and not a get, and whether changing it to a get is acceptable? Because that will avoid this problem entirely.