Never see escaped bytes in output.
Project description
It makes Python print the object representation in readable chars instead of the escaped string.
Example
Here we have a Python script, test.py:
# test.py data = ['中文', 'にほんご', u'Λλ'] print 'Before:', data import uniout print 'After :', data
The output of test.py:
Before: ['\xe4\xb8\xad\xe6\x96\x87', '\xe3\x81\xab\xe3\x81\xbb\xe3\x82\x93\xe3\x81\x94', u'\u039b\u03bb'] After : ['中文', 'にほんご', u'Λλ']
Installation
You can install it via PyPI,
sudo pip install uniout
or download it manually.
Change Log
v0.3.2
Show the original string if the escaped string can’t be decoded properly.
Use better way to find string literals.
v0.3.1
Fixed a bug when Uniout works with IPython.
v0.3
Thanks for the pull requests #3 and #4 from @timtan, it now
works well with IPython,
and also supports stderr.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
uniout-0.3.2.tar.gz
(5.3 kB
view details)
File details
Details for the file uniout-0.3.2.tar.gz
.
File metadata
- Download URL: uniout-0.3.2.tar.gz
- Upload date:
- Size: 5.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0fcb7ce752f84bd9f11034097b5ea0588ed4d990d62b717475e350a4b6f387c4 |
|
MD5 | 3ab333be811f3ecc8167239728c3f7af |
|
BLAKE2b-256 | 52ce5abdaafe23f4818afc81cee8243a04964d4e97627e4322e9e924cf7228e7 |