Skip to content
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

Update table and add information about staggered migrations #22

Merged
merged 12 commits into from
Feb 5, 2024

Conversation

abravalheri
Copy link
Contributor

@abravalheri abravalheri commented Mar 15, 2023

After setuptools added deprecation warnings for pkg_resources.declare_namespace there has been a lot of doubt in the community about how to migrate away from it, and concerns about carrying out this migration in large projects (see pypa/setuptools#3434).

The objective of this PR is to shed some light on the problem and help to answer the question "what happens if not all the packages sharing a namespace migrate at the same time?".

I took the opportunity to "modernize" the nox matrix, removing the deprecated installation method (using python setup.py ...) and adding some newer Python versions1.

Please note that I did not add all active versions of Python to the matrix on purpose, because that would take too much time in my machine. So I am intentionally stepping away from this objective (if any one is interested in adding the missing Python version that would be a nice next step)2.

Footnotes

  1. The motivation for this is twofold: we are a few moths away from the EoL of Python 3.7 and leaving Python 2.7 and python setup.py ... in the table would be distracting.

  2. Another equally nice improvement would be using CI, but I am also intentionally removing this from the scope of this PR.

@chrysle
Copy link
Contributor

chrysle commented Sep 21, 2023

Thanks for the work! But is it now staggered or staged migrations? If it's not of importance, I'd prefer the latter.

@abravalheri
Copy link
Contributor Author

Hi @chrysle, I am not a native speaker, so I am just replicating the words that were proposed by Jason in pypa/setuptools#3434.

@chrysle
Copy link
Contributor

chrysle commented Sep 21, 2023

Me neither ;-)

Referring to that, the term staged migration came up in zopefoundation/meta#194 (comment). Since that sounds much more "planned", could you update the PR to it?

Moreover, I think Python 3.7 could be dropped now.

@chrysle
Copy link
Contributor

chrysle commented Nov 21, 2023

@abravalheri Please let me know what concerns you have concerning the naming.

@pradyunsg pradyunsg changed the title Update table and add information about staggered migrations. Update table and add information about staggered migrations Nov 21, 2023
@abravalheri
Copy link
Contributor Author

Hi @chrysle sorry I let this one slip...

No I am fine with whichever words people think will make it clearer.
(If any native speaker would like to chip in, that would also be great :P)

@chrysle
Copy link
Contributor

chrysle commented Nov 26, 2023

Well, so I asked OALD, and to stagger seems to be a valid transitive (although that wasn't known to me), and the meaning of to stage I meant (of which I know it's possible) isn't even mentioned on the corresponding page....

So let's take the former ;) Could you rebase?

@abravalheri
Copy link
Contributor Author

Hi @chrysle, I solved the merge conflicts and also took the opportunity to ensure all tests were using build-isolation and backend APIs (aka PEP 517+PEP 660) - by adding pyproject.toml everywhere.

Hopefully the CI will pass 🤞

@abravalheri
Copy link
Contributor Author

Hopefully the CI will pass 🤞

Oh well, too soon.
I think that the CI might be failing in some rows of the column, e.g.:

nox > * session_cross_pkg_resources_pkgutil-3.8(command_b=('pip', 'install', '.'), command_a=('pip', 'install', '-e', '.')): failed

That is kind of expected isn't? Some combinations will fail indeed.
Not sure why the CI is expecting everything to pass...

@chrysle
Copy link
Contributor

chrysle commented Nov 27, 2023

Thank you!

That is kind of expected isn't? Some combinations will fail indeed. Not sure why the CI is expecting everything to pass...

I actually made the CI pass in #24 (could you have a look at that?). I don't think there will be any more merge conflicts when that is merged. And @pradyunsg enabled that passing checks are required.

noxfile.py Outdated Show resolved Hide resolved
@abravalheri
Copy link
Contributor Author

I think #24 is going to be a big conflict with this one, isn't it?

The original idea behind running nox right now is to generate an informative table that will include situations where combining thing will pass and other where it will not pass... Making all the sessions in nox pass kind of defeat this purpose isn't it?

@chrysle
Copy link
Contributor

chrysle commented Nov 27, 2023

Sorry if I screwed this up, I didn't find any documentation here that would explain this purpose. On the other hand, if you are able to run all scenarios correctly, isn't that more helpful to you?

@abravalheri
Copy link
Contributor Author

abravalheri commented Nov 27, 2023

Oh no, I didn't mean you screw things up, sorry if I miscommunicated that.

I think that adding more scenarios is good. But we should not remove scenarios that don't work (showing that they don't work is kind of the point).
The assumption that CI should have all the nox sessions passing is not something that this repository was originally designed for.

Copy link
Contributor

@chrysle chrysle left a comment

Choose a reason for hiding this comment

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

Looks good!

Should we migrate all the examples to pyproject.toml later on (probably keeping setup.pys as samples)?

report_to_table.py Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
@chrysle
Copy link
Contributor

chrysle commented Dec 5, 2023

@abravalheri Gentle nudge to this, sorry for approving too early.

@abravalheri
Copy link
Contributor Author

Hi @chrysle, sorry for the delay. I am away from my computer this December and less responsive than usual. I will be able to have a look as soon as I come back in January. But I think it might make sense to separate into 2 PRs.

@chrysle
Copy link
Contributor

chrysle commented Dec 5, 2023

No problem, take your time and enjoy your holiday!

But I think it might make sense to separate into 2 PRs.

That's my suggestion too.

README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
abravalheri and others added 5 commits February 5, 2024 11:53
Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
Co-authored-by: chrysle <fritzihab@posteo.de>
@abravalheri
Copy link
Contributor Author

I rebased the PR and updated the table with the latest output of nox.

@chrysle chrysle merged commit d6a93a1 into pypa:master Feb 5, 2024
0 of 3 checks passed
@chrysle
Copy link
Contributor

chrysle commented Feb 5, 2024

Thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants