[Git][reproducible-builds/diffoscope][master] Don't error-out with a traceback if we encounter struct.unpack-related errors...
Chris Lamb (@lamby)
gitlab at salsa.debian.org
Thu Feb 29 11:18:26 UTC 2024
Chris Lamb pushed to branch master at Reproducible Builds / diffoscope
Commits:
466523ac by Chris Lamb at 2024-02-29T11:17:52+00:00
Don't error-out with a traceback if we encounter struct.unpack-related errors when parsing .pyc files. (Closes: Debian:#1064973)
We should actually make the parsing *work*, but at least this won't cause
diffoscope to quit in the meantime.
- - - - -
1 changed file:
- diffoscope/comparators/python.py
Changes:
=====================================
diffoscope/comparators/python.py
=====================================
@@ -55,7 +55,7 @@ class PycFile(File):
source="Python bytecode",
)
]
- except (ValueError, IndexError) as exc:
+ except (ValueError, IndexError, struct.error) as exc:
self.add_comment("Could not decompile bytecode: {}".format(exc))
return []
View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/-/commit/466523ac6fbd1437635f8393fb93c37ff59341b3
--
View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/-/commit/466523ac6fbd1437635f8393fb93c37ff59341b3
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20240229/728020f4/attachment.htm>
More information about the rb-commits
mailing list