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

[PullRequest] Adding Yandex.Disk download support #6666

Closed
blacky-i opened this issue Jun 28, 2023 · 0 comments · Fixed by #6667
Closed

[PullRequest] Adding Yandex.Disk download support #6666

blacky-i opened this issue Jun 28, 2023 · 0 comments · Fixed by #6667

Comments

@blacky-i
Copy link
Contributor

Added test and yandex.disk url resolution

To download model weights hosted from yandex.disk use following snippet to create final url:

from urllib.parse import urlencode

base_url = 'https://cloud-api.yandex.net/v1/disk/public/resources/download?'
public_key = 'https://disk.yandex.ru/d/pWEKt6D3qi3-aw'  # Public link to url

# Encoding url to create final url
final_url = base_url + urlencode(dict(public_key=public_key))
print(final_rul)
wyli pushed a commit that referenced this issue Jun 28, 2023
Fixes #6666 
/black

### Description
Updated download_url to support internally yandex.disk hosting

### Types of changes
<!--- Put an `x` in all the boxes that apply, and remove the not
applicable items -->
- [x] Non-breaking change (fix or new feature that would not break
existing functionality).
- [ ] Breaking change (fix or new feature that would cause existing
functionality to change).
- [x] New tests added to cover the changes.
- [ ] Integration tests passed locally by running `./runtests.sh -f -u
--net --coverage`.
- [x] Quick tests passed locally by running `./runtests.sh --quick
--unittests --disttests`.
- [x] In-line docstrings updated.
- [ ] Documentation updated, tested `make html` command in the `docs/`
folder.

---------
Signed-off-by: BlackyI <cheivan@mail.ru>
@KumoLiu KumoLiu mentioned this issue Jul 18, 2023
7 tasks
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

Successfully merging a pull request may close this issue.

1 participant