Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blockify crashes during playback of ads with certain characters #95

Closed
retsifp opened this issue Apr 7, 2016 · 5 comments
Closed

Blockify crashes during playback of ads with certain characters #95

retsifp opened this issue Apr 7, 2016 · 5 comments

Comments

@retsifp
Copy link

retsifp commented Apr 7, 2016

In the last days, blockify crashes when a "Ö" is inside the title of the ad (An IKEA ad atm)

File "/usr/local/lib/python2.7/dist-packages/blockify/cli.py", line 252, in update self.found = self.find_ad() File "/usr/local/lib/python2.7/dist-packages/blockify/cli.py", line 272, in find_ad self.ad_found() File "/usr/local/lib/python2.7/dist-packages/blockify/cli.py", line 298, in ad_found self.toggle_mute(1) File "/usr/local/lib/python2.7/dist-packages/blockify/cli.py", line 329, in toggle_mute self.mutemethod(mode) File "/usr/local/lib/python2.7/dist-packages/blockify/cli.py", line 421, in pulsesink_mute log.info("Muting {}.".format(self.current_song)) UnicodeEncodeError: 'ascii' codec can't encode character u'\xd6' in position 8: ordinal not in range(128)

@gmdfalk
Copy link
Owner

gmdfalk commented Apr 7, 2016

Thanks for the report.
That should be an easy fix.

However, can i ask why you are still using Spotify < 1.0.0 (and thus the legacy version of blockify)?

That error would not occur in blockify >= 3.0.0.

@retsifp
Copy link
Author

retsifp commented Apr 7, 2016

Spotify Version is (according to my dpkg) 1:1.0.26.125.g64dc8bc6-15
Blockify Version is 3.4.0

I removed the line mentioned above and a other (similar) one, but the Ad with the "Ö" didn't occur so far 😉
Will report if my "hack" works 😄

@retsifp
Copy link
Author

retsifp commented Apr 8, 2016

I just got the IKEA-Ad again and it's working perfectly now! 😊 👍

@gmdfalk
Copy link
Owner

gmdfalk commented Apr 8, 2016

Great. I'm still a little concerned that you managed to install blockify as a python 2 package but if it works, it works.

@retsifp
Copy link
Author

retsifp commented Apr 8, 2016

Well 😅 I used sudo pip install . for the legacy-version and didn't get the information that I needed to do it with pip3 for the new version 😉

One of your latest commits, however, broke it (muted the music and un-muted the ads 😂) and I needed to do it with pip3 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants