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 build system : adopt PEP517/8 #454

Closed
pp-mo opened this issue Sep 12, 2024 · 5 comments · Fixed by #484
Closed

update build system : adopt PEP517/8 #454

pp-mo opened this issue Sep 12, 2024 · 5 comments · Fixed by #484

Comments

@pp-mo
Copy link
Member

pp-mo commented Sep 12, 2024

AT LEAST replace setup.cfg

setup.py mat be required because of the Cython info

@pp-mo pp-mo converted this from a draft issue Sep 12, 2024
@bjlittle
Copy link
Member

We still need a setup.py and we're already PEP517/8 compliant

@ocefpaf
Copy link
Member

ocefpaf commented Sep 13, 2024

Indeed removing setup.py is good but not mandatory. In case of c-extensions, like this one, it is still easier to maintain. One alternative is mesonpy but I confess I did not like it and I'm using only for Fortran extensions b/c there is no better way at the moment.

TL;DR while the setup.py here could use a clean-up, it is still relevant and correct with modern packaging standards.

@bjlittle
Copy link
Member

@ocefpaf Awesome, thanks 🍻

I've also had a look at meson, and it looks interesting, but I'm not sure whether using it as a build-backend would suit cf-units ... in particular, I fear that we've baked in some nasty dependencies on how setuptools works.

If we were serious about adopting meson we'd have to scope out the impact/effort involved vs the benefit.

There isn't something you know about that's going to break us when attempting to support >py311 in cf-units whilst staying with setuptools ?

I noticed that pyspharm opted to adopt meson for py312 support ... but they're building upon Fortran, so I was guessing that was somehow related to the numpy.disutils migration. Any insight/advice on that?

@ocefpaf
Copy link
Member

ocefpaf commented Sep 18, 2024

I noticed that pyspharm opted to adopt meson for py312 support ... but they're building upon Fortran, so I was guessing that was somehow related to the numpy.disutils migration. Any insight/advice on that?

setuptools is still OK for most c-extensions on modern Python. I'm pretty sure we can drop the numpy.distutils, if that is still used here. I believe that the effort to move to meson is not worth it. I'd rather use that energy to ditch udunits2 and make it pure Python.

@bjlittle
Copy link
Member

Cool 👍

Yup, dropping udunits2 would solve a lot of problems.

I'm 100% behind that 🎉

@pp-mo pp-mo changed the title replace setup.py, adopt PEP517/8 update buld system : adopt PEP517/8 Sep 19, 2024
@pp-mo pp-mo changed the title update buld system : adopt PEP517/8 update build system : adopt PEP517/8 Sep 19, 2024
@pp-mo pp-mo assigned trexfeathers and pp-mo and unassigned pp-mo Sep 19, 2024
@github-project-automation github-project-automation bot moved this from In progress to Done in Autumn 2024 cf-units Sep 26, 2024
@scitools-ci scitools-ci bot removed this from 🚴 Peloton Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants