-
-
Notifications
You must be signed in to change notification settings - Fork 33k
Open
Labels
stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Description
Bug report
Bug description:
This is just a special case of #84561 but it came up in the specific circumstance of XML plists in MOPUp, here: https://github.com/glyph/MOPUp/pull/448/files#r2280646662
I also discovered that it is possible to get the unmodified data, by changing plistlib._PlistParser.handle_data
to look like this:
def handle_data(self, data):
ctx = self.parser.GetInputContext()
if data == '\n' and ctx[0:1] != b'\n':
data = ctx[0:1].decode("utf-8")
self.data.append(data)
so we are not totally bound by the whims of Expat here; these types of bug could be fixed.
CPython versions tested on:
3.12, 3.13, 3.11
Operating systems tested on:
macOS
Metadata
Metadata
Assignees
Labels
stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error