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 setup.cfg with adding python_requires #101

Merged
merged 7 commits into from
Feb 5, 2021
Merged

Use setup.cfg with adding python_requires #101

merged 7 commits into from
Feb 5, 2021

Conversation

chezou
Copy link
Member

@chezou chezou commented Feb 2, 2021

This PR to use setup.cfg instead of setup.py also adding python_requires, describing explicit supported version for Python

To use attr: pytd.__version__, we need to stop importing .client in
__init__.py. This introduces incompatible change than benefit, so
changes to write version number in setup.cfg explicitly.
@@ -1,3 +1,52 @@
[metadata]
name = pytd
version = 1.4.0
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately version = attr: pytd.__version__ doesn't work well while there was improvement for it
https://stackoverflow.com/questions/58202909/modulenotfounderror-when-using-setup-cfg-and-version-accessed-with-attr
pypa/setuptools#1753

@chezou
Copy link
Member Author

chezou commented Feb 2, 2021

Hmm, we hit TypeError: Cannot interpret '<attribute 'dtype' of 'numpy.generic' objects>' as a data type error. Maybe numpy 1.20.0 release affects it.

@chezou chezou requested a review from takuti February 2, 2021 05:53
@chezou chezou changed the title Use setup.cfg adding python_requires Use setup.cfg with adding python_requires Feb 2, 2021
Comment on lines 77 to 79
.. code:: py

__version__ = "1.0.0"
version = 1.0.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's make it more interpretable as setup.cfg

.. code:: ini

   [metadata]
   name = pytd
   version = 1.0.0

setup.py Outdated
Comment on lines 7 to 9
a shorter time. It eventually makes your day-to-day data analytics work more
efficient and productive.
"""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the config file no longer refers __doc__, we can delete the top-level statements.

@chezou
Copy link
Member Author

chezou commented Feb 5, 2021

Thanks, applied feedbacks on 865e9df

@chezou chezou merged commit e72ccbd into master Feb 5, 2021
@chezou chezou deleted the setupcfg branch February 5, 2021 01:48
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.

2 participants