[issue35622] RFE: Add os.sched_setattr() and os.sched_getattr() functions

2019-01-05 Thread Michael Büsch
Michael Büsch added the comment: I would like to implement this feature. So if somebody thinks that it's a bad idea to have this feature, please speak up now. -- nosy: +vstinner ___ Python tracker <https://bugs.python.org/is

[issue35622] Add support for Linux SCHED_DEADLINE

2018-12-30 Thread Michael Büsch
New submission from Michael Büsch : Are there plans to support Linux SCHED_DEADLINE in the os module? If not, would changes to add such support be welcome? Support for SCHED_DEADLINE would also need support for sched_setattr/sched_getattr. -- components: Library (Lib) messages: 332772

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-22 Thread Michael Büsch
Michael Büsch added the comment: >an implementation of the vastly *less* common pattern: Ok, here are some numbers. My codebase is about 32 kLOC. $ git grep suppressAllExc |wc -l 20 $ git grep contextlib\\.suppress |wc -l 17 (suppressAllExc being my local version to suppress Exception,

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-20 Thread Michael Büsch
Michael Büsch added the comment: >when particular instances of "catch this exception, but not these ones" become >common, we tend to *change the standard exception hierarchy* to eliminate them >(e.g. StopIteration, KeyboardError, GeneratorExit no longer inheriting from &

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-20 Thread Michael Büsch
Michael Büsch added the comment: >and instead point you towards https://bugs.python.org/issue12029 Fair enough. But how would a 'suppress OSError, but catch FileNotFoundError' look like with this for example? (Note that I can't subclass the exception) >I'm also

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-20 Thread Michael Büsch
Michael Büsch added the comment: Thanks for your comments. Here's version 2 of the patch. Changes: - A typo in the docstring was fixed. - Space was removed in keyword assignments. - Documentation was added. (Note that I signed and sent the contributor agreement. It should arrive

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-20 Thread Michael Büsch
Michael Büsch added the comment: >Could you please produce a patch that conforms to PEP-8. I tried hard to do so. Could you please tell me what parts are not compliant, so I can fix them? -- ___ Python tracker <http://bugs.python.org/issu

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-20 Thread Michael Büsch
Changes by Michael Büsch : -- nosy: +rhettinger ___ Python tracker <http://bugs.python.org/issue27814> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27814] contextlib.suppress: Add whitelist argument

2016-08-20 Thread Michael Büsch
New submission from Michael Büsch: This adds a whitelist parameter with the name 'unless' to contextlib.suppress, so one can specify exceptions that will not be suppressed. This is useful for specifying single sub-exceptions that we still want to catch, even of we want to suppress

[issue22103] bdist_wininst does not run install script

2014-07-29 Thread Michael Büsch
New submission from Michael Büsch: The bdist_wininst installer does not run the specified --install-script. Attached is an example project foo.zip. setup.py is invoked as follows: py setup.py bdist_wininst --install-script foo_postinstall.py The installer shows that it successfully ran the