Open McDonald755 opened 6 months ago
That issue was solved by https://github.com/codecov/feedback/issues/170#issuecomment-1833982446
Does that work for you?
该问题已由#170 解决(评论)
那对你有用吗?
No, I can make sure my file is correct.
it return this error {"message": "Unable to log in due to problem on Github", "asctime": "2024-01-22 03:15:47,351", "name": "codecov_auth.views.github", "levelname": "WARNING", "lineno": 117, "pathname": "/app/codecov_auth/views/github.py", "funcName": "actual_login_step", "threadName": "MainThread", "exc_info": "Traceback (most recent call last):\n File \"/usr/local/lib/python3.9/site-packages/httpcore/backends/asyncio.py\", line 109, in connect_tcp\n stream: anyio.abc.ByteStream = await anyio.connect_tcp(\n File \"/usr/local/lib/python3.9/site-packages/anyio/_core/_sockets.py\", line 218, in connect_tcp\n await event.wait()\n File \"/usr/local/lib/python3.9/site-packages/anyio/_backends/_asyncio.py\", line 662, in aexit\n raise exceptions[0]\n File \"/usr/local/lib/python3.9/site-packages/anyio/_core/_sockets.py\", line 164, in try_connect\n stream = await asynclib.connect_tcp(remote_host, remote_port, local_address)\n File \"/usr/local/lib/python3.9/site-packages/anyio/_backends/_asyncio.py\", line 1691, in connect_tcp\n await get_running_loop().create_connection(\n File \"/usr/local/lib/python3.9/asyncio/base_events.py\", line 1050, in create_connection\n sock = await self._connect_sock(\n File \"/usr/local/lib/python3.9/asyncio/base_events.py\", line 961, in _connect_sock\n await self.sock_connect(sock, address)\n File \"/usr/local/lib/python3.9/asyncio/selector_events.py\", line 500, in sock_connect\n return await fut\nasyncio.exceptions.CancelledError\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_exceptions.py\", line 8, in map_exceptions\n yield\n File \"/usr/local/lib/python3.9/site-packages/httpcore/backends/asyncio.py\", line 109, in connect_tcp\n stream: anyio.abc.ByteStream = await anyio.connect_tcp(\n File \"/usr/local/lib/python3.9/site-packages/anyio/_core/_tasks.py\", line 118, in exit\n raise TimeoutError\nTimeoutError\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File \"/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py\", line 60, in map_httpcore_exceptions\n yield\n File \"/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py\", line 353, in handle_async_request\n resp = await self._pool.handle_async_request(req)\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_async/connection_pool.py\", line 253, in handle_async_request\n raise exc\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_async/connection_pool.py\", line 237, in handle_async_request\n response = await connection.handle_async_request(request)\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_async/connection.py\", line 86, in handle_async_request\n raise exc\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_async/connection.py\", line 63, in handle_async_request\n stream = await self._connect(request)\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_async/connection.py\", line 111, in _connect\n stream = await self._network_backend.connect_tcp(kwargs)\n File \"/usr/local/lib/python3.9/site-packages/httpcore/backends/auto.py\", line 29, in connect_tcp\n return await self._backend.connect_tcp(\n File \"/usr/local/lib/python3.9/site-packages/httpcore/backends/asyncio.py\", line 109, in connect_tcp\n stream: anyio.abc.ByteStream = await anyio.connect_tcp(\n File \"/usr/local/lib/python3.9/contextlib.py\", line 137, in exit\n self.gen.throw(typ, value, traceback)\n File \"/usr/local/lib/python3.9/site-packages/httpcore/_exceptions.py\", line 12, in map_exceptions\n raise to_exc(exc)\nhttpcore.ConnectTimeout\n\nThe above exception was the direct cause of the following exception:\n\nTraceback (most recent call last):\n File \"/usr/local/lib/python3.9/site-packages/shared/torngit/github.py\", line 208, in make_http_call\n res = await client.request(method, url, kwargs)\n File \"/usr/local/lib/python3.9/site-packages/httpx/_client.py\", line 1527, in request\n return await self.send(request, auth=auth, follow_redirects=follow_redirects)\n File \"/usr/local/lib/python3.9/site-packages/httpx/_client.py\", line 1614, in send\n response = await self._send_handling_auth(\n File \"/usr/local/lib/python3.9/site-packages/httpx/_client.py\", line 1642, in _send_handling_auth\n response = await self._send_handling_redirects(\n File \"/usr/local/lib/python3.9/site-packages/httpx/_client.py\", line 1679, in _send_handling_redirects\n response = await self._send_single_request(request)\n File \"/usr/local/lib/python3.9/site-packages/httpx/_client.py\", line 1716, in _send_single_request\n response = await transport.handle_async_request(request)\n File \"/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py\", line 353, in handle_async_request\n resp = await self._pool.handle_async_request(req)\n File \"/usr/local/lib/python3.9/contextlib.py\", line 137, in exit\n self.gen.throw(typ, value, traceback)\n File \"/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py\", line 77, in map_httpcore_exceptions\n raise mapped_exc(message) from exc\nhttpx.ConnectTimeout\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File \"/app/codecov_auth/views/github.py\", line 113, in actual_login_step\n user_dict = self.fetch_user_data(code)\n File \"/usr/local/lib/python3.9/site-packages/asgiref/sync.py\", line 240, in call\n return call_result.result()\n File \"/usr/local/lib/python3.9/concurrent/futures/_base.py\", line 439, in result\n return self.get_result()\n File \"/usr/local/lib/python3.9/concurrent/futures/_base.py\", line 391, in get_result\n raise self._exception\n File \"/usr/local/lib/python3.9/site-packages/asgiref/sync.py\", line 306, in main_wrap\n result = await self.awaitable(*args, **kwargs)\n File \"/app/codecov_auth/views/github.py\", line 79, in fetch_user_data\n authenticated_user = await repo_service.get_authenticated_user(code)\n File \"/usr/local/lib/python3.9/site-packages/shared/torngit/github.py\", line 422, in get_authenticated_user\n response = await self.make_http_call(\n File \"/usr/local/lib/python3.9/site-packages/shared/torngit/github.py\", line 229, in make_http_call\n raise TorngitServerUnreachableError(\nshared.torngit.exceptions.TorngitServerUnreachableError: GitHub was not able to be reached.", "logger.name": "codecov_auth.views.github", "logger.thread_name": "MainThread", "level": "WARNING"}
same https://github.com/codecov/feedback/discussions/169
Overview
Logging in with the "Login with GitHub" button goes through the auth flow, but ends by redirecting to localhost/gh.
Context
Here is the chain of redirects:
http://mydomain.com/login/gh http://github.com/login/oauth/authorize http://mydomain.com/login/github?code=x&state=x http://mydomain.com/login/gh
here is my codecov.yml
my docker-compose.yml
and my github app call back url is "myip:8080/logib/github"