Title: [Bug] Using < 3.10 on samples using global asyncio.Event fails · Issue #37 · temporalio/samples-python · GitHub
Open Graph Title: [Bug] Using < 3.10 on samples using global asyncio.Event fails · Issue #37 · temporalio/samples-python
X Title: [Bug] Using < 3.10 on samples using global asyncio.Event fails · Issue #37 · temporalio/samples-python
Description: Describe the bug asyncio.Event didn't get rid of its loop parameter (and defer loop lookup until use) until >= 3.10. So samples that instantiate an asyncio.Event() globally will get this when running in < 3.10: Traceback (most recent cal...
Open Graph Description: Describe the bug asyncio.Event didn't get rid of its loop parameter (and defer loop lookup until use) until >= 3.10. So samples that instantiate an asyncio.Event() globally will get this when runni...
X Description: Describe the bug asyncio.Event didn't get rid of its loop parameter (and defer loop lookup until use) until >= 3.10. So samples that instantiate an asyncio.Event() globally will get this whe...
Opengraph URL: https://github.com/temporalio/samples-python/issues/37
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[Bug] Using \u003c 3.10 on samples using global asyncio.Event fails","articleBody":"### Describe the bug\n`asyncio.Event` didn't get rid of its loop parameter (and defer loop lookup until use) until \u003e= 3.10. So samples that instantiate an `asyncio.Event()` globally will get this when running in \u003c 3.10:\n\n```\nTraceback (most recent call last):\n File \"scratch\\scratch.py\", line 106, in \u003cmodule\u003e\n loop.run_until_complete(main())\n File \"asyncio\\base_events.py\", line 616, in run_until_complete\n File \"scratch\\scratch.py\", line 99, in main\n await interrupt_event.wait()\n File \"asyncio\\locks.py\", line 309, in wait\nRuntimeError: Task \u003cTask pending name='Task-1' coro=\u003cmain() running at scratch\\scratch.py:99\u003e cb=[_run_until_complete_cb() at asyncio\\base_events.py:184]\u003e got Future \u003cFuture pending\u003e attached to a different loop\n```\n\nOf course delaying creation of the event until after loop creation and passing in the now-removed `loop` kwarg in the event constructor fixes it.\n\nWe just need to find a better way to marry asyncio and signals across our samples.\n\n","author":{"url":"https://github.com/cretz","@type":"Person","name":"cretz"},"datePublished":"2022-12-14T17:40:27.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/37/samples-python/issues/37"}
| 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:6b4e7b90-072f-8465-b24b-a01496a7144e |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E8CE:3E67A5:A7A0F4:EB581B:6A4E7E0F |
| html-safe-nonce | 410207e2651b197a5a37b033ce9c0c715168f9f76452cfca8054d0bccb839001 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFOENFOjNFNjdBNTpBN0EwRjQ6RUI1ODFCOjZBNEU3RTBGIiwidmlzaXRvcl9pZCI6IjQxMTIzODA4Mzc4MDE5MTc5NjciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 234915889d51abf650be600ed6224628edda041cada725806351c5c78bbc9b14 |
| hovercard-subject-tag | issue:1497106230 |
| 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/temporalio/samples-python/37/issue_layout |
| twitter:image | https://opengraph.githubassets.com/557083d5267a1db6b53e40ec6b139d4b35ab9ddc5c5635783332919d71715433/temporalio/samples-python/issues/37 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/557083d5267a1db6b53e40ec6b139d4b35ab9ddc5c5635783332919d71715433/temporalio/samples-python/issues/37 |
| og:image:alt | Describe the bug asyncio.Event didn't get rid of its loop parameter (and defer loop lookup until use) until >= 3.10. So samples that instantiate an asyncio.Event() globally will get this when runni... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | cretz |
| hostname | github.com |
| expected-hostname | github.com |
| None | 41b6ab3ba6d20a71766ac245b5a4a94c6fc672a9cd4da7d44c1b33ab8bf6a21c |
| turbo-cache-control | no-preview |
| go-import | github.com/temporalio/samples-python git https://github.com/temporalio/samples-python.git |
| octolytics-dimension-user_id | 56493103 |
| octolytics-dimension-user_login | temporalio |
| octolytics-dimension-repository_id | 454557884 |
| octolytics-dimension-repository_nwo | temporalio/samples-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 454557884 |
| octolytics-dimension-repository_network_root_nwo | temporalio/samples-python |
| 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 | e6a744804e8e70f97b4d5a18a94dcc63db22f97a |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width