Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.
Sign upMake closing stdin optional? #22
Comments
This comment has been minimized.
This comment has been minimized.
|
I'm not entirely sure why it was introduced in the first place; I'd likely prefer to consider modules messing with stdin outside their I think it would be acceptable to make the default remain open and only close it upon |
This comment has been minimized.
This comment has been minimized.
|
I agree that these modules are misbehaving, but I can't really control dependencies of dependencies :) I'll try to get a PR in today, leaving the current behaviour on by default but allowing for it to be disabled. |
This comment has been minimized.
This comment has been minimized.
|
I'm happy with inverting the default. We've made some best-effort incompatibility changes recently, so this won't strike anyone as odd. Times were different when this was introduced. |
nicolaskruchten commentedFeb 5, 2019
For the module I'm working on, this defensive line is actually breaking things because a dependency of a dependency is checking if
stdinis open: https://github.com/pdoc3/pdoc/blob/master/pdoc/cli.py#L285Would it be possible to allow this behaviour to be turned off via a flag or environment variable? If you'd accept such a PR I'd be happy to contribute it :)