[issue17868] pprint long non-printable bytes as hexdump

anatoly techtonik report at bugs.python.org
Tue Apr 30 10:51:11 CEST 2013


anatoly techtonik added the comment:

Some issues:

1. the hex converting logic doesn't belong to base64 module - there is no chance a person without StackOverflow access can find it
2. i'd put issue17862 first as a dependency for this one, because proposed itertools.chunks() can be further optimized (chunking endless sequences with constant memory overhead, pypy specific speedups, etc)

I like that this is not over-engineered. In my hexdump module I got too involved with problems of parsing/producing full dumps in a way compatible with Python 2/3. So I have to postpone my own user story until finally I run out of time.

Probably hexdump.dump() returning string will make it a useful API for the primary user story.
hexdump.dumpgen() as a line generator with 16 hexadecimal bytes delimited by space should cover all other use cases.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue17868>
_______________________________________


More information about the Python-bugs-list mailing list