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

[BUG]: Crash at the end of download on containered version #680

Open
abaurens opened this issue May 2, 2024 · 2 comments
Open

[BUG]: Crash at the end of download on containered version #680

abaurens opened this issue May 2, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@abaurens
Copy link

abaurens commented May 2, 2024

Program version

master (2488edc0243d8bef88db805aca0997bd23a4f41)

Operating System

Linux

Type

GUI

Service

Crunchyroll

Command used

aniDL

Show ID

G60914JM6

Episode

1

Console Output

2024-05-02 05:19:22 Resuming download from part 251...
2024-05-02 05:19:22 50 of 358 parts downloaded [14%] (3s | 6.5Mb/s)
2024-05-02 05:19:22 100 of 358 parts downloaded [28%] (3s | 6.6Mb/s)
2024-05-02 05:19:22 150 of 358 parts downloaded [42%] (2s | 5.9Mb/s)
2024-05-02 05:19:22 node:fs:1398
2024-05-02 05:19:22   handleErrorFromBinding(ctx);
2024-05-02 05:19:22   ^
2024-05-02 05:19:22 
2024-05-02 05:19:22 Error: EACCES: permission denied, mkdir 'app'
2024-05-02 05:19:22     at Object.mkdirSync (node:fs:1398:3)
2024-05-02 05:19:22     at Object.mkdirSync (pkg/prelude/bootstrap.js:1639:33)
2024-05-02 05:19:22     at /snapshot/lib/crunchy.js
2024-05-02 05:19:22     at Array.forEach (<anonymous>)
2024-05-02 05:19:22     at Crunchy.<anonymous> (/snapshot/lib/crunchy.js)
2024-05-02 05:19:22     at Generator.next (<anonymous>)
2024-05-02 05:19:22     at fulfilled (/snapshot/lib/crunchy.js)
2024-05-02 05:19:22     at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
2024-05-02 05:19:22   errno: -13,
2024-05-02 05:19:22   syscall: 'mkdir',
2024-05-02 05:19:22   code: 'EACCES',
2024-05-02 05:19:22   path: 'app'
2024-05-02 05:19:22 }
2024-05-02 05:19:22 
2024-05-02 05:19:22 Node.js v18.18.2

Additional Information

I am using the docker image that I compiled myself from the master branch.

The error most likely comes from the fact that I changed the user who is runing the the app within the container. However, it somehow manages to download all the parts and to create the directory structure for it.
The error only appears at the end, when it tries to mux the files together.

I already tried and succeded to fix this by letting the container run as root. But this is not a acceptable solution for me as it runs on my self hosted server and is available from the internet.

@abaurens abaurens added the bug Something isn't working label May 2, 2024
@Jaynator495
Copy link

You need to change the permission/ownership of the output folder to your user, otherwise, it will fail as you have seen.

@abaurens
Copy link
Author

abaurens commented May 2, 2024

Yes, that's what I did as a workaround.
However, since the app manages to download the parts, and to generate the subdirectories,
it means it should already be able to work in that directory without me having to modify the docker image.

The /app directory doesn't have write rights and ther's basically no reason for which the app would have exec an mkdir command on that path in the first place since it always exist..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants