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

Include setup.py in sdist #144

Closed
jameshilliard opened this issue Nov 29, 2021 · 7 comments
Closed

Include setup.py in sdist #144

jameshilliard opened this issue Nov 29, 2021 · 7 comments
Labels
duplicate This issue or pull request already exists question Further information is requested

Comments

@jameshilliard
Copy link

I noticed setup.py was removed here, however since tomli is a required dependency for bootstrapping flit this should be included to make installing flit easier for distros that need it for setting up a PEP-517 build environment.

@hukkin
Copy link
Owner

hukkin commented Nov 29, 2021

This has been discussed before. Please see #122 (comment)

For bootstrapping see https://github.com/FFY00/python-bootstrap and https://flit.readthedocs.io/en/latest/bootstrap.html

@jameshilliard
Copy link
Author

For bootstrapping see https://github.com/FFY00/python-bootstrap and https://flit.readthedocs.io/en/latest/bootstrap.html

Best I can tell nothing here actually covers installing tomli for distro build systems that don't already have wheel support(for various reasons we don't support wheels in buildroot at the moment, only sdists with setup.py).

I don't see any downside to including a setup.py for those that need it for bootstrapping, at least until the tooling situation improves a bit more(pep-517 tooling is still pretty bad for complex cross compilation scenarios in buildroot from what I can tell).

For now I'm having to use a version from before setup.py was removed since it's creating a recursive dependency issue for bootstrapping flit.

@hukkin
Copy link
Owner

hukkin commented Nov 29, 2021

I really don't have much to add to #122 (comment) and it even suggests a couple ways to solve your problem. Also note that there's like 40 distros/projects successfully repackaging Tomli already. Maybe you can learn from their processes.

I have no interest in maintaining a setup.py in this project. If you do then please make a fork, the license is MIT, you're welcome!

@hukkin hukkin closed this as completed Nov 29, 2021
@jameshilliard
Copy link
Author

jameshilliard commented Nov 29, 2021

I have no interest in maintaining a setup.py in this project.

Still not sure how one flag for flit is a maintenance burden at all.

You should probably remove this comment then:

If you're a packager and absolutely need this file, please create an issue.

@hukkin
Copy link
Owner

hukkin commented Nov 29, 2021

Still not sure how one flag for flit is a maintenance burden at all.

It isn't except when Python 3.12 is released and the setup.py stops working. Please read #122 (comment). Also I don't currently use flit as build frontend, I use build so I'd need to change that.

You should probably remove this comment then:

Yeah maybe I should. The thing is I'm not very convinced you have an absolute need for this file. Why can't you add a one-liner setup.py yourself for building? Why can't you have wheel support? Are you sure you even need to build a package that is pure Python?

@jameshilliard
Copy link
Author

It isn't except when Python 3.12 is released and the setup.py stops working.

Hopefully by then the tooling will have matured more, but it would be nice if the migration path wasn't so horribly complex, python cross compilation is a huge hacky mess and difficult to maintain as is.

Isn't python 3.12 something like 2 years away from being released anyways? I mean python 3.11(last version compatible with distutils) isn't even going to be EOL until 2027 looks like....so seems a bit premature removing setup.py when that is the case.

The thing is I'm not very convinced you have an absolute need for this file. Why can't you add a one-liner setup.py yourself for building?

Obviously I can make some ugly unmaintainable temporary hack if I have to, but that sort of thing tends to cause issues whenever we make changes to our tooling.

Why can't you have wheel support? Are you sure you even need to build a package that is pure Python?

We cross compile all packages so there wasn't much point since wheels are inherently incompatible with cross compilation for packages with c extensions...and we really don't want to special case pure-python packages for complexity reasons.

@hukkin hukkin added duplicate This issue or pull request already exists question Further information is requested labels Dec 16, 2021
@jameshilliard
Copy link
Author

So rather than include a setup.py maybe tomli should be fixed so that it complies with the PEP-517 Build Requirements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants