Also, here are the jupyterhub logs for those events:

[I 2017-06-22 14:58:36.031 JupyterHub oauth2:37] oauth redirect: 
'https://129.236.40.168/hub/oauth_callback'
[I 2017-06-22 14:58:36.039 JupyterHub log:100] 302 GET /hub/oauth_login 
(@::ffff:129.236.40.167) 2.79ms
[E 2017-06-22 14:59:19.782 JupyterHub web:1590] Uncaught exception GET 
/hub/oauth_callback?code=8695ece489e4be6d7f56 (::ffff:129.236.40.167)
    HTTPServerRequest(protocol='https', host='129.236.40.168', 
method='GET', uri='/hub/oauth_callback?code=8695ece489e4be6d7f56', 
version='HTTP/1.1', remote_ip='::ffff:129.236
.40.167', headers={'X-Forwarded-Host': '129.236.40.168', 
'X-Forwarded-Proto': 'https', 'X-Forwarded-Port': '443', 'X-Forwarded-For': 
'::ffff:129.236.40.167', 'User-Agent': 'Mo
zilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) AppleWebKit/603.1.30 (KHTML, 
like Gecko) Version/10.1 Safari/603.1.30', 'Accept-Encoding': 'gzip, 
deflate', 'Connection': 'close'
, 'Accept-Language': 'en-us', 'Accept': 
'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'Host': 
'129.236.40.168'})
    Traceback (most recent call last):
      File "/opt/conda/lib/python3.6/site-packages/tornado/web.py", line 
1511, in _execute
        result = yield result
      File 
"/opt/conda/lib/python3.6/site-packages/oauthenticator/oauth2.py", line 51, 
in get
        username = yield self.authenticator.get_authenticated_user(self, 
None)
      File "/opt/conda/lib/python3.6/site-packages/jupyterhub/auth.py", 
line 171, in get_authenticated_user
        username = yield self.authenticate(handler, data)
      File 
"/opt/conda/lib/python3.6/site-packages/oauthenticator/github.py", line 85, 
in authenticate
        resp = yield http_client.fetch(req)
    tornado.httpclient.HTTPError: HTTP 404: Not Found

[E 2017-06-22 14:59:19.789 JupyterHub log:99] {
      "X-Forwarded-Host": "129.236.40.168",
      "X-Forwarded-Proto": "https",
      "X-Forwarded-Port": "443",
      "X-Forwarded-For": "::ffff:129.236.40.167",
      "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) 
AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.1 Safari/603.1.30",
      "Accept-Encoding": "gzip, deflate",
      "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) 
AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.1 Safari/603.1.30",
      "Accept-Encoding": "gzip, deflate",
      "Accept-Encoding": "gzip, deflate",
      "Connection": "close",
      "Accept-Language": "en-us",
      "Accept": 
"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8",
      "Host": "129.236.40.168"
    }
[E 2017-06-22 14:59:19.790 JupyterHub log:100] 500 GET 
/hub/oauth_callback?code=8695ece489e4be6d7f56 (@::ffff:129.236.40.167) 
256.57ms
[E 2017-06-22 14:59:34.195 JupyterHub web:1590] Uncaught exception GET 
/hub/oauth_callback?code=b0d4a493fd932b2fbf0c (::ffff:129.236.40.167)
    HTTPServerRequest(protocol='https', host='129.236.40.168', 
method='GET', uri='/hub/oauth_callback?code=b0d4a493fd932b2fbf0c', 
version='HTTP/1.1', remote_ip='::ffff:129.236.40.167', 
headers={'X-Forwarded-Host': '129.236.40.168', 'X-Forwarded-Proto': 
'https', 'X-Forwarded-Port': '443', 'X-Forwarded-For': 
'::ffff:129.236.40.167', 'Accept-Encoding': 'gzip, deflate', 'Referer': 
'https://github.com/login/oauth/authorize', 'Accept-Language': 'en-us', 
'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) 
AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.1 Safari/603.1.30', 
'Accept': 
'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 
'Connection': 'close', 'Host': '129.236.40.168'})
    Traceback (most recent call last):
      File "/opt/conda/lib/python3.6/site-packages/tornado/web.py", line 
