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.
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
Add test for package readme syntax errors #492
Add test for package readme syntax errors #492
Changes from 5 commits
26bddb7
9ddbfd8
3106f85
4383e22
c85cea4
d549f38
1c46821
2b6d1d6
05aafa0
14867bc
223fcf2
2be6971
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
I would move this check under the
if not is_valid_rst
(or in a try/except around it). We should first try to parse the readme, and if parsing failed we check to see if a nonexistent file was the reason.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.
Any reason not to treat this as an error and exit as above? I would assume we'd want a README.rst for all packages.
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.
The package does not technically need to have a README.rst. The file could be named differently, it could be an markdown or plain text file, or the description could be embedded inline, instead of in a separate file.
testutil
does not have a README and seems to be marked for deletion (#374 5.), so I felt this behavior might be desirable.If someone adds a README.rst it will get checked, and if they do not include a README.rst we just assume that the package is still WIP and/or will not be uploaded to PyPI. If there is another README file the warning basically indicates departure from implicit convention.
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.
We can just force everyone to put the readme in README.rst. If we want to allow README.md, then this tool will need to support it too.
If we want to exclude packages, I think we can add the exclusion list to eachdist.ini (but I'm not sure if it has support for configured exclusions yet).
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.
Exclusions do not seem to be supported, so I added a README to the
testutil
package for now.