py-amqp
py-amqp copied to clipboard
AMQP assumes that field-table is UTF8 encoded
Hello,
we're migrating an old codebase from py2 to py3 and similar to issue #323, we've encountered the same error with field-table. And similar again, the spec doesn't explicitly mention that field-table values should be, or are expected to be UTF8; spec says it's long-uint as well. The same try..except fix works when applied to the loads() method when processing "F" format.
I can make a PR if needed, and I'd be willing to review other places where utf8 decoding is applied. I think that verification of specs in this context might find similar bugs in other places where string encoding/decoding takes place.
i want to review a draft pr first