securisec / chepy

Chepy is a python lib/cli equivalent of the awesome CyberChef tool.
GNU General Public License v3.0
934 stars 54 forks source link

remove_whitespace() prints replacement characters #6

Closed geekscrapy closed 4 years ago

geekscrapy commented 4 years ago

Describe the bug When remove_whitespace() is used a list of replacement characters is printed to the terminal:

[' ', '\r', '\n', '\t', '\x0c']

To Reproduce

$ python -V
Python 3.7.5
$ python
Python 3.7.5 (default, Nov  1 2019, 02:16:32)
[Clang 11.0.0 (clang-1100.0.33.8)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from chepy import Chepy
>>> c = (
...     Chepy("lots of white space s")
...     .remove_whitespace()
... )
[' ', '\r', '\n', '\t', '\x0c']
>>> print(c.o)
lotsofwhitespaces