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

Docker dont work. #132

Closed
giovannigenna opened this issue May 26, 2024 · 18 comments
Closed

Docker dont work. #132

giovannigenna opened this issue May 26, 2024 · 18 comments

Comments

@giovannigenna
Copy link

Ciao,
Nel docker dopo aver scaricato video e audio da un errore "FileNotFoundError: [Errno 2] No such file or directory:" esattamente nella riga:
File "/app/Src/Lib/Hls/downloader.py", line 454, in clean
os.rename(out_path, self.output_filename)

Sembrerebbe che non trova il file o il path è configurato male. Riesci a darci un occhio ?

Se invece utilizzato senza docker funziona molto bene.

ps: Nel requirements manca "unidecode".

Grazie

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Ciao unidecode dopo lo aggiungo invece per docker ho visto il problema ma non ho tempo per trovare la soluzione dato che cercando sembrebbe un problema interno a docker. Forse però mi sbaglio

@Lovi-0 Lovi-0 changed the title Docker FileNotFoundError: [Errno 2] No such file or directory Docker dont work. May 26, 2024
@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

tqdm/tqdm#771

@giovannigenna
Copy link
Author

Se guardo dentro alla folder di destinazione esiste la cartella temporanea, sembrerebbe qualcosa della funzione clean che non gli piace. Altrimenti non riuscirebbe proprio a scrivere nemmeno il video o l'audio

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Esistono anche i 0.ts per video e audio ?

@giovannigenna
Copy link
Author

sto provando con una serie, nella cartella che crei della puntata ho dentro:
Screenshot 2024-05-26 alle 21 11 50

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Ok perfetto sembra tutto corretto, allora si è un problema nel clean finale.

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Allora in questo caso bisognerebbe fare il print di out_path e verificare che esiste vermante: https://github.com/Ghost6446/StreamingCommunity_api/blob/main/Src%2FLib%2FHls%2Fdownloader.py#L454

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Forse c'è un caso che non ho previsto perché v_v è solo video, v_a è video con audio e v_s può essere sia video e sottotitoli o video con audio e sottotitoli.

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Infatti forse manca il join con i sottotitoli.

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Da questa riga è quelle in po' sotto c'è la decisione dei file da rinominare e sicuramente anche l'errore: https://github.com/Ghost6446/StreamingCommunity_api/blob/main/Src%2FLib%2FHls%2Fdownloader.py#L516

@giovannigenna
Copy link
Author

se però provo ad aprire v_a.mp4 è corrotto, non so se viene fatta qualche operazione finale prima di salvarlo con il nome corretto e spostarlo nella directory della serie

@giovannigenna
Copy link
Author

giovannigenna commented May 26, 2024

l'errore più completo è:
[21:22:15] Find audios => ['ita', 'eng'] downloader.py:172
Find subtitles => ['eng', 'ger', 'gre', 'fre', 'forced-ita', 'ita', 'ukr'] downloader.py:185
Find resolution => [(854, 480), (1280, 720), (1920, 1080)] downloader.py:202
Find codec => ('v': libx264, 'a': aac, 'b': 4500000) downloader.py:223
Video already exists. downloader.py:258
Audio (ita) already exists. downloader.py:304
Subtitle (eng) already exists. downloader.py:354
Conversion => (Audio: True, Subtitle: True) downloader.py:513
ERROR:root:Error: [mov,mp4,m4a,3gp,3g2,mj2 @ 0x563ee6737700] moov atom not found
Video/streamingcommunity/Serie/SERIE_NAME/S1/EPISODIO_NAME/v_a.mp4: Invalid data found when processing input

ERROR:root:Error: Video/streamingcommunity/Serie/SERIE_NAME/S1/EPISODIO_NAME//v_s.mp4: No such file or directory

Traceback (most recent call last):
File "/app/run.py", line 145, in
main()
File "/app/run.py", line 139, in main
run_function(input_to_function[category], CLOSE_CONSOLE)
File "/app/run.py", line 87, in run_function
func()
File "/app/Src/Api/Streamingcommunity/init.py", line 38, in main_film_series
download_series(
File "/app/Src/Api/Streamingcommunity/series.py", line 179, in download_series
donwload_episode(tv_name, list_season_select[0])
File "/app/Src/Api/Streamingcommunity/series.py", line 137, in donwload_episode
donwload_video(tv_name, index_season_selected, list_episode_select[0])
File "/app/Src/Api/Streamingcommunity/series.py", line 99, in donwload_video
).start(SERVER_IP)
^^^^^^^^^^^^^^^^
File "/app/Src/Lib/Hls/downloader.py", line 529, in start
self.clean(converted_out_path)
File "/app/Src/Lib/Hls/downloader.py", line 454, in clean
os.rename(out_path, self.output_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'Video/streamingcommunity/Serie/SERIE_NAME/S1/EPISODIO_NAME/v_s.mp4' -> 'Video/streamingcommunity/Serie/SERIE_NAME/S1/EPISODIO_NAME.mp4'

Andando con il debug il percorso che mi da è questo: "Video/streamingcommunity/Serie/SERIE_NAME/S1/EPISODIO_NAME"

Non vorrei che dentro il container preferisce avere /app/Video/streamingcommunity/Serie/SERIE_NAME/S1/EPISODIO_NAME

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Probabilmente è un errore di ffmpeg che non funziona bene e questo deriva dal fatto che non scaricare bene, prova a vedere se è presente nel docker open ssl, altrimenti bisogna installare pycryptodome

@giovannigenna
Copy link
Author

ora è tardi ;)
domani sera provo a fare un test

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

Aggiungere un ulteriore controllo se ffmpeg funziona alla fine del join o meno però teoricamente è quello.

@Lovi-0
Copy link
Owner

Lovi-0 commented May 26, 2024

ora è tardi ;)
domani sera provo a fare un test

Certamente infatti l'ho sempre rimandato perché serviva molto tempo per trovare il problema.

@Lovi-0
Copy link
Owner

Lovi-0 commented May 27, 2024

Okay allora il problema è che prende sempre come root path: video e non quello passato da docker

@Lovi-0
Copy link
Owner

Lovi-0 commented May 27, 2024

Ora dovrebbe andare

@Lovi-0 Lovi-0 closed this as not planned Won't fix, can't repro, duplicate, stale May 27, 2024
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