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

BLD: Enable PEP 517 #39415

Closed
fangchenli opened this issue Jan 26, 2021 · 6 comments
Closed

BLD: Enable PEP 517 #39415

fangchenli opened this issue Jan 26, 2021 · 6 comments
Labels
Build Library building on various platforms Needs Discussion Requires discussion from core team before further action

Comments

@fangchenli
Copy link
Member

After #38852, we could enable PEP 517 by modifying PATH in setup.py or use non-vendored versioneer. See python-versioneer/python-versioneer#193 for details.

@fangchenli fangchenli added Bug Needs Triage Issue that has not been reviewed by a pandas team member Build Library building on various platforms Needs Discussion Requires discussion from core team before further action and removed Bug Needs Triage Issue that has not been reviewed by a pandas team member labels Jan 26, 2021
@andriyor
Copy link

I will recommend switching to setuptools_scm how it was done in matplotlib matplotlib/matplotlib#18971

@fangchenli
Copy link
Member Author

I will recommend switching to setuptools_scm how it was done in matplotlib matplotlib/matplotlib#18971

We hope to get the complete git commit hash, but not sure how to do that using setuptools_scm. I opened an issue pypa/setuptools-scm#577 for this.

@jules-ch
Copy link

We can retrieve full commit hash, using setuptools-scm with the following config:

[tool.setuptools_scm]
git_describe_command = [
            "git",
            "describe",
            "--dirty",
            "--tags",
            "--abbrev=40",
            "--long",
            "--match",
            "*[0-9]*",
        ]

This will overide the default git describe command used by setuptools-scm to get the full (40 digits long hex hash).
Then writing a template to generate the same output as today in _version.py should work.

@fangchenli
Copy link
Member Author

@jules-ch Thanks for this. I posted the link to your comment in the corresponding setuptools_scm issue. Hope they can incorporate this to setuptools_scm as a simple setting.

And in the meantime, a PR is welcome if you want to give this a try^^

@nathanjmcdougall
Copy link

nathanjmcdougall commented Oct 19, 2022

It is worth noting that as of v0.24 versioneer can be non-vendored, closing this issue:
python-versioneer/python-versioneer#193
If the plan is to move away from versioneer altogether, it may be worth updating this comment accordingly:

pandas/pyproject.toml

Lines 10 to 12 in 75429df

# uncomment to enable pep517 after versioneer problem is fixed.
# https://github.com/python-versioneer/python-versioneer/issues/193
# build-backend = "setuptools.build_meta"

@fangchenli
Copy link
Member Author

closed by #49115

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Library building on various platforms Needs Discussion Requires discussion from core team before further action
Projects
None yet
Development

No branches or pull requests

4 participants