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] Model download URL points to wrong location when splitting on Github Actions runner #781

Open
4 tasks done
chuttam opened this issue Aug 25, 2022 · 0 comments · May be fixed by #782
Open
4 tasks done

[Bug] Model download URL points to wrong location when splitting on Github Actions runner #781

chuttam opened this issue Aug 25, 2022 · 0 comments · May be fixed by #782
Labels
bug Something isn't working invalid This doesn't seem right

Comments

@chuttam
Copy link

chuttam commented Aug 25, 2022

  • I didn't find a similar issue already open.
  • I read the documentation (README AND Wiki)
  • I have installed FFMpeg
  • My problem is related to Spleeter only, not a derivative product (such as Webapplication, or GUI provided by others)

Description

Any attempt to run spleeter on a Github Actions runner results in a 404 GET failure at the step for downloading the pre-trained model from spleeter's URL (https://github.com/deezer/spleeter/releases).

Instead, the job attempts to fetch the pretrained model from the current Github repo's URL (https://github.com/my-org/myrepo/releases) , which is non-existent, and returns a 404 Not Found.

404 attempting to download model from local repo instead of from spleeter releases

Root Cause

Spleeter uses the [following environment variables(https://github.com/deezer/spleeter/blob/master/spleeter/model/provider/github.py#L88-L90) for building the fetch URL for its pre-trained, published models:

  • GITHUB_HOST
  • GITHUB_REPOSITORY
  • GITHUB_RELEASE

Unfortunately, GITHUB_REPOSITORY is a reserved environment variable in the context of Github Actions, and gets picked up at runtime, resulting in an incorrect destination model URL.

Solution Options

One alternative is to explicitly set GITHUB_REPOSITORY at the time of invocation of spleeter.

$ GITHUB_REPOSITORY="deezer/spleeter" poetry run python lib/stem_split.py

However, this could introduce undesired side-effects in the Github Action by overriding what should be the original expected value that's set by the environment by default.

A more appropriate solution would be to make the internal usage of spleeter-specific Github environment variables even more distinct, than the current, generic, conflicting names.

Environment

OS Linux
Installation type poetry
RAM available plenty
Hardware spec CPU
@chuttam chuttam added bug Something isn't working invalid This doesn't seem right labels Aug 25, 2022
@chuttam chuttam changed the title [Bug] Model download models points to wrong location when splitting on Github Actions runner [Bug] Model download URL points to wrong location when splitting on Github Actions runner Aug 25, 2022
chuttam added a commit to chuttam/spleeter that referenced this issue Aug 25, 2022
When running in a Github Action runner, `GITHUB_REPOSITORY` is a reserved environment variable that ideally should not be overridden for fear of erratic/unexpected side-effects.

This commit renames the environment variables to be a bit more distinct and related to their purpose within spleeter i.e. for building a model download destination.

Fixes deezer#781
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working invalid This doesn't seem right
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant