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

Migrate to flit_core build system #360

Merged
merged 3 commits into from
Feb 15, 2022
Merged

Migrate to flit_core build system #360

merged 3 commits into from
Feb 15, 2022

Conversation

mgorny
Copy link
Contributor

@mgorny mgorny commented Jan 31, 2022

Fixes #357

@mgorny
Copy link
Contributor Author

mgorny commented Jan 31, 2022

sdist is mostly the same, except for removing setuptools-specific files, adding pyproject.toml and changes in metadata.

Only in old: MANIFEST.in
diff -dupr old/PKG-INFO pyparsing-3.0.7/PKG-INFO
--- old/PKG-INFO	2022-01-31 10:53:11.057560700 +0100
+++ pyparsing-3.0.7/PKG-INFO	1970-01-01 01:00:00.000000000 +0100
@@ -1,13 +1,10 @@
 Metadata-Version: 2.1
 Name: pyparsing
 Version: 3.0.7
-Summary: Python parsing module
-Home-page: https://github.com/pyparsing/pyparsing/
-Download-URL: https://pypi.org/project/pyparsing/
-Author: Paul McGuire
-Author-email: ptmcg.gm+pyparsing@gmail.com
-License: MIT License
-Platform: UNKNOWN
+Summary: pyparsing module - Classes and methods to define and execute parsing grammars
+Author-email: Erik Rose <erikrose@grinchcentral.com>
+Requires-Python: >=3.6
+Description-Content-Type: text/x-rst
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Intended Audience :: Developers
 Classifier: Intended Audience :: Information Technology
@@ -23,10 +20,10 @@ Classifier: Programming Language :: Pyth
 Classifier: Programming Language :: Python :: 3 :: Only
 Classifier: Programming Language :: Python :: Implementation :: CPython
 Classifier: Programming Language :: Python :: Implementation :: PyPy
-Requires-Python: >=3.6
-Description-Content-Type: text/x-rst
+Requires-Dist: railroad-diagrams ; extra == "diagrams"
+Requires-Dist: jinja2 ; extra == "diagrams"
+Project-URL: Homepage, https://github.com/pyparsing/pyparsing/
 Provides-Extra: diagrams
-License-File: LICENSE
 
 PyParsing -- A Python Parsing Module
 ====================================
@@ -105,4 +102,3 @@ See `CHANGES <https://github.com/pyparsi
 .. |Coverage| image:: https://codecov.io/gh/pyparsing/pyparsing/branch/master/graph/badge.svg
   :target: https://codecov.io/gh/pyparsing/pyparsing
 
-
Only in old: pyparsing.egg-info
Only in pyparsing-3.0.7: pyproject.toml
Only in old: setup.cfg
Only in old: setup.py

@mgorny
Copy link
Contributor Author

mgorny commented Jan 31, 2022

wheel only differs in metadata:

diff -dupr a/pyparsing-3.0.7.dist-info/METADATA b/pyparsing-3.0.7.dist-info/METADATA
--- a/pyparsing-3.0.7.dist-info/METADATA	2022-01-31 09:53:18.000000000 +0100
+++ b/pyparsing-3.0.7.dist-info/METADATA	2016-01-01 00:00:00.000000000 +0100
@@ -1,13 +1,10 @@
 Metadata-Version: 2.1
 Name: pyparsing
 Version: 3.0.7
-Summary: Python parsing module
-Home-page: https://github.com/pyparsing/pyparsing/
-Download-URL: https://pypi.org/project/pyparsing/
-Author: Paul McGuire
-Author-email: ptmcg.gm+pyparsing@gmail.com
-License: MIT License
-Platform: UNKNOWN
+Summary: pyparsing module - Classes and methods to define and execute parsing grammars
+Author-email: Erik Rose <erikrose@grinchcentral.com>
+Requires-Python: >=3.6
+Description-Content-Type: text/x-rst
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Intended Audience :: Developers
 Classifier: Intended Audience :: Information Technology
@@ -23,12 +20,10 @@ Classifier: Programming Language :: Pyth
 Classifier: Programming Language :: Python :: 3 :: Only
 Classifier: Programming Language :: Python :: Implementation :: CPython
 Classifier: Programming Language :: Python :: Implementation :: PyPy
-Requires-Python: >=3.6
-Description-Content-Type: text/x-rst
-License-File: LICENSE
+Requires-Dist: railroad-diagrams ; extra == "diagrams"
+Requires-Dist: jinja2 ; extra == "diagrams"
+Project-URL: Homepage, https://github.com/pyparsing/pyparsing/
 Provides-Extra: diagrams
-Requires-Dist: railroad-diagrams ; extra == 'diagrams'
-Requires-Dist: jinja2 ; extra == 'diagrams'
 
 PyParsing -- A Python Parsing Module
 ====================================
@@ -107,4 +102,3 @@ See `CHANGES <https://github.com/pyparsi
 .. |Coverage| image:: https://codecov.io/gh/pyparsing/pyparsing/branch/master/graph/badge.svg
   :target: https://codecov.io/gh/pyparsing/pyparsing
 
