Skip to content

Allow installation of the project without a setup.py #3095

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

Merged
merged 2 commits into from
Nov 15, 2017

Conversation

agronholm
Copy link
Contributor

With PEP 517, projects may no longer even have one in the future.

With PEP 517, projects may no longer even have one in the future.
@ericholscher
Copy link
Member

Looks good at first glance. Is there a way to verify a package is using the new stuff? I imagine not without executing it, because Python?

@agjohnson
Copy link
Contributor

We could be inspecting setup.cfg for basic required metadata, but that doesn't ensure that setup.py is itself inspecting setup.cfg. We can probably be sure in the majority of cases though, with the exception being a package that moved to setup.py and left stale metadata in the setup.cfg.

@agjohnson
Copy link
Contributor

@agronholm Revisiting this, I think what we want is to either catch the else case and report back to the user, or convert the elif back to else so that we are unconditionally trying to run python setup.py if the user wants the package installed and isn't using pip.

This should throw an error back at the user with setup.py not found, which should be enough. The best user experience here is reporting on what went wrong and how to fix it (disable install project) but we don't have a good pattern for this yet.

@agronholm
Copy link
Contributor Author

We could be inspecting setup.cfg for basic required metadata, but that doesn't ensure that setup.py is itself inspecting setup.cfg. We can probably be sure in the majority of cases though, with the exception being a package that moved to setup.py and left stale metadata in the setup.cfg.

Wait, why would we inspect setup.cfg?

@agronholm Revisiting this, I think what we want is to either catch the else case and report back to the user, or convert the elif back to else so that we are unconditionally trying to run python setup.py if the user wants the package installed and isn't using pip.

Sure, if this is what you want. The current production code does nothing if setup.py is not found, regardless of whether the user has indicated that the project should be installed.

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.

3 participants