1511, in _execute
        result = yield result
      File 
"/opt/conda/lib/python3.6/site-packages/oauthenticator/oauth2.py", line 51, 
in get
        username = yield self.authenticator.get_authenticated_user(self, 
None)
      File "/opt/conda/lib/python3.6/site-packages/jupyterhub/auth.py", 
line 171, in get_authenticated_user
        username = yield self.authenticate(handler, data)
      File 
"/opt/conda/lib/python3.6/site-packages/oauthenticator/github.py", line 85, 
in authenticate
        resp = yield http_client.fetch(req)
    tornado.httpclient.HTTPError: HTTP 404: Not Found

[E 2017-06-22 14:59:34.206 JupyterHub log:99] {
      "X-Forwarded-Host": "129.236.40.168",
      "X-Forwarded-Proto": "https",
      "X-Forwarded-Port": "443",
      "X-Forwarded-For": "::ffff:129.236.40.167",
      "Accept-Encoding": "gzip, deflate",
      "Referer": "https://github.com/login/oauth/authorize";,
      "Accept-Language": "en-us",
      "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) 
AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.1 Safari/603.1.30",
      "Accept": 
"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8",
      "Connection": "close",
      "Host": "129.236.40.168"
    }
[E 2017-06-22 14:59:34.209 JupyterHub log:100] 500 GET 
/hub/oauth_callback?code=b0d4a493fd932b2fbf0c (@::ffff:129.236.40.167) 
128.57ms

On Thursday, June 22, 2017 at 10:48:40 AM UTC-4, chris bertinato wrote:
>
> Hi all,
>
> I have tried to cover my bases by searching for any related issues, but so 
> far, nothing has helped to resolve this one.
>
> The setup is:
> - ubuntu 16.04 vagrant VM
>   * public network, bridged
> - python 3.6
> - jupyterhub 0.7.2 
> - Github OAuth
>
> Using the url: https://some_ip, I get the redirect to the Github sign-in 
> and like others, once signed in, I get a 404 message with this url:
>
> https://github.com/login/oauth/authorize?redirect_uri=https%3A%2F%2F129.236.40.168%2Fhub%2Foauth_callback&client_id=&response_type=code
>
> I noticed that the client_id is empty.  I read the 
> jupyterhub/oauthenticator issue #69 which was an issue with mismatching 
> client id's, but I've checked that the client id as it appears on Github is 
> the same as in the configuration file.
>
> If I copy+paste the client id from the configuration file into the url I 
> get a 500 (internal server error) message.
>
> Here is the jupyterhub_config.py:
> c.JupyterHub.ssl_key = '/etc/jupyterhub/jupyterhub.key'
> c.JupyterHub.ssl_cert = '/etc/jupyterhub/jupyterhub.crt'
> c.JupyterHub.port = 443
> c.JupyterHub.hub_ip = 'some_ip'
> c.JupyterHub.hub_ip_connect = 'some_ip'
>
> c.JupyterHub.authenticator_class = 'oauthenticator.GitHubOAuthenticator'
> c.LocalAuthenticator.create_system_users = True
> c.GitHubOAuthenaticator.client_id = os.environ['GITHUB_CLIENT_ID']
> c.GitHubOAuthenaticator.client_secret = os.environ['GITHUB_CLIENT_SECRET']
> c.GitHubOAuthenticator.oauth_callback_url = '
> https://some_ip/hub/oauth_callback'
>
> I acknowledge that this is very likely a configuration blunder on my part, 
> but I am quickly exhausting the low-hanging fruit.
>
> Any help would be appreciated.
>
> Chris 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jupyter/07ca4ffb-2992-4887-939c-bd168b3c8ba5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to