Skip to content

Upper lowerbound for aiodns to fix hanging issue#6695

Merged
mdellweg merged 1 commit into
pulp:mainfrom
pedro-psb:restrict-aiodns-lowerbound
Jun 18, 2025
Merged

Upper lowerbound for aiodns to fix hanging issue#6695
mdellweg merged 1 commit into
pulp:mainfrom
pedro-psb:restrict-aiodns-lowerbound

Conversation

@pedro-psb

Copy link
Copy Markdown
Member

I've conducted some tests with the script below (independent from any Pulp logic) and tested that agains't a combination of python, aiodns and pycares versions, almost no changes (see below).
The result were are marked x for hanging and ok for not-hanging.

As the result shows, it has some unstable behavior for aiodns-3.2 combinations, but works for >=3.3 combinations.

script.py

import aiohttp
import asyncio
import logging

logging.basicConfig(level=logging.DEBUG)
URL = "http://example.com"

async def main():
    async with aiohttp.ClientSession() as session:
        async with session.get(URL) as response:
            return response.status

status = asyncio.run(main())
assert status == 200, status

results

pycares==4.8 aiodns==3.2
py3.9  ok
py3.10 ok
py3.11 ok
py3.12 ok
py3.13 ok

pycares==4.9 aiodns==3.2
py3.9  x
py3.10 x
py3.11 x
py3.12 ok
py3.13 ok

pycares==4.8 aiodns==3.2
pycares==4.9 aiodns==3.3
pycares==4.8 aiodns==3.3
pycares==4.8 aiodns==3.4
pycares==4.8 aiodns==3.4
py3.9  ok
py3.10 ok
py3.11 ok
py3.12 ok
py3.13 ok

Diff between python versions (equal for every aiodns x pycares combination):

venv39.output venv310.output
No changes.

venv310.output venv311.output
diff --git a/venv310.output b/venv311.output
index 4faf2be..d7e6177 100644
--- a/venv310.output
+++ b/venv311.output
@@ -5 +4,0 @@ aiosignal==1.3.2
-async-timeout==5.0.1
@@ -8 +6,0 @@ cffi==1.17.1
-exceptiongroup==1.3.0
@@ -20,2 +17,0 @@ pytest==8.4.0
-tomli==2.2.1
-typing_extensions==4.14.0

venv311.output venv312.output
No changes.

venv312.output venv313.output
No changes.

@mdellweg mdellweg merged commit 96e79a8 into pulp:main Jun 18, 2025
13 checks passed
@patchback

patchback Bot commented Jun 18, 2025

Copy link
Copy Markdown

Backport to 3.80: 💔 cherry-picking failed — conflicts found

❌ Failed to cleanly apply 96e79a8 on top of patchback/backports/3.80/96e79a8f66c8ae8d5b5c2b3408d17f1110765700/pr-6695

Backporting merged PR #6695 into main

  1. Ensure you have a local repo clone of your fork. Unless you cloned it
    from the upstream, this would be your origin remote.
  2. Make sure you have an upstream repo added as a remote too. In these
    instructions you'll refer to it by the name upstream. If you don't
    have it, here's how you can add it:
    $ git remote add upstream https://github.com/pulp/pulpcore.git
  3. Ensure you have the latest copy of upstream and prepare a branch
    that will hold the backported code:
    $ git fetch upstream
    $ git checkout -b patchback/backports/3.80/96e79a8f66c8ae8d5b5c2b3408d17f1110765700/pr-6695 upstream/3.80
  4. Now, cherry-pick PR Upper lowerbound for aiodns to fix hanging issue #6695 contents into that branch:
    $ git cherry-pick -x 96e79a8f66c8ae8d5b5c2b3408d17f1110765700
    If it'll yell at you with something like fatal: Commit 96e79a8f66c8ae8d5b5c2b3408d17f1110765700 is a merge but no -m option was given., add -m 1 as follows instead:
    $ git cherry-pick -m1 -x 96e79a8f66c8ae8d5b5c2b3408d17f1110765700
  5. At this point, you'll probably encounter some merge conflicts. You must
    resolve them in to preserve the patch from PR Upper lowerbound for aiodns to fix hanging issue #6695 as close to the
    original as possible.
  6. Push this branch to your fork on GitHub:
    $ git push origin patchback/backports/3.80/96e79a8f66c8ae8d5b5c2b3408d17f1110765700/pr-6695
  7. Create a PR, ensure that the CI is green. If it's not — update it so that
    the tests and any other checks pass. This is it!
    Now relax and wait for the maintainers to process your pull request
    when they have some cycles to do reviews. Don't worry — they'll tell you if
    any improvements are necessary when the time comes!

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
mdellweg pushed a commit that referenced this pull request Jun 18, 2025
mdellweg pushed a commit that referenced this pull request Jun 18, 2025
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jun 18, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
gerrod3 pushed a commit that referenced this pull request Jun 23, 2025
See for more context:
#6695

(cherry picked from commit b156030)
@Odilhao

Odilhao commented Jun 25, 2025

Copy link
Copy Markdown

Can we make this a python version thing?

Right now on katello we have python3.12, pulpcore 3.73 and pycares 4.9. Having pycares < 4.9 means that our pipelines will fail due to dependency resolution when I build 3.73.13

@mdellweg

Copy link
Copy Markdown
Member

Can we make this a python version thing?

Right now on katello we have python3.12, pulpcore 3.73 and pycares 4.9. Having pycares < 4.9 means that our pipelines will fail due to dependency resolution when I build 3.73.13

I believe you meant the backported versions of this fix where we were not confident raising the lower bound?

@mdellweg

Copy link
Copy Markdown
Member

#6722

mdellweg pushed a commit to pedro-psb/pulpcore that referenced this pull request Jul 2, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
pedro-psb added a commit to pedro-psb/pulpcore that referenced this pull request Jul 7, 2025
See for more context:
pulp#6695

(cherry picked from commit b156030)
mdellweg pushed a commit that referenced this pull request Jul 7, 2025
See for more context:
#6695

(cherry picked from commit b156030)
mdellweg pushed a commit that referenced this pull request Jul 7, 2025
See for more context:
#6695

(cherry picked from commit b156030)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants