PMXBOT Log file Viewer

Help | Karma | Search:

#pypa logs for Sunday the 16th of February, 2020

(Back to #pypa overview) (Back to channel listing) (Animate logs)
[03:21:07] <Wulf> Hello! How can I specify extra requirements in poetry's pyproject.toml? I need this to work: pip install pkg[foo]
[05:03:50] <toad_polo> Wulf: poetry is not a pypa project.
[05:04:14] <toad_polo> I've never seen anyone involved in it in this room.
[06:48:06] <Wulf> toad_polo: Then I apologise for asking.
[12:34:54] <dustfinger> PEP-420 - Differences between namespace packages and regular packages (https://www.python.org/dev/peps/pep-0420/#id27) states that: Namespace packages' __path__ attribute is a read-only iterable of strings, which is automatically updated when the parent path is modified.
[12:34:54] <dustfinger> I tested this and found that __path__ is not readonly.
[12:36:44] <dustfinger> What is the expected behavior? Should it be not possible to set __path__ to a different value? Should it be not possible to set a item in __path__ to something new? How is __path__ meant to be readonly?
[16:37:06] <tos9> dustfinger: I don't know the answer / intention, but "read only" does not to me have to mean "you can't write to it", it just means "you should not", and doing so does not have to produce any sensical result
[16:37:27] <tos9> (E.g. locals() is "read only" even though it's a dict and you can write to it -- doing so is just nonsensical and doesn't do anything useful)
[18:29:36] <pradyunsg> dustfinger: +1 to what tos9 said. It's related to how Python's "consenting adults" approach works - making __path__ a non-writable attribute could be difficult+complex to actually implement, and it's better to not introduce that complexity and instead rely on documenting that the user should only read from it. It's considered reasonable to expect that the user wouldn't actually do things beyond the what's been
[18:29:36] <pradyunsg> established by the standard (since that's *technically* undefined).
[19:54:59] <dustfinger> tos9: pradyunsg: Thank you both. That makes sense.
[21:19:30] <dustfinger> Is anyone here familiar with pip #6055? I created a project that reproduces the issue for PEP-420 implicit namespaces https://github.com/BloggerBust/test_pep_420. In the comments for pip #6055 daa suggested that it is not a pip issue, but rather a setuptools issue. Thoughts?