Message389392
> The __getattr__ hack is not needed. You can reset the flags in a different, more straight forward way
As mentioned, ZipFile._open_to_write() will modify the ZipInfo's .external_attr when it is set to 0.
> I just found another specific example in _open_to_write(). 0 is a valid value for zinfo.external_attr. But this code always forces 0 to something else:
>
> if not zinfo.external_attr:
> zinfo.external_attr = 0o600 << 16 # permissions: ?rw-------
Your alternative doesn't seem to take that subsequent modification into account. |
|
Date |
User |
Action |
Args |
2021-03-23 15:26:22 | obfusk | set | recipients:
+ obfusk, christian.heimes, jondo, eighthave |
2021-03-23 15:26:22 | obfusk | set | messageid: <1616513182.97.0.261467025139.issue43547@roundup.psfhosted.org> |
2021-03-23 15:26:22 | obfusk | link | issue43547 messages |
2021-03-23 15:26:22 | obfusk | create | |
|