Unable to download bluebook-for-bulldozers with Kaggle API

I am trying to download the bluebook-for-bulldozers dataset using kaggle API, but I get the “403 - Forbidden” error,

I did this –

(1) Logged into to my kaggle profile
(2) “Edit Profile” in the right hand top corner
(3) “Create New API token”
(4) Download token in ~/Downloads

(5)
(pytorch-gpu) onkar@Curiosity:~/mnt/kaggle/bluebook-for-bulldozers/data$ cp ~/Downloads/kaggle.json ~/.kaggle/kaggle.json
(pytorch-gpu) onkar@Curiosity:~/mnt/kaggle/bluebook-for-bulldozers/data$ chmod 600 /home/onkar/.kaggle/kaggle.json
(pytorch-gpu) onkar@Curiosity:~/mnt/kaggle/bluebook-for-bulldozers/data$ kaggle competitions download -c bluebook-for-bulldozers -w -q
403 - Forbidden
onkar@Curiosity:~/mnt/kaggle/bluebook-for-bulldozers/data$ kaggle competitions download -c bluebook-for-bulldozers -w -q
403 - Forbidden

This is a local/Home system.

Any clues ?

Sorry, my mistake, to download datasets, competition rules have to be accepted. If you have created a new account, there is a phone verification and after that you can accept the competition rule and get started with using the Kaggle API to download the datasets.

Posting the answer in hope that this helps others as well.

1 Like

Well I can manually download the data from kaggle, but the api download does not work.

2 Likes

Yes the api download command is not working.

so did the following: -

  • downloaded the data using
    ! kaggle competitions download -c bluebook-for-bulldozers
  • create the directory using
    if not path.exists(): path.mkdir()
  • moved the zip file downloaded to that created directory.
  • then extract files using
    file_extract(path/'bluebook-for-bulldozers.zip')

you are good to go :om:

1 Like

I have also same issue from couple of days any suggestion for this so please reply. Thanks in advance.

Can you please provide a screenshot of this part of the your notebook?

It looks like Kaggle changed the location of the accept rules, it is now appears like a popup for with the accept competition rules button

I’m having a bit of trouble with the kaggle API download. I can still get the data by manually downloading it, but the API isn’t working

I’m also struggling to download the data, either via API or directly from the Kaggle site. It tells me to accept the rules, but I’m unable to do that. There’s a grayed out button saying “Late Submission” on the page, and I can’t press that. Other competitions that are over, the “Late Submission” button is black and it can be pressed. But not for the bluebook-for-bulldozers competition…

Probably issue with Kaggle, but wanted to post it here, too.

I solved the problem,
you can not accept the rules directly, here is the trick

  1. activate the account and phone number
  2. go to the data > click on one of the tables like train.csv
  3. one pop up comes up and then accept and join the competition