Title: Exception on timeout from connection pool acquire · Issue #509 · MagicStack/asyncpg · GitHub
Open Graph Title: Exception on timeout from connection pool acquire · Issue #509 · MagicStack/asyncpg
X Title: Exception on timeout from connection pool acquire · Issue #509 · MagicStack/asyncpg
Description: asyncpg version: v0.20.0 PostgreSQL version: 11 Do you use a PostgreSQL SaaS? If so, which? Can you reproduce the issue with a local PostgreSQL install?: Python version: 3.7 Platform: Ubuntu Do you use pgbouncer?: No Did you install asyn...
Open Graph Description: asyncpg version: v0.20.0 PostgreSQL version: 11 Do you use a PostgreSQL SaaS? If so, which? Can you reproduce the issue with a local PostgreSQL install?: Python version: 3.7 Platform: Ubuntu Do you...
X Description: asyncpg version: v0.20.0 PostgreSQL version: 11 Do you use a PostgreSQL SaaS? If so, which? Can you reproduce the issue with a local PostgreSQL install?: Python version: 3.7 Platform: Ubuntu Do you...
Opengraph URL: https://github.com/MagicStack/asyncpg/issues/509
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Exception on timeout from connection pool acquire","articleBody":"\u003c!--\r\nThank you for reporting an issue/feature request.\r\n\r\nIf this is a feature request, please disregard this template. If this is\r\na bug report, please answer to the questions below.\r\n\r\nIt will be much easier for us to fix the issue if a test case that reproduces\r\nthe problem is provided, with clear instructions on how to run it.\r\n\r\nThank you!\r\n--\u003e\r\n\r\n* **asyncpg version**: v0.20.0\r\n* **PostgreSQL version**: 11\r\n* **Do you use a PostgreSQL SaaS? If so, which? Can you reproduce\r\n the issue with a local PostgreSQL install?**:\r\n* **Python version**: 3.7\r\n* **Platform**: Ubuntu\r\n* **Do you use pgbouncer?**: No\r\n* **Did you install asyncpg with pip?**: Yes\r\n* **If you built asyncpg locally, which version of Cython did you use?**:\r\n* **Can the issue be reproduced under both asyncio and\r\n [uvloop](https://github.com/magicstack/uvloop)?**: Idk, probably.\r\n\r\nThis one fixes timeout error\r\nhttps://github.com/MagicStack/asyncpg/pull/468\r\n\r\nThis one line breaks it.\r\n\r\nhttps://github.com/MagicStack/asyncpg/commit/bdba7ce73324a7a87a8c854de7b5e881ea029744#diff-8424be9bb2792628343ee98369a5cf74L529\r\n\r\n\r\n\r\n```\r\n22:13:29 ERROR [/usr/lib/python3.7/asyncio/base_events.py:1608] Task exception was never retrieved\r\nfuture: \u003cTask finished coro=\u003cPool._acquire.\u003clocals\u003e._acquire_impl() done, defined at .venv/lib/python3.7/site-packages/asyncpg/pool.py:595\u003e exception=AttributeError(\"'coroutine' object has no attribute 'add_done_callback'\")\u003e\r\nTraceback (most recent call last):\r\n File \".venv/lib/python3.7/site-packages/asyncpg/connect_utils.py\", line 621, in _connect_addr\r\n connector, timeout=timeout)\r\n File \"/usr/lib/python3.7/asyncio/tasks.py\", line 409, in wait_for\r\n await waiter\r\nconcurrent.futures._base.CancelledError\r\n\r\nDuring handling of the above exception, another exception occurred:\r\n\r\nTraceback (most recent call last):\r\n File \".venv/lib/python3.7/site-packages/asyncpg/pool.py\", line 598, in _acquire_impl\r\n proxy = await ch.acquire() # type: PoolConnectionProxy\r\n File \".venv/lib/python3.7/site-packages/asyncpg/pool.py\", line 133, in acquire\r\n await self.connect()\r\n File \".venv/lib/python3.7/site-packages/asyncpg/pool.py\", line 125, in connect\r\n self._con = await self._pool._get_new_connection()\r\n File \".venv/lib/python3.7/site-packages/asyncpg/pool.py\", line 472, in _get_new_connection\r\n **self._connect_kwargs)\r\n File \".venv/lib/python3.7/site-packages/asyncpg/connection.py\", line 1677, in connect\r\n max_cacheable_statement_size=max_cacheable_statement_size)\r\n File \".venv/lib/python3.7/site-packages/asyncpg/connect_utils.py\", line 654, in _connect\r\n connection_class=connection_class)\r\n File \".venv/lib/python3.7/site-packages/asyncpg/connect_utils.py\", line 623, in _connect_addr\r\n connector.add_done_callback(_close_leaked_connection)\r\nAttributeError: 'coroutine' object has no attribute 'add_done_callback'\r\n```","author":{"url":"https://github.com/masell","@type":"Person","name":"masell"},"datePublished":"2019-11-28T22:22:18.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/509/asyncpg/issues/509"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:8af62394-3968-1553-8f65-71c57e290d00 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B424:19CD0D:1305C2D:1984FF5:6A5B9659 |
| html-safe-nonce | 1bae4051852c731639e63f7baf75232b3af85018125747bdec77dc6ba59f5d36 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNDI0OjE5Q0QwRDoxMzA1QzJEOjE5ODRGRjU6NkE1Qjk2NTkiLCJ2aXNpdG9yX2lkIjoiNTAwNTA1NjA4NzY2ODAwNDQ0MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 4c6fd656f697f298162e9072fb30e64e36075bab27b603c52bac552142f6f7ca |
| hovercard-subject-tag | issue:530089687 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/MagicStack/asyncpg/509/issue_layout |
| twitter:image | https://opengraph.githubassets.com/b24378bb086d025247b7a8f6c9ff6b4836adb09daeca41f597b337ad7b271c24/MagicStack/asyncpg/issues/509 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/b24378bb086d025247b7a8f6c9ff6b4836adb09daeca41f597b337ad7b271c24/MagicStack/asyncpg/issues/509 |
| og:image:alt | asyncpg version: v0.20.0 PostgreSQL version: 11 Do you use a PostgreSQL SaaS? If so, which? Can you reproduce the issue with a local PostgreSQL install?: Python version: 3.7 Platform: Ubuntu Do you... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | masell |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5290d7e14309ad1e76106a9c4237bd1041517e83ea182c8ab756752cb0c6940b |
| turbo-cache-control | no-preview |
| go-import | github.com/MagicStack/asyncpg git https://github.com/MagicStack/asyncpg.git |
| octolytics-dimension-user_id | 14324950 |
| octolytics-dimension-user_login | MagicStack |
| octolytics-dimension-repository_id | 63652864 |
| octolytics-dimension-repository_nwo | MagicStack/asyncpg |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 63652864 |
| octolytics-dimension-repository_network_root_nwo | MagicStack/asyncpg |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 9c975978430e9ad293956f2bbdaf153b1bd84a99 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width