Felix C. Stegerman added the comment:
> specified_attributes = True is also set in xml.dom.expatbuilder.
That's good to know and should perhaps be addressed as well.
> Should not it be set to true in the C implementation of ElementTree?
That would break existing code. Including mi
New submission from Felix C. Stegerman :
I originally reported this as a bug in PyPy, but it turns out that CPython's C
implementation (_elementtree) behaves differently than the pure Python version
(b/c it sets specified_attributes = 1).
PyPy issue with example code: https
Change by Felix C. Stegerman :
--
keywords: +patch
pull_requests: +21901
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/22987
___
Python tracker
<https://bugs.python.org/issu
Felix C. Stegerman added the comment:
https://github.com/obfusk/apksigcopier currently produces reproducible ZIP
files identical to those produced by apksigner using this code:
DATETIMEZERO = (1980, 0, 0, 0, 0, 0)
class ReproducibleZipInfo(zipfile.ZipInfo):
"""Repro
Felix C. Stegerman added the comment:
Hi! I've been working on reproducible builds for python-for-android [1,2,3].
Current issues with .pyc files are:
* .pyc files differ depending on whether Python was compiled w/ liblzma-dev
installed or not;
* many .pyc files include build paths;
* some
Change by Felix C. Stegerman :
--
nosy: +obfusk
___
Python tracker
<https://bugs.python.org/issue29708>
___
___
Python-bugs-list mailing list
Unsubscribe:
Felix C. Stegerman added the comment:
I've closed the PR for now.
Using a carefully crafted ZipInfo object doesn't work because ZipFile modifies
its .external_attr when set to 0.
Using something like this quickly hacked together ZipInfo subclass does work:
class ZeroedZipInfo
Felix C. Stegerman added the comment:
> external_attr == 0 may cause issues with permissions.
That may be true in some scenarios, but not being able to set it to 0 means you
can't create identical files to those produced by other tools -- like those
used to generate APKs -- which do in f
Change by Felix C. Stegerman :
--
keywords: +patch
pull_requests: +23737
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/24979
___
Python tracker
<https://bugs.python.org/issu
Felix C. Stegerman added the comment:
I've created a draft PR; RFC :)
Also:
* setting the date to (1980,0,0,0,0,0) already works;
* the main issue seems to be that external_attr cannot be 0 atm.
--
___
Python tracker
<https://bugs.python.
Change by Felix C. Stegerman :
--
components: +Library (Lib)
___
Python tracker
<https://bugs.python.org/issue43547>
___
___
Python-bugs-list mailing list
Unsub
Change by Felix C. Stegerman :
--
components: -IO, Library (Lib)
versions: -Python 3.6, Python 3.7, Python 3.8, Python 3.9
___
Python tracker
<https://bugs.python.org/issue43
Change by Felix C. Stegerman :
--
type: -> enhancement
___
Python tracker
<https://bugs.python.org/issue43547>
___
___
Python-bugs-list mailing list
Un
Felix C. Stegerman added the comment:
> 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 specifi
Change by Felix C. Stegerman :
--
nosy: +obfusk
___
Python tracker
<https://bugs.python.org/issue43547>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Felix C. Stegerman :
--
nosy: +obfusk
___
Python tracker
<https://bugs.python.org/issue2824>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Felix C. Stegerman :
--
nosy: +obfusk
___
Python tracker
<https://bugs.python.org/issue37596>
___
___
Python-bugs-list mailing list
Unsubscribe:
17 matches
Mail list logo