Issue: Outdated Link for mkqa Dataset
State: closed
Author: liaeh

## Describe the bug
The URL used to download the mkqa dataset is outdated. It seems the URL to download the dataset is currently https://github.com/apple/ml-mkqa/blob/main/dataset/mkqa.jsonl.gz instead of https://github.com/apple/ml-mkqa/raw/master/dataset/mkqa.jsonl.gz (master branch has been renamed to main).

## Steps to reproduce the bug
```python
from datasets import load_dataset

dataset = load_dataset("mkqa")
```

## Expected results
downloads the dataset

## Actual results
```python
Downloading builder script:
4.79k/? [00:00<00:00, 201kB/s]
Downloading metadata:
13.2k/? [00:00<00:00, 504kB/s]

Downloading and preparing dataset mkqa/mkqa (download: 11.35 MiB, generated: 34.29 MiB, post-processed: Unknown size, total: 45.65 MiB) to /home/lhr/.cache/huggingface/datasets/mkqa/mkqa/1.0.0/5401489c674c81257cf563417aaaa5de2c7e26a1090ce9b10eb0404f10003d4d...

Downloading data files: 0%
0/1 [00:00<?, ?it/s]

---------------------------------------------------------------------------
FileNotFoundError                         Traceback (most recent call last)
Input In [3], in <cell line: 3>()
      1 from datasets import load_dataset
----> 3 dataset = load_dataset("mkqa")

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/load.py:1746, in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs)
   1743 try_from_hf_gcs = path not in _PACKAGED_DATASETS_MODULES
   1745 # Download and prepare data
-> 1746 builder_instance.download_and_prepare(
   1747     download_config=download_config,
   1748     download_mode=download_mode,
   1749     ignore_verifications=ignore_verifications,
   1750     try_from_hf_gcs=try_from_hf_gcs,
   1751     use_auth_token=use_auth_token,
   1752 )
   1754 # Build dataset for splits
   1755 keep_in_memory = (
   1756     keep_in_memory if keep_in_memory is not None else is_small_dataset(builder_instance.info.dataset_size)
   1757 )

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/builder.py:704, in DatasetBuilder.download_and_prepare(self, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, **download_and_prepare_kwargs)
    702         logger.warning("HF google storage unreachable. Downloading and preparing it from source")
    703 if not downloaded_from_gcs:
--> 704     self._download_and_prepare(
    705         dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
    706     )
    707 # Sync info
    708 self.info.dataset_size = sum(split.num_bytes for split in self.info.splits.values())

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/builder.py:1227, in GeneratorBasedBuilder._download_and_prepare(self, dl_manager, verify_infos)
   1226 def _download_and_prepare(self, dl_manager, verify_infos):
-> 1227     super()._download_and_prepare(dl_manager, verify_infos, check_duplicate_keys=verify_infos)

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/builder.py:771, in DatasetBuilder._download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs)
    769 split_dict = SplitDict(dataset_name=self.name)
    770 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs)
--> 771 split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
    773 # Checksums verification
    774 if verify_infos and dl_manager.record_checksums:

File ~/.cache/huggingface/modules/datasets_modules/datasets/mkqa/5401489c674c81257cf563417aaaa5de2c7e26a1090ce9b10eb0404f10003d4d/mkqa.py:130, in Mkqa._split_generators(self, dl_manager)
    128 # download and extract URLs
    129 urls_to_download = _URLS
--> 130 downloaded_files = dl_manager.download_and_extract(urls_to_download)
    132 return [datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"filepath": downloaded_files["train"]})]

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/download/download_manager.py:431, in DownloadManager.download_and_extract(self, url_or_urls)
    415 def download_and_extract(self, url_or_urls):
    416     """Download and extract given url_or_urls.
    417 
    418     Is roughly equivalent to:
   (...)
    429         extracted_path(s): `str`, extracted paths of given URL(s).
    430     """
--> 431     return self.extract(self.download(url_or_urls))

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/download/download_manager.py:309, in DownloadManager.download(self, url_or_urls)
    306 download_func = partial(self._download, download_config=download_config)
    308 start_time = datetime.now()
--> 309 downloaded_path_or_paths = map_nested(
    310     download_func,
    311     url_or_urls,
    312     map_tuple=True,
    313     num_proc=download_config.num_proc,
    314     disable_tqdm=not is_progress_bar_enabled(),
    315     desc="Downloading data files",
    316 )
    317 duration = datetime.now() - start_time
    318 logger.info(f"Downloading took {duration.total_seconds() // 60} min")

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/utils/py_utils.py:393, in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, types, disable_tqdm, desc)
    391     num_proc = 1
    392 if num_proc <= 1 or len(iterable) <= num_proc:
--> 393     mapped = [
    394         _single_map_nested((function, obj, types, None, True, None))
    395         for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc)
    396     ]
    397 else:
    398     split_kwds = []  # We organize the splits ourselve (contiguous splits)

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/utils/py_utils.py:394, in <listcomp>(.0)
    391     num_proc = 1
    392 if num_proc <= 1 or len(iterable) <= num_proc:
    393     mapped = [
--> 394         _single_map_nested((function, obj, types, None, True, None))
    395         for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc)
    396     ]
    397 else:
    398     split_kwds = []  # We organize the splits ourselve (contiguous splits)

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/utils/py_utils.py:330, in _single_map_nested(args)
    328 # Singleton first to spare some computation
    329 if not isinstance(data_struct, dict) and not isinstance(data_struct, types):
--> 330     return function(data_struct)
    332 # Reduce logging to keep things readable in multiprocessing with tqdm
    333 if rank is not None and logging.get_verbosity() < logging.WARNING:

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/download/download_manager.py:335, in DownloadManager._download(self, url_or_filename, download_config)
    332 if is_relative_path(url_or_filename):
    333     # append the relative path to the base_path
    334     url_or_filename = url_or_path_join(self._base_path, url_or_filename)
--> 335 return cached_path(url_or_filename, download_config=download_config)

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/utils/file_utils.py:185, in cached_path(url_or_filename, download_config, **download_kwargs)
    181     url_or_filename = str(url_or_filename)
    183 if is_remote_url(url_or_filename):
    184     # URL, so get it from the cache (downloading if necessary)
--> 185     output_path = get_from_cache(
    186         url_or_filename,
    187         cache_dir=cache_dir,
    188         force_download=download_config.force_download,
    189         proxies=download_config.proxies,
    190         resume_download=download_config.resume_download,
    191         user_agent=download_config.user_agent,
    192         local_files_only=download_config.local_files_only,
    193         use_etag=download_config.use_etag,
    194         max_retries=download_config.max_retries,
    195         use_auth_token=download_config.use_auth_token,
    196         ignore_url_params=download_config.ignore_url_params,
    197         download_desc=download_config.download_desc,
    198     )
    199 elif os.path.exists(url_or_filename):
    200     # File, and it exists.
    201     output_path = url_or_filename

File ~/repos/punc-cap/venv/lib/python3.9/site-packages/datasets/utils/file_utils.py:530, in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc)
    525     raise FileNotFoundError(
    526         f"Cannot find the requested files in the cached path at {cache_path} and outgoing traffic has been"
    527         " disabled. To enable file online look-ups, set 'local_files_only' to False."
    528     )
    529 elif response is not None and response.status_code == 404:
--> 530     raise FileNotFoundError(f"Couldn't find file at {url}")
    531 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}")
    532 if head_error is not None:

FileNotFoundError: Couldn't find file at https://github.com/apple/ml-mkqa/raw/master/dataset/mkqa.jsonl.gz


```

## Environment info
- `datasets` version: 2.4.0
- Platform: Linux-5.13.0-40-generic-x86_64-with-glibc2.31
- Python version: 3.9.7
- PyArrow version: 9.0.0
- Pandas version: 1.4.2


Comments:
Thanks for reporting @liaeh, we are investigating this.