Skip to content

Download files from subfolders doesn't work #739

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

Open
setoff opened this issue Apr 17, 2025 · 6 comments
Open

Download files from subfolders doesn't work #739

setoff opened this issue Apr 17, 2025 · 6 comments

Comments

@setoff
Copy link

setoff commented Apr 17, 2025

Tried the same code:

from kaggle.api.kaggle_api_extended import KaggleApi

api = KaggleApi()
api.authenticate()

api.competition_download_file(
        <competition-name>, 
        'dataset/dataset_files/filename.ext' 
        path='local_path'
    )

Version 1.6.17 downloads file successfully.

Version 1.7.4.2 returns this error:

404 Client Error: Not Found for url: https://www.kaggle.com/api/v1/competitions/data/download/<competion-name>/dataset/dataset_files/filename.ext
@stevemessick stevemessick added the bug Something isn't working label Apr 18, 2025
@stevemessick
Copy link
Contributor

@setoff I'm having trouble reproducing this. Can you give me an example using the command-line tool that works with 1.6.17? Thanks.

Copy link

github-actions bot commented May 4, 2025

Without additional information we're not able to resolve this issue, so it will be closed at this time. You're still free to add more info and respond to any questions above, though. We'll reopen the case if you do. Thanks for your contribution!

@github-actions github-actions bot closed this as completed May 4, 2025
@setoff
Copy link
Author

setoff commented May 5, 2025

Sorry for the late reply.
You may use this one:
kaggle competitions download --file kaggle-environments-0.1.4/kaggle_environments/static/player.html -c connectx

With Kaggle API 1.6.17 downloads file successfully.
With Kaggle API 1.7.4.2:

404 Client Error: Not Found for url: https://www.kaggle.com/api/v1/competitions/data/download/connectx/kaggle-environments-0.1.4/kaggle_environments/static/player.html

@setoff
Copy link
Author

setoff commented May 5, 2025

@stevemessick added CLI to download file from one of the open competitions https://www.kaggle.com/competitions/connectx/overview

You need to join competition first and accept rules before running command I added in message above.

@stevemessick
Copy link
Contributor

@setoff Thanks! I'll look into this.

stevemessick added a commit that referenced this issue May 7, 2025
@stevemessick
Copy link
Contributor

This should be fixed in the latest release, last week.

@stevemessick stevemessick removed the bug Something isn't working label May 12, 2025
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