Skip to content
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

OpenID login error: NoMethodError: undefined method `index' for server_url (which is nil) #1515

Closed
sentry-io bot opened this issue May 4, 2021 · 10 comments

Comments

@sentry-io
Copy link

sentry-io bot commented May 4, 2021

Sentry Issue: MAPKNITTER-5B

NoMethodError: undefined method `index' for nil:NilClass
  openid/store/filesystem.rb:29:in `get_association_filename'
    unless server_url.index('://')
  openid/store/filesystem.rb:82:in `get_association'
    filename = get_association_filename(server_url, handle)
  openid/consumer/idres.rb:209:in `check_signature'
    assoc = @store.get_association(server_url, fetch('assoc_handle'))
  openid/consumer/idres.rb:74:in `id_res'
    check_signature
  openid/consumer/idres.rb:59:in `initialize'
    id_res
...
(69 additional frame(s) were not displayed)
@jywarren
Copy link
Member

jywarren commented May 4, 2021

I just saw this while trying to log in using OAuth, as "warren" --

Why is server_url nil? Are we seeing an issue with openid filesystem storage?

@icarito
Copy link
Member

icarito commented May 4, 2021

Hmmm is it an OAuth or OpenID issue? Are they coupled in any way?
We tested this, will investigate.

@icarito
Copy link
Member

icarito commented May 4, 2021

Hmm I couldn't reproduce at first from here:

  • I logged in to Publiclab.Org with Github OAuth,
  • I logged into Mapnitter using OpenID from Publiclab.Org (regular user/password).
    But I did get a 500 error when trying to log into Mapknitter with Github OAuth.

@icarito
Copy link
Member

icarito commented May 4, 2021

I just saw this while trying to log in using OAuth, as "warren" --

Why is server_url nil? Are we seeing an issue with openid filesystem storage?

We host Mapknitter in Google Appengine since a long time, and we hadn't previously noticed this. There's been no change in this, I'll dig into the Google infrastructure for clues.

@icarito
Copy link
Member

icarito commented May 4, 2021

I see errors for this as far back as February in Sentry, I guess it's been there all along since we moved to Google Appengine.

@jywarren jywarren changed the title OAuth login error: NoMethodError: undefined method `index' for server_url (which is nil) OpenID login error: NoMethodError: undefined method `index' for server_url (which is nil) May 4, 2021
@sentry-io
Copy link
Author

sentry-io bot commented May 4, 2021

This is the issue I managed to reproduce. But I couldn't reproduce an OpenID issue.

Sentry issue: MAPKNITTER-4G

@jywarren
Copy link
Member

jywarren commented May 4, 2021

OK great, i moved the OAuth error to #1516

@jywarren
Copy link
Member

jywarren commented May 4, 2021

When logging into PL.org fresh (in incognito) then using OpenID from MapKnitter, I don't see this error.

@jywarren
Copy link
Member

jywarren commented May 4, 2021

This has happened only 4 times. I'll try logging out of my current session and logging back in.

@jywarren
Copy link
Member

jywarren commented May 4, 2021

Strange, i didn't even have to log out. The second time i tried to log in from MapKnitter via OpenID, it worked. I'll close this with the recommended fix "try again" -- dissatisfying but... pretty rare!

@jywarren jywarren closed this as completed May 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants