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

Strip trailing spaces in pydoc #94318

Closed
serhiy-storchaka opened this issue Jun 27, 2022 · 0 comments
Closed

Strip trailing spaces in pydoc #94318

serhiy-storchaka opened this issue Jun 27, 2022 · 0 comments
Labels
type-feature A feature request or enhancement

Comments

@serhiy-storchaka
Copy link
Member

pydoc generates text output which can contain trailing spaces as a result of indentation of an empty line. It causes constant headashe in tests containing the pydoc output, because some editors automatically remove trailing spaces, and trailing spaces are usually difficult to notice. You need to replace trailing spaces with \x20, and do it every time you change the expected output, but since not all editors strip trailing spaces, you can introduce trailing spaces which will be stripped when somebody else edit that file, adding unrelated changes which break tests.

See for example 1a82f7e, but there were more recent examples, and test_enum currently contains trailing spaces.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

1 participant