Author conchylicultor
Recipients conchylicultor
Date 2020-10-15.12:03:28
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1602763408.56.0.61735130641.issue42043@roundup.psfhosted.org>
In-reply-to
Content
Currently, zipfile.Path inheritance behavior is inconsistent with pathlib.Path:

```
class MyPath(zipfile.Path):
  pass


path = MyPath(zf)
path = path.joinpath('other')
assert isinstance(path, MyPath)  # Oups, type(path) is zipfile.Path
```

Calling parent, /,... should keep the class, as for pathlib.Path

Use case: I'm writing a wrapper around `zipfile.Path` which adds `os.fspath` compatibility (the file is extracted in a tmp dir when os.path.join, open,...).
History
Date User Action Args
2020-10-15 12:03:28conchylicultorsetrecipients: + conchylicultor
2020-10-15 12:03:28conchylicultorsetmessageid: <1602763408.56.0.61735130641.issue42043@roundup.psfhosted.org>
2020-10-15 12:03:28conchylicultorlinkissue42043 messages
2020-10-15 12:03:28conchylicultorcreate