-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
💅 Propagate error causes via asyncio protocols #8089
💅 Propagate error causes via asyncio protocols #8089
Conversation
@bdraco @Dreamsorcerer please, consider this idea 🙏 Hopefully, it's viable. I expect that this needs polishing, of course. Especially since I didn't even bother touching the tests. Surprisingly, only 6 failed: https://github.com/aio-libs/aiohttp/actions/runs/7691292578/job/20956384838?pr=8089#step:11:3813. |
41f7b1a
to
6c4278c
Compare
f0d5b92
to
3706e7c
Compare
Backport to 3.9: 💔 cherry-picking failed — conflicts found❌ Failed to cleanly apply dc38630 on top of patchback/backports/3.9/dc38630b168a169139974617d75e176530c91696/pr-8089 Backporting merged PR #8089 into master
🤖 @patchback |
Backport to 3.10: 💔 cherry-picking failed — conflicts found❌ Failed to cleanly apply dc38630 on top of patchback/backports/3.10/dc38630b168a169139974617d75e176530c91696/pr-8089 Backporting merged PR #8089 into master
🤖 @patchback |
…ia asyncio protocols This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with aio-libs#4581. PR aio-libs#8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
…ia asyncio protocols This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with aio-libs#4581. PR aio-libs#8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
…a asyncio protocols This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with aio-libs#4581. PR aio-libs#8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
…a asyncio protocols This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with aio-libs#4581. PR aio-libs#8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
…ia asyncio protocols This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with aio-libs#4581. PR aio-libs#8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
…o protocols (#8162) **This is a backport of PR #8089 as merged into master (dc38630).** This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with #4581. PR #8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
…io protocols (#8161) **This is a backport of PR #8089 as merged into master (dc38630).** This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available. It'll make possible for the end-users to see more detailed tracebacks. It's also supposed to help with tracking down what's happening with #4581. PR #8089 Co-Authored-By: J. Nick Koston <[email protected]> Co-Authored-By: Sam Bull <[email protected]> (cherry picked from commit dc38630)
@bdraco I'm triggering a release candidate via https://github.com/aio-libs/aiohttp/actions/runs/7926204466 — you'll be able to deploy this pre-release for testing before cutting a stable version. |
@bdraco I ended up having to re-trigger the release on another commit: https://github.com/aio-libs/aiohttp/actions/runs/7930478394/job/21655287776. It's now available via https://pypi.org/project/aiohttp/3.9.4rc0/. cc @Dreamsorcerer FYI |
This PR is rc0 for now but will be updated when the full release it out. For now its to get a CI run to see if there are any side effects/regressions and make sure aio-libs/aiohttp#8089 is good with our code.
Running HA supervisor and core CIs against this now. I'm also going to test it on my production systems shortly |
I'm also deploying this into the Chronographer and Patchback bots now, that have Sentry hooked up. This should help with figuring out #4581 since Sentry alerts with that arrive every day and it's quite annoying. |
I had to revert back right away when testing on production due to:
|
I thought that PR was only merged into 3.10? |
It did. Sorry for the lack of clarity. I pulled 3.10 on to test since that's what I've been running with as the staging production env is making use of 3.10 features. I'm going to pull it back down to 3.9 later today when I have free cycles |
I've managed to get the smaller one downgraded to 3.9 (3.9.4rc0). So far so good. I'm working on the larger one |
Larger install is working well. No regressions observed. I'm about to leave town for the weekend. I'll report back after checking the logs when I get back home (Sunday night/Monday depending on jetlag) |
Great! I hope I'll get some tracebacks from the bots too, maybe. |
This is supposed to unify setting exceptions on the future objects, allowing to also attach their causes whenever available.
It's also supposed to help with tracking down what's happening with #4581.
What do these changes do?
$sbj.
Are there changes in behavior for the user?
They should be able to see more detailed tracebacks.
Related issue number
#4581
Checklist
CONTRIBUTORS.txt
CHANGES/
foldername it
<issue_or_pr_num>.<type>.rst
(e.g.588.bugfix.rst
)if you don't have an issue number, change it to the pull request
number after creating the PR
.bugfix
: A bug fix for something the maintainers deemed animproper undesired behavior that got corrected to match
pre-agreed expectations.
.feature
: A new behavior, public APIs. That sort of stuff..deprecation
: A declaration of future API removals and breakingchanges in behavior.
.breaking
: When something public is removed in a breaking way.Could be deprecated in an earlier release.
.doc
: Notable updates to the documentation structure or buildprocess.
.packaging
: Notes for downstreams about unobvious side effectsand tooling. Changes in the test invocation considerations and
runtime assumptions.
.contrib
: Stuff that affects the contributor experience. e.g.Running tests, building the docs, setting up the development
environment.
.misc
: Changes that are hard to assign to any of the abovecategories.
Make sure to use full sentences with correct case and punctuation,
for example:
Use the past tense or the present tense a non-imperative mood,
referring to what's changed compared to the last released version
of this project.