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

Transition remote modules configuration from setup.py to the modern pyproject.toml #4748

Open
38 of 85 tasks
jhlegarreta opened this issue Jun 23, 2024 · 5 comments
Open
38 of 85 tasks
Labels
type:Infrastructure Infrastructure/ecosystem related changes, such as CMake or buildbots

Comments

@jhlegarreta
Copy link
Member

jhlegarreta commented Jun 23, 2024

Description

Transition remote modules configuration from setup.py to the modern pyproject.toml.

Impact analysis

pyproject.toml is the modern way to package projects using Python code:
https://packaging.python.org/en/latest/guides/writing-pyproject-toml/
https://packaging.python.org/en/latest/guides/modernize-setup-py-project/#modernize-setup-py-project

Expected behavior

Transition all remote module's project configuration to a pyproject.toml file.

Actual behavior

Almost all remote module's project configuration dwells in a setup.py file.

Versions

N/A.

Environment

N/A.

Additional Information

Matt has contributed with a script that would help in the transition:
InsightSoftwareConsortium/ITKModuleTemplate#161

Also, there is this tool Matt has used to update the remote module CI config to ITK 5.4:
https://github.com/asottile/all-repos

Ongoing work:
thewtex@9e9d513

Remotes and PRs:

Notes:

@jhlegarreta jhlegarreta added the type:Infrastructure Infrastructure/ecosystem related changes, such as CMake or buildbots label Jun 23, 2024
@thewtex
Copy link
Member

thewtex commented Jun 24, 2024

@jhlegarreta thank you for your help with this! 💯 🥇

I did not bump the versions for the remotes while opening the PRs. @thewtex let me know your thoughts. Major, minor, patch, none?

I think we should bump the major version. Experience has shown that the packages are not binary compatible across itk major or minor releases. Following semantic versioning, this is a major bump.

In the process of updating these, we could consider also changing the default branch from master to main,

image

@jhlegarreta
Copy link
Member Author

Re #4748 (comment)

I am not bumping to newer ITK versions when transitioning to pyproject.toml: I am leaving unmodified the ITK dependency version that is transferred automatically from setup.py to pyproject.toml. Do you want me to require "itk>=5.4" for all of them while adopting pyproject.toml?

In the process of updating these, we could consider also changing the default branch from master to main,

Can do that right after the PRs are merged.

@thewtex
Copy link
Member

thewtex commented Jun 25, 2024

I am not bumping to newer ITK versions when transitioning to pyproject.toml: I am leaving unmodified the ITK dependency version that is transferred automatically from setup.py to pyproject.toml. Do you want me to require "itk>=5.4" for all of them while adopting pyproject.toml?

Yes, please. itk == 5.4.* to be specific (or itk-core == 5.4.* if it only requires itk-core, etc.) We should update the script to do so automatically, too.

@jhlegarreta
Copy link
Member Author

jhlegarreta commented Jun 25, 2024

Yes, please. itk == 5.4.* to be specific (or itk-core == 5.4.* if it only requires itk-core, etc.) We should update the script to do so automatically, too.

OK, done. The script does update to itk == 5.4.* in most cases (e.g. it does not when no specific version of itk has been specified, for example).

Edit: leaving bumping version of ITKTubeTK to @aylward.

thewtex added a commit to thewtex/scikit-build-core that referenced this issue Jul 19, 2024
This is an example of a realistic, more complex scikit-build-core SWIG
project, historically sparked the origin of scikit-build.

There are also many additional examples referenced here:

  InsightSoftwareConsortium/ITK#4748
thewtex added a commit to thewtex/scikit-build-core that referenced this issue Jul 19, 2024
This is an example of a realistic, more complex scikit-build-core SWIG
project that also sparked the origin of scikit-build.

There are also many additional examples referenced here:

  InsightSoftwareConsortium/ITK#4748
thewtex added a commit to thewtex/scikit-build-core that referenced this issue Jul 19, 2024
This is an example of a realistic, more complex scikit-build-core SWIG
project that also sparked the origin of scikit-build.

Point to the itk-webassemblyinterface ITK Remote module configuration.
(the main `itk` package has a configured pyproject.toml in the
[ITKPythonPackage](https://github.com/InsightSoftwareConsortium/ITKPythonPackage)
repository which does not support the docs extraction
assumptions).

There are also many additional examples referenced here:

  InsightSoftwareConsortium/ITK#4748
thewtex added a commit to thewtex/scikit-build-core that referenced this issue Jul 19, 2024
This is an example of a realistic, more complex scikit-build-core SWIG
project that also sparked the origin of scikit-build.

Point to the main `itk` package pyproject.toml configuration and many
adition ITK Remote Module extension packages configured here many additional examples
referenced here:

  InsightSoftwareConsortium/ITK#4748
thewtex added a commit to thewtex/scikit-build-core that referenced this issue Jul 19, 2024
This is an example of a realistic, more complex scikit-build-core SWIG
project that also sparked the origin of scikit-build.

Point to the main `itk` package pyproject.toml configuration and many
adition ITK Remote Module extension packages configured here many additional examples
referenced here:

  InsightSoftwareConsortium/ITK#4748
henryiii pushed a commit to scikit-build/scikit-build-core that referenced this issue Jul 19, 2024
This is an example of a realistic, more complex scikit-build-core SWIG
project that also sparked the origin of scikit-build.

There are also many additional examples referenced here:

  InsightSoftwareConsortium/ITK#4748
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:Infrastructure Infrastructure/ecosystem related changes, such as CMake or buildbots
Projects
None yet
Development

No branches or pull requests

3 participants