-
diff -dupr a/pyparsing-3.0.7.dist-info/RECORD b/pyparsing-3.0.7.dist-info/RECORD
--- a/pyparsing-3.0.7.dist-info/RECORD	2022-01-31 09:53:18.000000000 +0100
+++ b/pyparsing-3.0.7.dist-info/RECORD	2016-01-01 00:00:00.000000000 +0100
@@ -11,7 +11,6 @@ pyparsing/util.py,sha256=kq772O5YSeXOSdP
 pyparsing/diagram/__init__.py,sha256=yySG7RAh6JHuM8xewjaZjY4EWlIc6bX6neHxzTOjuoM,22136
 pyparsing/diagram/template.jinja2,sha256=SfQ8SLktSBqI5W1DGcUVH1vdflRD6x2sQBApxrcNg7s,589
 pyparsing-3.0.7.dist-info/LICENSE,sha256=ENUSChaAWAT_2otojCIL-06POXQbVzIGBNRVowngGXI,1023
-pyparsing-3.0.7.dist-info/METADATA,sha256=u3H31Y4UAq3IJaMyDOjbs1vOOtXaEaSlX2yjCt6NXp8,4227
-pyparsing-3.0.7.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
-pyparsing-3.0.7.dist-info/top_level.txt,sha256=eUOjGzJVhlQ3WS2rFAy2mN3LX_7FKTM5GSJ04jfnLmU,10
+pyparsing-3.0.7.dist-info/WHEEL,sha256=jPMR_Dzkc4X4icQtmz81lnNY_kAsfog7ry7qoRvYLXw,81
+pyparsing-3.0.7.dist-info/METADATA,sha256=1F3bj5RyWPn9K7k7XGWljwu2eknhsrlPe8_F4SPHSjs,4172
 pyparsing-3.0.7.dist-info/RECORD,,
Only in a/pyparsing-3.0.7.dist-info: top_level.txt
diff -dupr a/pyparsing-3.0.7.dist-info/WHEEL b/pyparsing-3.0.7.dist-info/WHEEL
--- a/pyparsing-3.0.7.dist-info/WHEEL	2022-01-31 09:53:18.000000000 +0100
+++ b/pyparsing-3.0.7.dist-info/WHEEL	2016-01-01 00:00:00.000000000 +0100
@@ -1,5 +1,4 @@
 Wheel-Version: 1.0
-Generator: bdist_wheel (0.37.1)
+Generator: flit 3.6.0
 Root-Is-Purelib: true
 Tag: py3-none-any
-

@mgorny
Copy link
Contributor Author

mgorny commented Jan 31, 2022

I've tried to preserve the original metadata and sdist contents. One notable difference is description — flit grabs that from pyparsing/__init__.py docstring by default. If you prefer, I can put the old description in explicitly but I've figured out they roughly mean the same.

I haven't touched makeRelease.bat yet as I don't know what environment it's run on and what workflow you prefer. Long story short, two typical options are installing flit and using flit build to create the distribution, or installing build and using python -m build. I've been using the latter.

@ptmcg
Copy link
Member

ptmcg commented Jan 31, 2022

makeRelease.bat can be deleted, I used it when I still building pyparsing on my Windows machine, which I have not done for years. It is way out of date. I do the tox and twine commands manually now, that's really all the automation I need.

In its place, though, could you add a BUILDING file with instructions on testing and building for release?

@mgorny
Copy link
Contributor Author

mgorny commented Feb 5, 2022

Added. Is what you had in mind?

pyproject.toml Outdated Show resolved Hide resolved
@ptmcg
Copy link
Member

ptmcg commented Feb 6, 2022

BUILDING file looks great

@mgorny
Copy link
Contributor Author

mgorny commented Feb 6, 2022

Updated the initial commit and force-pushed.

@ptmcg
Copy link
Member

ptmcg commented Feb 14, 2022

Sorry, I didn't notice that merging the other PR would generate a conflict here. If you can resolve, I'll go ahead and merge next.

@mgorny
Copy link
Contributor Author

mgorny commented Feb 14, 2022

Rebased.

@ptmcg ptmcg merged commit 43b22d9 into pyparsing:master Feb 15, 2022
@mgorny
Copy link
Contributor Author

mgorny commented Feb 15, 2022

Thanks!

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.

Please consider using flit build system to ease setuptools bootstrap
2 participants