Closed janaxhell closed 2 months ago
Maybe again the permission error you had once before? Rename the older /spotify folder to /spotisub if you still have it If not, you have to re-init the container with the init script
Also can you share your new compose file?
Ahh, yes, I didn't dochmod 777 -R
on /cache, it starts with no error now.
Anyway when I tried to git clone spotisub and launched the script, this was the answer:
root@openmediavault:~/spotisub# ./first_run.sh
Traceback (most recent call last):
File "init.py", line 2, in <module>
import spotipy
ImportError: No module named spotipy
My compose:
services:
navidrome:
container_name: navidrome
image: deluan/navidrome:latest
user: 998:100
networks:
- omv1
ports:
- "4533:4533"
environment:
ND_SCANSCHEDULE: 5 6 * * 0
ND_LOGLEVEL: info
ND_SESSIONTIMEOUT: 72h
ND_BASEURL: "/music"
ND_PLAYLISTSPATH: "lidarr/playlists"
# ND_IMAGECACHESIZE: "100MB"
ND_SPOTIFY_ID: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ND_SPOTIFY_SECRET: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ND_LASTFM_ENABLED: true
ND_LASTFM_APIKEY: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ND_LASTFM_SECRET: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ND_SUBSONICARTISTPARTICIPATIONS: true
ND_LISTENBRAINZ_BASEURL: http://192.168.1.94:42010/apis/listenbrainz/1/
ND_UIWELCOMEMESSAGE: Be water my friend
ND_ENABLEREPLAYGAIN: true
ND_ENABLESHARING: true
ND_ENABLESTARRATING: true
ND_IGNOREDARTICLES: "The El La Los Las Le Les Os As O A Il Lo La Gli"
ND_ENABLEFAVOURITES: true
ND_ENABLEEXTERNALSERVICES: true
ND_ENABLECOVERANIMATION: true
ND_COVERARTPRIORITY: embedded, folder.*, cover.*, front.*
ND_JUKEBOX_ENABLED: true
volumes:
- "/srv/dev-disk-by-uuid-5b67514d-485e-4306-873e-b1cbb54ccf99/Config/Navidrome:/data"
- "/srv/dev-disk-by-uuid-BAF04088F0404D37/data/media/unmapped:/music/unmapped"
- "/srv/dev-disk-by-uuid-BAF04088F0404D37/data/media/music:/music/lidarr"
restart: unless-stopped
spotisub:
container_name: spotisub
environment:
- PUID=998
- PGID=100
- TZ=Europe/Rome
- SPOTIPY_CLIENT_ID=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- SPOTIPY_CLIENT_SECRET=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- SPOTIPY_REDIRECT_URI=http://127.0.0.1:18080/
# - LIDARR_ENABLED=1
# - LIDARR_IP=192.168.1.94
# - LIDARR_PORT=8686
# - LIDARR_TOKEN=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- SUBSONIC_API_BASE_URL=/music
- SUBSONIC_API_HOST=http://192.168.1.94
- SUBSONIC_API_PORT=4533
- SUBSONIC_API_USER=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- SUBSONIC_API_PASS=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- ITEMS_PER_PLAYLIST=100
- NUM_USER_PLAYLISTS=5
- ARTIST_GEN_SCHED=2
- RECCOMEND_GEN_SCHED=8
- PLAYLIST_GEN_SCHED=6
- SAVED_GEN_SCHED=24
- PLAYLIST_PREFIX="Z "
- SCHEDULER_ENABLED=1
- SPOTDL_ENABLED=0
- SPOTDL_OUT_FORMAT="/music/222subtify/{album-artist}/{album-artist} - ({year}) - {album}/{track-number} - {title}.{output-ext}"
- EXCLUDED_WORDS=acoustic,instrumental,demo,remix,live
- LOG_LEVEL=20
image: "blastbeng/spotisub:latest"
user: 998:100
restart: always
volumes:
- "/srv/dev-disk-by-uuid-5b67514d-485e-4306-873e-b1cbb54ccf99/Config/spotisub/cache:/home/user/spotisub/cache"
ports:
- 50811:50811
networks:
- omv1
networks:
omv1:
external: true
Ahh, yes, I didn't do
chmod 777 -R
on /cache, it starts with no error now. Anyway when I tried to git clone spotisub and launched the script, this was the answer:root@openmediavault:~/spotisub# ./first_run.sh Traceback (most recent call last): File "init.py", line 2, in <module> import spotipy ImportError: No module named spotipy
My compose:
services: navidrome: container_name: navidrome image: deluan/navidrome:latest user: 998:100 networks: - omv1 ports: - "4533:4533" environment: ND_SCANSCHEDULE: 5 6 * * 0 ND_LOGLEVEL: info ND_SESSIONTIMEOUT: 72h ND_BASEURL: "/music" ND_PLAYLISTSPATH: "lidarr/playlists" # ND_IMAGECACHESIZE: "100MB" ND_SPOTIFY_ID: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX ND_SPOTIFY_SECRET: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX ND_LASTFM_ENABLED: true ND_LASTFM_APIKEY: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX ND_LASTFM_SECRET: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX ND_SUBSONICARTISTPARTICIPATIONS: true ND_LISTENBRAINZ_BASEURL: http://192.168.1.94:42010/apis/listenbrainz/1/ ND_UIWELCOMEMESSAGE: Be water my friend ND_ENABLEREPLAYGAIN: true ND_ENABLESHARING: true ND_ENABLESTARRATING: true ND_IGNOREDARTICLES: "The El La Los Las Le Les Os As O A Il Lo La Gli" ND_ENABLEFAVOURITES: true ND_ENABLEEXTERNALSERVICES: true ND_ENABLECOVERANIMATION: true ND_COVERARTPRIORITY: embedded, folder.*, cover.*, front.* ND_JUKEBOX_ENABLED: true volumes: - "/srv/dev-disk-by-uuid-5b67514d-485e-4306-873e-b1cbb54ccf99/Config/Navidrome:/data" - "/srv/dev-disk-by-uuid-BAF04088F0404D37/data/media/unmapped:/music/unmapped" - "/srv/dev-disk-by-uuid-BAF04088F0404D37/data/media/music:/music/lidarr" restart: unless-stopped spotisub: container_name: spotisub environment: - PUID=998 - PGID=100 - TZ=Europe/Rome - SPOTIPY_CLIENT_ID=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX - SPOTIPY_CLIENT_SECRET=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX - SPOTIPY_REDIRECT_URI=http://127.0.0.1:18080/ # - LIDARR_ENABLED=1 # - LIDARR_IP=192.168.1.94 # - LIDARR_PORT=8686 # - LIDARR_TOKEN=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX - SUBSONIC_API_BASE_URL=/music - SUBSONIC_API_HOST=http://192.168.1.94 - SUBSONIC_API_PORT=4533 - SUBSONIC_API_USER=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX - SUBSONIC_API_PASS=XXXXXXXXXXXXXXXXXXXXXXXXXXXXX - ITEMS_PER_PLAYLIST=100 - NUM_USER_PLAYLISTS=5 - ARTIST_GEN_SCHED=2 - RECCOMEND_GEN_SCHED=8 - PLAYLIST_GEN_SCHED=6 - SAVED_GEN_SCHED=24 - PLAYLIST_PREFIX="Z " - SCHEDULER_ENABLED=1 - SPOTDL_ENABLED=0 - SPOTDL_OUT_FORMAT="/music/222subtify/{album-artist}/{album-artist} - ({year}) - {album}/{track-number} - {title}.{output-ext}" - EXCLUDED_WORDS=acoustic,instrumental,demo,remix,live - LOG_LEVEL=20 image: "blastbeng/spotisub:latest" user: 998:100 restart: always volumes: - "/srv/dev-disk-by-uuid-5b67514d-485e-4306-873e-b1cbb54ccf99/Config/spotisub/cache:/home/user/spotisub/cache" ports: - 50811:50811 networks: - omv1 networks: omv1: external: true
Before launching the first run script you need to enter the container
docker exec -it spotisub bash
You are executing the script outside the container
Anyways, there's no need to clone the repo
I'm a bit confused because during one of the previous issues you told me to simply run ./first_run.sh with no docker exec, which I did from the git cloned repo and it worked IIRC.. But maybe this was when you were still creating the docker version.
I'm a bit confused because during one of the previous issues you told me to simply run ./first_run.sh with no docker exec, which I did from the git cloned repo and it worked IIRC.. But maybe this was when you were still creating the docker version.
That was because there was a bug in the docker container, which got resolved in a previous release, now the correct way of executing it is inside the docker container
EDIT: it works outside the docker container, but you have to install python requirements before.
After a couple of hours starting with no error, I checked it again and it was repeating the same errors above and had produced no playlist meanwhile. So I tried the script. but it doesn't work
root@openmediavault:~/spotisub# docker exec -it spotisub bash
I have no name!@2f01963a0326:~/spotisub$ ./first_run.sh
Traceback (most recent call last):
File "/home/user/spotisub/init.py", line 3, in <module>
import constants
ModuleNotFoundError: No module named 'constants'
After a couple of hours starting with no error, I checked it again and it was repeating the same errors above and had produced no playlist meanwhile. So I tried the script. but it doesn't work
root@openmediavault:~/spotisub# docker exec -it spotisub bash I have no name!@2f01963a0326:~/spotisub$ ./first_run.sh Traceback (most recent call last): File "/home/user/spotisub/init.py", line 3, in <module> import constants ModuleNotFoundError: No module named 'constants'
probably because of this on the init.py its being compared to the constants pypi module instead of importing the constants from the spotisub directory, https://github.com/blastbeng/spotisub/blob/f5346431a21a023d6091d74039a642fa67fea58f/init.py#L3
It should be
from spotisub.constants import constants
that allows to run the ./first_run.sh
I rebuild the image changing that part of the init.py
and first_run.sh
executes without problem.
After a couple of hours starting with no error, I checked it again and it was repeating the same errors above and had produced no playlist meanwhile. So I tried the script. but it doesn't work
root@openmediavault:~/spotisub# docker exec -it spotisub bash I have no name!@2f01963a0326:~/spotisub$ ./first_run.sh Traceback (most recent call last): File "/home/user/spotisub/init.py", line 3, in <module> import constants ModuleNotFoundError: No module named 'constants'
probably because of this on the init.py its being compared to the constants pypi module instead of importing the constants from the spotisub directory,
https://github.com/blastbeng/spotisub/blob/f5346431a21a023d6091d74039a642fa67fea58f/init.py#L3
It should be
from spotisub.constants import constants
that allows to run the
./first_run.sh
I rebuild the image changing that part of the
init.py
andfirst_run.sh
executes without problem.
It has been moved, sorry about that, gonna fix in v 0.2.1
After a couple of hours starting with no error, I checked it again and it was repeating the same errors above and had produced no playlist meanwhile. So I tried the script. but it doesn't work
root@openmediavault:~/spotisub# docker exec -it spotisub bash I have no name!@2f01963a0326:~/spotisub$ ./first_run.sh Traceback (most recent call last): File "/home/user/spotisub/init.py", line 3, in <module> import constants ModuleNotFoundError: No module named 'constants'
probably because of this on the init.py its being compared to the constants pypi module instead of importing the constants from the spotisub directory,
https://github.com/blastbeng/spotisub/blob/f5346431a21a023d6091d74039a642fa67fea58f/init.py#L3
It should be
from spotisub.constants import constants
that allows to run the
./first_run.sh
I rebuild the image changing that part of the
init.py
andfirst_run.sh
executes without problem.
This is solved now in Release 0.2.1
https://github.com/blastbeng/spotisub/releases/tag/v0.2.1
Can you confirm that? Thanks
I have been able to deploy 0.2.1 and paste the URL generated by the script, now I have to wait some time to see if it triggers Navidrome with new playlists.
EDIT What I see here after half an hour is this:
2024-09-18 09:10:26 INFO Scheduler started
███████╗██████╗ ██████╗ ████████╗██╗███████╗██╗ ██╗██████╗
██╔════╝██╔══██╗██╔═══██╗╚══██╔══╝██║██╔════╝██║ ██║██╔══██╗
███████╗██████╔╝██║ ██║ ██║ ██║███████╗██║ ██║██████╔╝
╚════██║██╔═══╝ ██║ ██║ ██║ ██║╚════██║██║ ██║██╔══██╗
███████║██║ ╚██████╔╝ ██║ ██║███████║╚██████╔╝██████╔╝
╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝ ╚═════╝ ╚═════╝
v0.2.1
WSGI app 0 (mountpoint='') ready in 2 seconds on interpreter 0x55aec30fed50 pid: 7 (default app)
2024-09-18 09:15:04 INFO [2024-Sep-18 09:15] 192.168.1.21 GET http /generate/artist_reccomendations/? 404 NOT FOUND
[pid: 7|app: 0|req: 1/1] 192.168.1.21 () {40 vars in 3321 bytes} [Wed Sep 18 09:15:04 2024] GET /generate/artist_reccomendations/ => generated 207 bytes in 1 msecs (HTTP/1.1 404) 2 headers in 87 bytes (1 switches on core 0)
2024-09-18 09:15:05 INFO [2024-Sep-18 09:15] 192.168.1.21 GET http /favicon.ico? 404 NOT FOUND
[pid: 7|app: 0|req: 2/2] 192.168.1.21 () {38 vars in 3216 bytes} [Wed Sep 18 09:15:05 2024] GET /favicon.ico => generated 207 bytes in 0 msecs (HTTP/1.1 404) 2 headers in 87 bytes (1 switches on core 0)
2024-09-18 09:15:07 INFO [2024-Sep-18 09:15] 192.168.1.21 GET http /generate/artist_reccomendations/? 404 NOT FOUND
[pid: 7|app: 0|req: 3/3] 192.168.1.21 () {42 vars in 3352 bytes} [Wed Sep 18 09:15:07 2024] GET /generate/artist_reccomendations/ => generated 207 bytes in 0 msecs (HTTP/1.1 404) 2 headers in 87 bytes (1 switches on core 0)
EDIT2 It works, a couple of new playlists appeared in Navidrome.
I have been able to deploy 0.2.1 and paste the URL generated by the script, now I have to wait some time to see if it triggers Navidrome with new playlists.
EDIT What I see here after half an hour is this:
2024-09-18 09:10:26 INFO Scheduler started ███████╗██████╗ ██████╗ ████████╗██╗███████╗██╗ ██╗██████╗ ██╔════╝██╔══██╗██╔═══██╗╚══██╔══╝██║██╔════╝██║ ██║██╔══██╗ ███████╗██████╔╝██║ ██║ ██║ ██║███████╗██║ ██║██████╔╝ ╚════██║██╔═══╝ ██║ ██║ ██║ ██║╚════██║██║ ██║██╔══██╗ ███████║██║ ╚██████╔╝ ██║ ██║███████║╚██████╔╝██████╔╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝ ╚═════╝ ╚═════╝ v0.2.1 WSGI app 0 (mountpoint='') ready in 2 seconds on interpreter 0x55aec30fed50 pid: 7 (default app) 2024-09-18 09:15:04 INFO [2024-Sep-18 09:15] 192.168.1.21 GET http /generate/artist_reccomendations/? 404 NOT FOUND [pid: 7|app: 0|req: 1/1] 192.168.1.21 () {40 vars in 3321 bytes} [Wed Sep 18 09:15:04 2024] GET /generate/artist_reccomendations/ => generated 207 bytes in 1 msecs (HTTP/1.1 404) 2 headers in 87 bytes (1 switches on core 0) 2024-09-18 09:15:05 INFO [2024-Sep-18 09:15] 192.168.1.21 GET http /favicon.ico? 404 NOT FOUND [pid: 7|app: 0|req: 2/2] 192.168.1.21 () {38 vars in 3216 bytes} [Wed Sep 18 09:15:05 2024] GET /favicon.ico => generated 207 bytes in 0 msecs (HTTP/1.1 404) 2 headers in 87 bytes (1 switches on core 0) 2024-09-18 09:15:07 INFO [2024-Sep-18 09:15] 192.168.1.21 GET http /generate/artist_reccomendations/? 404 NOT FOUND [pid: 7|app: 0|req: 3/3] 192.168.1.21 () {42 vars in 3352 bytes} [Wed Sep 18 09:15:07 2024] GET /generate/artist_reccomendations/ => generated 207 bytes in 0 msecs (HTTP/1.1 404) 2 headers in 87 bytes (1 switches on core 0)
EDIT2 It works, a couple of new playlists appeared in Navidrome.
The endpoint has been modified, it is not "/generate/artist_reccomendations/" but "/generate/artist_recommendations/"
I've just noticed that after replacing all the subtify entries in my compose with spotisub (only the subtify words, no other change), this happens when the container starts:
/spotisub folder contains a /cache folder, but it's empty.