-
Notifications
You must be signed in to change notification settings - Fork 22
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
fix: bloating of sdists by setuptools-scm
#195
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The pyproject.toml file is now the single location for the version to be declared. It will be read by __init__.py automatically. The old system used setuptools-scm but apparently that has the unintended side-effect of adding all files tracked by version control to the sdist! yikes Refer to pypa/setuptools-scm#190 for more details
setuptools-scm
I checked that my changes restored the previous sdist contents by comparing the sdist contents before and after:
Click here to view sdist-contents.diff--- /dev/fd/63 2023-11-24 22:32:57.823274914 +0000
+++ /dev/fd/62 2023-11-24 22:32:57.823274914 +0000
@@ -1,12 +1,11 @@
trtools-5.0.2/
trtools-5.0.2/LICENSE.txt
-trtools-5.0.2/MANIFEST.in
trtools-5.0.2/PKG-INFO
trtools-5.0.2/README.rst
+trtools-5.0.2/pyproject.toml
trtools-5.0.2/scripts/
trtools-5.0.2/scripts/trtools_prep_beagle_vcf.sh
trtools-5.0.2/setup.cfg
-trtools-5.0.2/setup.py
trtools-5.0.2/trtools/
trtools-5.0.2/trtools/__init__.py
trtools-5.0.2/trtools/associaTR/
@@ -36,12 +35,24 @@
trtools-5.0.2/trtools/mergeSTR/tests/
trtools-5.0.2/trtools/mergeSTR/tests/__init__.py
trtools-5.0.2/trtools/mergeSTR/tests/test_mergeSTR.py
+trtools-5.0.2/trtools/prancSTR/
+trtools-5.0.2/trtools/prancSTR/__init__.py
+trtools-5.0.2/trtools/prancSTR/prancSTR.py
+trtools-5.0.2/trtools/prancSTR/tests/
+trtools-5.0.2/trtools/prancSTR/tests/__init__.py
+trtools-5.0.2/trtools/prancSTR/tests/test_prancSTR.py
trtools-5.0.2/trtools/qcSTR/
trtools-5.0.2/trtools/qcSTR/__init__.py
trtools-5.0.2/trtools/qcSTR/qcSTR.py
trtools-5.0.2/trtools/qcSTR/tests/
trtools-5.0.2/trtools/qcSTR/tests/__init__.py
trtools-5.0.2/trtools/qcSTR/tests/test_qcSTR.py
+trtools-5.0.2/trtools/simTR/
+trtools-5.0.2/trtools/simTR/__init__.py
+trtools-5.0.2/trtools/simTR/simTR.py
+trtools-5.0.2/trtools/simTR/tests/
+trtools-5.0.2/trtools/simTR/tests/__init__.py
+trtools-5.0.2/trtools/simTR/tests/test_simTR.py
trtools-5.0.2/trtools/statSTR/
trtools-5.0.2/trtools/statSTR/__init__.py
trtools-5.0.2/trtools/statSTR/statSTR.py
@@ -65,7 +76,6 @@
trtools-5.0.2/trtools/utils/tests/test_utils.py
trtools-5.0.2/trtools/utils/tr_harmonizer.py
trtools-5.0.2/trtools/utils/utils.py
-trtools-5.0.2/trtools/version.py
trtools-5.0.2/trtools.egg-info/
trtools-5.0.2/trtools.egg-info/PKG-INFO
trtools-5.0.2/trtools.egg-info/SOURCES.txt |
gymreklab
approved these changes
Nov 27, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this PR!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR #193 introduced a new versioning scheme that used
setuptools-scm
. Unfortunately, it had the unwanted side-effect of adding all files tracked in version control to our source distribution! So we ended up publishing a ~60 MB sdist (instead of the usual ~110 KB sdist) to PyPI. Unfortunately, there isn't currently a way to disable this particular behavior ofsetuptools-scm
-- you can refer to pypa/setuptools-scm#190 for more details.This PR fixes the issue by removing
setuptools-scm
and implementing a new versioning scheme where the pyproject.toml file itself becomes the central location for the version declaration. When we want to release a new version, we'll just need to bump it there.