[issue35486] subprocess module import hooks breaks back compatibility

2019-01-22 Thread Nick Coghlan


Nick Coghlan  added the comment:

Aye, we can :)

--
assignee:  -> docs@python
components: +Documentation -Library (Lib)
nosy: +docs@python
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread Ned Deily


Ned Deily  added the comment:

I've merged the doc changes for 3.6, thanks.  Can we close this now?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread Ned Deily


Ned Deily  added the comment:


New changeset 1edb3dc6ff70db88a7e89586578e58a86ee0e75e by Ned Deily (Miss 
Islington (bot)) in branch '3.6':
bpo-35486: Note Py3.6 import system API requirement change (GH-11540) (GH-11588)
https://github.com/python/cpython/commit/1edb3dc6ff70db88a7e89586578e58a86ee0e75e


--
nosy: +ned.deily

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


miss-islington  added the comment:


New changeset 422db3777874f4f31fc8f4e718f440a2abc59347 by Miss Islington (bot) 
in branch '3.7':
bpo-35486: Note Py3.6 import system API requirement change (GH-11540)
https://github.com/python/cpython/commit/422db3777874f4f31fc8f4e718f440a2abc59347


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


Change by miss-islington :


--
pull_requests: +11279, 11280, 11281, 11282, 11283

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


Change by miss-islington :


--
pull_requests: +11278, 11279, 11280

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


Change by miss-islington :


--
pull_requests: +11279, 11280, 11281, 11283

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


Change by miss-islington :


--
pull_requests: +11279, 11280, 11283

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


miss-islington  added the comment:


New changeset cee29b46a19116261b083dc803217aa754c7df40 by Miss Islington (bot) 
(Nick Coghlan) in branch 'master':
bpo-35486: Note Py3.6 import system API requirement change (GH-11540)
https://github.com/python/cpython/commit/cee29b46a19116261b083dc803217aa754c7df40


--
nosy: +miss-islington

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


Change by miss-islington :


--
pull_requests: +11278, 11279

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-17 Thread miss-islington


Change by miss-islington :


--
pull_requests: +11278

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-12 Thread Nick Coghlan


Nick Coghlan  added the comment:

dw: we routinely impose new requirements on folks modifying runtime internals 
in new feature releases, so the only aspect we missed for this changing is to 
explicitly call it out in the Porting section of the Python 3.6 What's New 
document as a potential forward compatibility risk for import system 
replacement authors that don't update their plugins accordingly.

For folks implementing PEP 302 finders and loaders, no change is required, as 
they indicate failure to find a module by returning None, not by raising 
ImportError.

It's only folks emulating the full import system by replacing `__import__` that 
should need to worry about this.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-12 Thread Nick Coghlan


Change by Nick Coghlan :


--
keywords: +patch, patch
pull_requests: +11147, 11148
stage: test needed -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-12 Thread Nick Coghlan


Change by Nick Coghlan :


--
keywords: +patch, patch, patch
pull_requests: +11147, 11148, 11149
stage: test needed -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-12 Thread Nick Coghlan


Change by Nick Coghlan :


--
keywords: +patch
pull_requests: +11147
stage: test needed -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2019-01-08 Thread David Wilson


David Wilson  added the comment:

Hi Nick,

The purpose of ModuleNotFoundError is clear and unrelated to the problem 
documented here. The problem is that due to the introduction of 
ModuleNotFoundError, ImportError's semantics have been changed within a minor 
release in a breaking, backwards-incompatible manner.

As of Python 3.5, ImportError meant both "ImportError" and 
"ModuleNotFoundError". As of 3.6, the senses are distinct, and thus code 
written against ImportError as it existed in 3.5 no longer works correctly as 
of 3.6.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2018-12-19 Thread Nick Coghlan


Nick Coghlan  added the comment:

Note that the above distinction is also the rationale for introducing the new 
subtype: so that it's easy to tell the difference between "that module was not 
found at all" (ModuleNotFoundError) and "the module was found, but attempting 
to actually load it failed" (other cases of ImportError)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2018-12-19 Thread Nick Coghlan


Nick Coghlan  added the comment:

The two errors mean different things: ModuleNotFoundError means literally that 
the module could not be found at all (i.e. no import hook offered to try to 
load it)

A plain ImportError then means that the module was located, but attempting to 
actually load it failed.

find_spec()/find_loader()/find_module() implementations on import plugins 
shouldn't be raising exceptions for modules they don't offer, and hence 
shouldn't be needing to raise ModuleNotFoundError directly.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2018-12-17 Thread Brett Cannon


Brett Cannon  added the comment:

RE: "PEP-302 and PEP-451 are the definitive specifications for how 
sys.meta_path is supposed to work"

That's actually not true. In the case of import the language reference is 
considered the reference for import: 
https://docs.python.org/3/reference/import.html (and true for PEPs in general 
once they are implemented).

--
nosy: +davin

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35486] subprocess module import hooks breaks back compatibility

2018-12-14 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
nosy: +brett.cannon, eric.snow, ncoghlan
stage:  -> test needed
title: subprocess module breaks backwards compatibility with import hooks -> 
subprocess module import hooks breaks back compatibility
type:  -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com