[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-23 Thread Géry

Géry  added the comment:

Thanks @barry for reviewing and merging PR 15190

> I haven't merged PR 10016, but I left some additional comments.  Are you 
> still interested in shepherding this PR?

Also thanks for helping me with @ericsnowcurrently advancing this last PR. Yes 
I am still interested, I have reviewed all the comments and updated the whole 
thing, doing my best to keep the two descriptions of the module attributes and 
spec attributes consistent since this PEP updates both descriptions.

--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread Barry A. Warsaw


Barry A. Warsaw  added the comment:

@maggyero - I haven't merged PR 10016, but I left some additional comments.  
Are you still interested in shepherding this PR?

--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread miss-islington


miss-islington  added the comment:


New changeset 6e842bcdf8a47fe081c9f2edc2b8875e1f3e2f18 by Miss Skeleton (bot) 
in branch '3.9':
bpo-35181: Correct importlib documentation for some module attributes (GH-15190)
https://github.com/python/cpython/commit/6e842bcdf8a47fe081c9f2edc2b8875e1f3e2f18


--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread miss-islington


miss-islington  added the comment:


New changeset 916ac9520108831d2099b13992a45884b112b193 by Miss Skeleton (bot) 
in branch '3.8':
bpo-35181: Correct importlib documentation for some module attributes (GH-15190)
https://github.com/python/cpython/commit/916ac9520108831d2099b13992a45884b112b193


--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21815
pull_request: https://github.com/python/cpython/pull/22873

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21814
pull_request: https://github.com/python/cpython/pull/22872

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread miss-islington

miss-islington  added the comment:


New changeset 27f1bd8787d24ac53cc3dc6ea5eb00b8a3499839 by Géry Ogam in branch 
'master':
bpo-35181: Correct importlib documentation for some module attributes (GH-15190)
https://github.com/python/cpython/commit/27f1bd8787d24ac53cc3dc6ea5eb00b8a3499839


--
nosy: +miss-islington

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2020-10-21 Thread Barry A. Warsaw


Barry A. Warsaw  added the comment:

Apologies for the long delay in reviewing this bug.  I'm looking at it now, 
however since Python 3.7 is in security-only mode, this will only apply to 
3.10, 3.9, and 3.8.

--
versions: +Python 3.10, Python 3.9 -Python 3.7

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2019-08-09 Thread Géry

Change by Géry :


--
pull_requests: +14922
pull_request: https://github.com/python/cpython/pull/15190

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2019-06-23 Thread Géry

Géry  added the comment:

Oops, sorry, only one of the two PRs has been merged.

--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2019-06-23 Thread Géry

Géry  added the comment:

@Julien, @Barry

Now that the PRs are merged, I think that we can close this issue.

--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2019-04-30 Thread Barry A. Warsaw

Barry A. Warsaw  added the comment:

I've approved both PRs, however I am rather uncomfortable about the code 
snippet in import.rst.  Géry's change is a good one AFAICT, and thanks for the 
contribution!  I would feel much better about the long term correctness of this 
code snippet if we had a doctest to run over it.  But that's for another time.

--

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2019-04-27 Thread Brett Cannon


Change by Brett Cannon :


--
assignee: docs@python -> barry

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2019-04-09 Thread Cheryl Sabella


Cheryl Sabella  added the comment:

@barry, you started a review of PR10016 and I believe all your requested 
changes have been made, so please review again when you get a chance.  Please 
also take a look at PR10376.  Thanks!

--
nosy: +cheryl.sabella
type:  -> enhancement
versions: +Python 3.8

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2018-11-22 Thread Géry

Change by Géry :


--
nosy: +eric.smith

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2018-11-07 Thread Géry

Géry  added the comment:

It looks like Barry Warsaw has not been fully updated the documentation after 
making the __spec__.loader attribute match with the __loader__ attribute, and 
the __spec__.file attribute match with the __file__ attribute for namespace 
packages.

Here is a pull request to update the library documentation of importlib (your 
first link [1]) with the current Barry's implementation:
https://github.com/python/cpython/pull/10016

Here is another pull request to update the reference documentation of the 
import system (your second link [2], but for a different paragraph, as I think 
the "To indicate to the import machinery that the spec represents a namespace 
portion the path entry finder sets “loader” on the spec to None" sentence is 
correct, since the `_bootstrap.ModuleSpec.loader` attribute of a namespace 
package remains `None` until the call to the 
`importlib._bootstrap._init_module_attrs` function):
https://github.com/python/cpython/pull/10376

--
nosy: +brett.cannon, eric.snow, maggyero, ncoghlan

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2018-11-07 Thread Géry

Change by Géry :


--
pull_requests: +9678

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2018-11-07 Thread Géry

Change by Géry :


--
keywords: +patch
pull_requests: +9677
stage:  -> patch review

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2018-11-06 Thread Barry A. Warsaw


Change by Barry A. Warsaw :


--
nosy: +barry

___
Python tracker 

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



[issue35181] Doc: Namespace Packages: Inconsistent documentation of __loader__ being None

2018-11-06 Thread Julien Palard

New submission from Julien Palard :

The documentation states that a __loader__ of a namespace package should be 
None:

- [1] "For namespace packages this should be set to None."
- [2] "To indicate to the import machinery that the spec represents a namespace 
portion. the path entry finder sets “loader” on the spec to None".

But this looks wrong [3], looks like it has been changed in [4]/[5].

I think one should rely on __file__ being None on namespace packages (which 
make sense as they span over multiple directories) instead of __loader__ being 
None (a side effect of the import machinery ?).


[1]: 
https://docs.python.org/3/library/importlib.html#importlib.machinery.ModuleSpec.loader
[2]: https://docs.python.org/3/reference/import.html#path-entry-finder-protocol
[3]: 
https://stackoverflow.com/questions/52869541/namespace-package-spec-loader-and-loader-attributes-not-set-to-none
[4]: https://bugs.python.org/issue32303
[5]: 
https://github.com/python/cpython/pull/5481/files#diff-a6592cec2ebc8dba9bbf7d396370b138L319

--
assignee: docs@python
components: Documentation
messages: 329392
nosy: docs@python, mdk
priority: normal
severity: normal
status: open
title: Doc: Namespace Packages: Inconsistent documentation of __loader__ being 
None
versions: Python 3.7

___
Python tracker 

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