Skip to content

switched kubernetes_asyncio to kubernetes_aio#2590

Open
yliaog wants to merge 10 commits into
kubernetes-client:masterfrom
yliaog:master
Open

switched kubernetes_asyncio to kubernetes_aio#2590
yliaog wants to merge 10 commits into
kubernetes-client:masterfrom
yliaog:master

Conversation

@yliaog
Copy link
Copy Markdown
Contributor

@yliaog yliaog commented May 22, 2026

What type of PR is this?

/kind bug

What this PR does / why we need it:

switched kubernetes_asyncio to kubernetes_aio

Which issue(s) this PR fixes:

Fixes #2583

Special notes for your reviewer:

Does this PR introduce a user-facing change?

NONE

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:


@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/bug Categorizes issue or PR as related to a bug. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels May 22, 2026
@k8s-ci-robot k8s-ci-robot requested a review from roycaihw May 22, 2026 04:16
@yliaog
Copy link
Copy Markdown
Contributor Author

yliaog commented May 22, 2026

/assign @roycaihw

@yliaog
Copy link
Copy Markdown
Contributor Author

yliaog commented May 22, 2026

@karimzakzouk could you take a look at this PR?

@mistydemeo
Copy link
Copy Markdown

Instead of installing a second top-level package, maybe it would make more sense to nest this under kubernetes? eg kubernetes.aio

Copy link
Copy Markdown
Member

@roycaihw roycaihw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 22, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: roycaihw, yliaog

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@roycaihw
Copy link
Copy Markdown
Member

/hold

per #2590 (comment) cc @yliaog

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label May 22, 2026
@yliaog
Copy link
Copy Markdown
Contributor Author

yliaog commented May 22, 2026

Instead of installing a second top-level package, maybe it would make more sense to nest this under kubernetes? eg kubernetes.aio

kubernetes/ for synchronous client
client/
config/
e2e_test/
...
kubernetes_aio/ for asynchronous client
client/
config/
e2e_test/
...

the two have the same directory structure. It may be better to make them both top-level, rather than one nested inside another, which will look like this:
kubernetes/
client/
config/
e2e_test/
...
aio/
aio/client/
aio/config/
aio/e2e_test/
...

Let me add to the CHANGELOG that aio package is experimental, we may change it in future releasses if the community prefers the other approach.

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 22, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

New changes are detected. LGTM label has been removed.

@yliaog
Copy link
Copy Markdown
Contributor Author

yliaog commented May 22, 2026

@roycaihw @mistydemeo

please see the CHANGELOG update:

2d80404

@mistydemeo
Copy link
Copy Markdown

the two have the same directory structure. It may be better to make them both top-level, rather than one nested inside another, which will look like this:

I understand, but given that there's already been one issue from writing to a package owned by another package, it really feels like the safest solution here is to nest it under the existing package.

@yliaog
Copy link
Copy Markdown
Contributor Author

yliaog commented May 22, 2026

the two have the same directory structure. It may be better to make them both top-level, rather than one nested inside another, which will look like this:

I understand, but given that there's already been one issue from writing to a package owned by another package, it really feels like the safest solution here is to nest it under the existing package.

That makes sense. Please take a look at PR: #2593

@karimzakzouk
Copy link
Copy Markdown

@yliaog Thanks for the ping

I actually agree with both of you here. @yliaog is totally right that physically putting the aio folder inside kubernetes/ in the repo would make the generator output super messy.

But I also agree with @mistydemeo that pushing a new top level kubernetes_aio package to PyPI is risky and might just cause the exact same namespace collisions we're trying to fix right now.

I pushed a working concept over in #2586.

Basically, it keeps the kubernetes_asyncio directory totally flat in the repo (so the generator stays clean), but installs under the kubernetes.aio namespace for end users.

I hooked a script into update-client-asyncio.sh that automatically swaps the absolute imports to relative imports right after generation. Then setup-release.py just uses package_dir={'kubernetes.aio': 'kubernetes_asyncio'} during the actual install.

It keeps the repo structure exactly how it is now, but solves the PyPI namespace issue. All tests are passing locally with this setup.Please have a look #2586.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. kind/bug Categorizes issue or PR as related to a bug. release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

kubernetes@36.0.0 overwrites existing kubernetes-asyncio package

5 participants