Closed emtee-bc closed 4 years ago
Yes, station icons are implemented and caching should be working.
Have a look at the home directory of the user running YCast. There should be a folder named .ycast
.
The icon cache resides in there.
You may also run YCast with the -d
argument to enable debug logging. Maybe something went wrong creating the cache.
I do have a number of JPEG files for my customised list of stations in stations.yml.
I am starting YCast as a service as it is running on a headless Raspberry Pi 2. I did find the .ycast folder in the root user home folder.
What's not clear from the README is where user supplied JPEG files for the custom stations should be stored and how the file should be named.
From my exploring of your code, it looks like the icon file will be named 'MY_ stationid' without the JPEG extension. It also appears that the maximum size of the JPEG file should be 290 x 290 pixels.
Can you describe:
Thanks in advance. Mark
Icons are only supported for Radiobrowser stations at the moment.
Until we can supply more information besides a name and a url for custom stations, icons (and other tags) are not supported.
From my exploring of your code, it looks like the icon file will be named 'MY_ stationid' without the JPEG extension. It also appears that the maximum size of the JPEG file should be 290 x 290 pixels.
hi @emtee-bc you can easily hack server.py code to have it serve cache icons that you will manually store in .ycast/cache/icons with MY_stationid filename (no extension, 290px max) : simply comment the 3 lines
if not hasattr(station, 'icon') or not station.icon:
logging.warning("No icon information found for station with id '%s'", stationid)
abort(404)
(don't forget to remove pycache)
I have been trying to add station JPEG files to the YCast server and so far nothing appears to work. I am brand new to Flask and while I have some ideas from viewing the YCast code, I don't have direct experience with Flask.
I did insert a
logging.error()
line intostation_icons.py
in theget_icons()
method to display both thecache_path
and thestation_icon_file
, but there is nothing in the log.This is leaving me to believe that icon file functionality has not yet been coded into YCast.
Could you confirm if icon file functionality works, please?