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

Icon feature not working in 1.1.0 ? #76

Closed
tomtastic opened this issue Nov 29, 2020 · 1 comment · Fixed by #77
Closed

Icon feature not working in 1.1.0 ? #76

tomtastic opened this issue Nov 29, 2020 · 1 comment · Fixed by #77

Comments

@tomtastic
Copy link
Contributor

I dont see icons for any stations, for example this station from radio-browsers popular list :

{'changeuuid': 'a2bd6961-077e-11e8-ae97-52543be04c81', 'stationuuid': '962cc6df-0601-11e8-ae97-52543be04c81', 'name': 'Dance Wave!', 'url': 'http://dancewave.online/dance.mp3.pls', 'url_resolved': 'http://stream.dancewave.online:8080/dance.mp3', 'homepage': 'http://dancewave.online/', 'favicon': 'http://dancewave.online/dw-logo_s.png', 'tags': 'house,trance,dance', 'country': 'Hungary', 'countrycode': 'HU', 'state': '', 'language': 'english', 'votes': 109068, 'lastchangetime': '2020-01-19 13:17:11', 'codec': 'MP3', 'bitrate': 128, 'hls': 0, 'lastcheckok': 1, 'lastchecktime': '2020-11-28 21:58:10', 'lastcheckoktime': '2020-11-28 21:58:10', 'lastlocalchecktime': '2020-11-28 15:11:13', 'clicktimestamp': '2020-11-29 10:23:23', 'clickcount': 3599, 'clicktrend': -16}

I dont see the ~/.ycast/cache path being mkdir'd, or any related error, so it seem the following codepath isn't being hit yet?

./ycast/station_icons.py:15:def get_icon(station):
./ycast/station_icons.py-16-    cache_path = generic.get_cache_path(CACHE_NAME)
./ycast/station_icons.py-17-    if not cache_path:
./ycast/station_icons.py-18-        return None

The Radio-browser API request seems to hit a 404 also ...

2020-11-29 10:55:19 INFO: YCast (1.1.0) server starting
2020-11-29 10:55:19 DEBUG: Debug logging enabled
 * Serving Flask app "ycast.server" (lazy loading)
 * Environment: production
   WARNING: This is a development server. Do not use it in a production deployment.
   Use a production WSGI server instead.
 * Debug mode: off
2020-11-29 10:55:19 INFO:  * Running on http://0.0.0.0:80/ (Press CTRL+C to quit)

2020-11-29 10:55:49 DEBUG: Radiobrowser API request: stations/byid/962cc6df-0601-11e8-ae97-52543be04c81
2020-11-29 10:55:49 DEBUG: Starting new HTTP connection (1): all.api.radio-browser.info:80
2020-11-29 10:55:49 DEBUG: Radiobrowser API request: stations/byid/962cc6df-0601-11e8-ae97-52543be04c81
2020-11-29 10:55:49 DEBUG: Starting new HTTP connection (1): all.api.radio-browser.info:80
2020-11-29 10:55:49 DEBUG: http://all.api.radio-browser.info:80 "GET /json/stations/byid/962cc6df-0601-11e8-ae97-52543be04c81 HTTP/1.1" 404 0
2020-11-29 10:55:49 DEBUG: http://all.api.radio-browser.info:80 "GET /json/stations/byid/962cc6df-0601-11e8-ae97-52543be04c81 HTTP/1.1" 404 0
2020-11-29 10:55:49 ERROR: Could not fetch data from Radiobrowser API (HTML status 404)
2020-11-29 10:55:49 ERROR: Could not get station with id 'RB_962cc6df-0601-11e8-ae97-52543be04c81'
2020-11-29 10:55:49 ERROR: Could not fetch data from Radiobrowser API (HTML status 404)
2020-11-29 10:55:49 INFO: 172.27.0.12 - - [29/Nov/2020 10:55:49] "GET /ycast/icon?id=RB_962cc6df-0601-11e8-ae97-52543be04c81 HTTP/1.1" 404 -
2020-11-29 10:55:49 ERROR: Could not get station with id 'RB_962cc6df-0601-11e8-ae97-52543be04c81'
2020-11-29 10:55:49 INFO: 172.27.0.12 - - [29/Nov/2020 10:55:49] "GET /ycast/icon?id=RB_962cc6df-0601-11e8-ae97-52543be04c81 HTTP/1.1" 404 -
2020-11-29 10:55:49 DEBUG: Radiobrowser API request: stations/byid/962cc6df-0601-11e8-ae97-52543be04c81
2020-11-29 10:55:49 DEBUG: Starting new HTTP connection (1): all.api.radio-browser.info:80
2020-11-29 10:55:49 DEBUG: http://all.api.radio-browser.info:80 "GET /json/stations/byid/962cc6df-0601-11e8-ae97-52543be04c81 HTTP/1.1" 404 0
2020-11-29 10:55:49 ERROR: Could not fetch data from Radiobrowser API (HTML status 404)
2020-11-29 10:55:49 ERROR: Could not get station with id 'RB_962cc6df-0601-11e8-ae97-52543be04c81'
2020-11-29 10:55:49 INFO: 172.27.0.12 - - [29/Nov/2020 10:55:49] "GET /ycast/icon?id=RB_962cc6df-0601-11e8-ae97-52543be04c81 HTTP/1.1" 404 -```
@tomtastic
Copy link
Contributor Author

This appears to be because the GET to http://all.api.radio-browser.info:80 is wrong.

GET /json/stations/byid/962cc6df-0601-11e8-ae97-52543be04c81

Should be :

GET /json/stations/byuuid/962cc6df-0601-11e8-ae97-52543be04c81

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

Successfully merging a pull request may close this issue.

1 participant