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

Use declarative setuptools configuration and PyPI build tools #73

Merged
merged 1 commit into from
Apr 14, 2022

Conversation

mwtoews
Copy link
Contributor

@mwtoews mwtoews commented Apr 13, 2022

This converts setup.py to setuptools' declarative configuration setup.cfg file. Other changes:

  • Use PyPI's build tool in CI to check package build
  • Update publish guide to recommend using python -m build and twine check dist/*
  • Add empty file xmipy/timers/__init__.py so xmipy.timers becomes a submodule
  • setup.py is kept as a shim, but it can be deleted
  • Merge (and delete) contents from .flake8 to setup.cfg to clean-up one file

@codecov
Copy link

codecov bot commented Apr 13, 2022

Codecov Report

Merging #73 (61d8269) into develop (ed8d4c2) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff            @@
##           develop      #73   +/-   ##
========================================
  Coverage    85.87%   85.87%           
========================================
  Files            6        6           
  Lines          439      439           
========================================
  Hits           377      377           
  Misses          62       62           

@Hofer-Julian
Copy link
Contributor

This is strictly better than what we currently have, thanks a lot @mwtoews!

setup.py is kept as a shim, but it can be deleted

Is there a reason to keep it?

@mwtoews
Copy link
Contributor Author

mwtoews commented Apr 14, 2022

Some old versions of pip expect a setup.py, but this is probably not an issue since Python 3.7 is the minimum requirement. So sure, let's remove it. To replicate it, use something like:

python -c "from setuptools import setup; setup()" sdist

@Hofer-Julian Hofer-Julian merged commit 2afeaf6 into Deltares:develop Apr 14, 2022
@pya
Copy link

pya commented Apr 14, 2022

The only reason I am aware of to keep an, essentially empty, setup.py around were editable installs, i.e. pip install --editable. This reason seems to be gone. So, deleting setup.py should be fine.

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.

None yet

3 participants