Message341045
Playing around with it a bit more, I ended up changing the interface of the canonicalize() function to return its output as a string by default. It's really nice to be able to say
c14n_xml = canonicalize(plain_xml)
To write to a file, you now do this:
with open("c14n_output.xml", mode='w', encoding='utf-8') as out_file:
canonicalize(xml_data, out=out_file)
and to read from a file:
canonicalize(from_file=fileobj)
I think that nicely handles all use cases. |
|
Date |
User |
Action |
Args |
2019-04-29 06:56:16 | scoder | set | recipients:
+ scoder, loewis, effbot, vstinner, christian.heimes, eli.bendersky, flox, serhiy.storchaka, cbz |
2019-04-29 06:56:16 | scoder | set | messageid: <1556520976.81.0.977045928207.issue13611@roundup.psfhosted.org> |
2019-04-29 06:56:16 | scoder | link | issue13611 messages |
2019-04-29 06:56:16 | scoder | create | |
|