Skip to content

Use pyproject.toml fully instead of setup.py#721

Merged
adybbroe merged 4 commits into
pytroll:mainfrom
mraspaud:use-pyproject.toml
May 19, 2026
Merged

Use pyproject.toml fully instead of setup.py#721
adybbroe merged 4 commits into
pytroll:mainfrom
mraspaud:use-pyproject.toml

Conversation

@mraspaud
Copy link
Copy Markdown
Member

@mraspaud mraspaud commented May 18, 2026

Use pyproject.toml to entirely remove setup.py

This PR was generated mainly using AI

@mraspaud mraspaud self-assigned this May 18, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.66%. Comparing base (b23310e) to head (3b1287b).
⚠️ Report is 20 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #721   +/-   ##
=======================================
  Coverage   93.66%   93.66%           
=======================================
  Files          89       89           
  Lines       13707    13707           
=======================================
  Hits        12838    12838           
  Misses        869      869           
Flag Coverage Δ
unittests 93.66% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment thread pyproject.toml
Comment on lines +97 to +98
{ platforms = ["linux", "darwin", "freebsd"], arg = "-O3" },
{ platforms = ["linux", "darwin", "freebsd"], arg = "-Wno-unused-function" },
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

These 2 lines can't be combined?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

My understanding is that hatch-cython wants them separate

Copy link
Copy Markdown
Member

@djhoese djhoese left a comment

Choose a reason for hiding this comment

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

The unstable environment in CI might need to be updated to not install versioneer. And maybe the RTD config too.

I'm fine with this, but it does scare me for any further customizations that we may want. For example, I think pykdtree's setup.py has a lot of custom stuff depending on what it finds in the environment (ex. OpenMP) so I'm worried about what pyresample would have to do to handle a similar case.

@adybbroe adybbroe added the PCW Pytroll Contributors' Week label May 19, 2026
@adybbroe
Copy link
Copy Markdown
Contributor

This saved my (PCW) week, thanks Martin!
I will make an issue shortly...

@adybbroe
Copy link
Copy Markdown
Contributor

Should close #722 (edited the pre-amble reflecting that - see above)

@mraspaud
Copy link
Copy Markdown
Member Author

The unstable environment in CI might need to be updated to not install versioneer. And maybe the RTD config too.

I'm fine with this, but it does scare me for any further customizations that we may want. For example, I think pykdtree's setup.py has a lot of custom stuff depending on what it finds in the environment (ex. OpenMP) so I'm worried about what pyresample would have to do to handle a similar case.

Noted! I think we will be able to fix this though, so we'll go ahead and merge this.

Copy link
Copy Markdown
Contributor

@adybbroe adybbroe left a comment

Choose a reason for hiding this comment

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

LGTM

@adybbroe adybbroe merged commit 59da024 into pytroll:main May 19, 2026
26 checks passed
@github-project-automation github-project-automation Bot moved this from Backlog to Done in PCW Spring 2026 May 19, 2026
@mraspaud mraspaud deleted the use-pyproject.toml branch May 19, 2026 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement PCW Pytroll Contributors' Week

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Cannot import unless being in the pyresample source root - when installing with pip (not using conda-forge)

3 participants