[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-31 Thread Nick Coghlan
Nick Coghlan added the comment: Reviewing Rémi's page made me realise that a big part of the root cause here is pickle support in exceptions predating the introduction of `__getnewargs__` and `__getnewargs_ex__`. -- nosy: +ncoghlan ___ Python

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-31 Thread Nick Coghlan
Change by Nick Coghlan : -- pull_requests: -11260 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-31 Thread Nick Coghlan
Change by Nick Coghlan : -- pull_requests: -11261 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-16 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: I tried to fix the issue, the attached PR solves the issue of saving the kwargs and unpickling the exception but I was not able to fix a regression I caused in test_memory_error_in_PyErr_PrintEx. -- versions: +Python 3.6, Python 3.7, Python 3.8

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-16 Thread Rémi Lapeyre
Change by Rémi Lapeyre : -- keywords: +patch, patch, patch pull_requests: +11260, 11261, 11262 stage: -> patch review ___ Python tracker ___

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-16 Thread Rémi Lapeyre
Change by Rémi Lapeyre : -- keywords: +patch, patch pull_requests: +11260, 11261 stage: -> patch review ___ Python tracker ___ ___

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-16 Thread Rémi Lapeyre
Change by Rémi Lapeyre : -- keywords: +patch pull_requests: +11260 stage: -> patch review ___ Python tracker ___ ___

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2019-01-11 Thread Rémi Lapeyre
Change by Rémi Lapeyre : -- nosy: +remi.lapeyre ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2016-05-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is a problem not only with CalledProcessError, but with all custom exceptions with overridden __init__. BaseException.__new__ saves positional arguments as the "args" attribute, but ignores keyword arguments. repr() and pickle use "args". --

[issue27015] subprocess.CalledProcessError's repr changes based on kwargs, and doesn't unpickle

2016-05-13 Thread Taywee
New submission from Taywee: When using kwargs to construct a CalledProcessError, the repr doesn't show those args, and using kwargs also breaks pickling: >>> import pickle; from subprocess import CalledProcessError >>> CalledProcessError(2, 'foo') CalledProcessError(2, 'foo') >>>