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

Automatically register the encoding using a "pth" file. #13

Open
amcgregor opened this issue Dec 3, 2015 · 3 comments
Open

Automatically register the encoding using a "pth" file. #13

amcgregor opened this issue Dec 3, 2015 · 3 comments

Comments

@amcgregor
Copy link
Member

This allows us to execute the encoding import and registration on Python startup.

An example approach can be seen in the setup.py for pytest-cov.

@amcgregor
Copy link
Member Author

This would appear to be an anti-feature. While it does in theory provide some convenience for users of the library, the headaches involving the astoundingly stupid mechanism of pth files outweigh the benefit. Add one and the test coverage requires wrapping in a call to pytest-cov in order to capture the initial import, but only if our file is named something like zzpluralzalpha.pth in order to ensure ours sorts lexicographically after pytest.pth. Patches welcome, but I won't overly encourage this.

@ionelmc
Copy link

ionelmc commented Dec 5, 2015

Is this „patches welcome” or „closed/nope”? Reopen if you want patches.

@amcgregor
Copy link
Member Author

This is "patches welcome" but not "help wanted". I'm not going to encourage this kind of terribly fragile feature, but there's not much I can do to stop someone from writing it and submitting a pull request. (Pull requests are their own tickets.)

@amcgregor amcgregor reopened this Nov 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants