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

Ignore irrelevant files when uploading #855

Closed
dukecat0 opened this issue Jan 10, 2022 · 5 comments
Closed

Ignore irrelevant files when uploading #855

dukecat0 opened this issue Jan 10, 2022 · 5 comments

Comments

@dukecat0
Copy link
Member

dukecat0 commented Jan 10, 2022

The Issue

Just a feature request here:

When some irrelevant files are generated in dist/ when running CI, uploading it will error out. Example: pypa/gh-action-pypi-publish#74

Is it possible for us to have a command-line argument like --ignore-irrelevant-files?
As I think twine only supports these six formats:

twine/twine/package.py

Lines 35 to 42 in ce87465

DIST_EXTENSIONS = {
".whl": "bdist_wheel",
".exe": "bdist_wininst",
".egg": "bdist_egg",
".tar.bz2": "sdist",
".tar.gz": "sdist",
".zip": "sdist",
}

@sigmavirus24
Copy link
Member

This seems related to #853

@bhrutledge
Copy link
Contributor

Yeah, from pypa/gh-action-pypi-publish#74, I don't know why *.dist-info would be ending up in the dist/ directory. That sounds like a symptom of a configuration issue, which I'm more inclined to resolve with the submitter, rather than add what feels like a hack to ignore it.

@sigmavirus24
Copy link
Member

@meowmeowmeowcat do you also encounter this issue or were you looking for things to fix?

@dukecat0
Copy link
Member Author

I didn't encounter this issue. And I also found that the command provided by @bhrutledge in pypa/gh-action-pypi-publish#74 is useful, so probably this feature is unnecessary.

@webknjaz
Copy link
Member

FTR, it turned out to be meson's PEP 517 build back-end that creates *.dist-info/ folders under the dist/ directory. A quick search suggests that these lines are to blame: https://gitlab.com/thiblahute/mesonpep517/-/blob/fe3b0086/mesonpep517/buildapi.py#L648-650.

I've filed a bug with them at https://gitlab.com/thiblahute/mesonpep517/-/issues/22 if anybody wants to discuss it there.

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

No branches or pull requests

4 participants