Closed kiike closed 8 years ago
As for the integration issues: i see that there's a call to str.decode() even though it's not needed. I think it's safe to drop it: i get a UTF-8 string on both Python 2.7 and Python 3.5.
These travis errors would make it look like there's an unnecessary .decode()
. Removing it from test_filetype.py
make the tests pass again:
(.pyvenv2) pushbullet.py/ py.test tests/test_filetypes.py
======================================================================================== test session starts =========================================================================================
platform linux2 -- Python 2.7.12, pytest-2.9.2, py-1.4.31, pluggy-0.3.1
rootdir: /mnt/vault/projects/pushbullet.py, inifile:
collected 2 items
tests/test_filetypes.py ..
====================================================================================== 2 passed in 0.10 seconds ======================================================================================
(.pyvenv2) pushbullet.py/ deactivate
pushbullet.py/ source ~/.pyvenv/bin/activate
(.pyvenv) pushbullet.py/ py.test tests/test_filetypes.py
========= test session starts ==========
platform linux -- Python 3.5.2, pytest-2.9.2, py-1.4.31, pluggy-0.3.1
rootdir: /mnt/vault/projects/pushbullet.py, inifile:
plugins: mock-1.1, cov-2.3.0
collected 2 items
tests/test_filetypes.py ..
======= 2 passed in 0.10 seconds =======
This PR adds basic support for handling errors for
websockets-client
listener. Without it no exception was raised on, say, KeyboardInterrupt and I wanted to handle them in order to clean up.