Repository: openml/openml-python

Issue:
Don't download (large) datasets by default
#### Description
In datasets.get_dataset(data_id) the default is currently to always download the dataset:
https://openml.github.io/openml-python/master/generated/openml.datasets.get_dataset.html#openml.datasets.get_dataset

This is problematic for large datasets - it takes a long time and may cause out-of-memory errors. Sometimes we need to look at the full meta-data (of many datasets) without downloading the data. We can do that now with the option download_data=False, but it feels like this should be the default. Some users may also be unaware of this option or the fact that get_dataset will actually download the data and consume resources.

A simple solution would be to make download_data=False the default.

#### Steps/Code to Reproduce
```python
import openml
openml.datasets.get_dataset(41081)
```

#### Expected Results
The dataset metadata within seconds

#### Actual Results
A long time waiting until the dataset has downloaded and parsed.

#### Versions
macOS-10.16-x86_64-i386-64bit
Python 3.8.5 (default, Sep  4 2020, 02:22:02) 
[Clang 10.0.0 ]
NumPy 1.19.5
SciPy 1.5.2
Scikit-Learn 0.23.2
OpenML 0.11.1dev

Discussion:
codecov-commenter: ## [Codecov](https://app.codecov.io/gh/openml/openml-python/pull/1354?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml) Report
Attention: Patch coverage is `11.11111%` with `8 lines` in your changes missing coverage. Please review.
> Project coverage is 84.26%. Comparing base [(`7764ddb`)](https://app.codecov.io/gh/openml/openml-python/commit/7764ddb38feb14e9c7fe774351524c09f4241356?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml) to head [(`da31a5e`)](https://app.codecov.io/gh/openml/openml-python/commit/da31a5e9f3de834729497ccf6e8d7f4028c3e014?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml).

| [Files with missing lines](https://app.codecov.io/gh/openml/openml-python/pull/1354?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml) | Patch % | Lines |
|---|---|---|
| [openml/tasks/functions.py](https://app.codecov.io/gh/openml/openml-python/pull/1354?src=pr&el=tree&filepath=openml%2Ftasks%2Ffunctions.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml#diff-b3Blbm1sL3Rhc2tzL2Z1bmN0aW9ucy5weQ==) | 11.11% | [8 Missing :warning: ](https://app.codecov.io/gh/openml/openml-python/pull/1354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml) |

<details><summary>Additional details and impacted files</summary>


```diff
@@             Coverage Diff             @@
##           develop    #1354      +/-   ##
===========================================
- Coverage    84.28%   84.26%   -0.03%     
===========================================
  Files           38       38              
  Lines         5288     5287       -1     
===========================================
- Hits          4457     4455       -2     
- Misses         831      832       +1     
```

| [Flag](https://app.codecov.io/gh/openml/openml-python/pull/1354/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml) | Coverage Δ | |
|---|---|---|
| [](https://app.codecov.io/gh/openml/openml-python/pull/1354/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml) | `84.26% <11.11%> (-0.03%)` | :arrow_down: |

Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml#carryforward-flags-in-the-pull-request-comment) to find out more.

</details>

[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/openml/openml-python/pull/1354?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml).   
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openml).


Patch:
diff --git a/openml/tasks/functions.py b/openml/tasks/functions.py
index c763714b..9fd2e4be 100644
--- a/openml/tasks/functions.py
+++ b/openml/tasks/functions.py
@@ -347,8 +347,8 @@ def __list_tasks(  # noqa: PLR0912, C901
 # TODO(eddiebergman): Maybe since this isn't public api, we can make it keyword only?
 def get_tasks(
     task_ids: list[int],
-    download_data: bool = True,  # noqa: FBT001, FBT002
-    download_qualities: bool = True,  # noqa: FBT001, FBT002
+    download_data: bool | None = None,
+    download_qualities: bool | None = None,
 ) -> list[OpenMLTask]:
     """Download tasks.
 
@@ -367,79 +367,65 @@ def get_tasks(
     -------
     list
     """
+    if download_data is None:
+        warnings.warn(
+            "`download_data` will default to False starting in 0.16. "
+            "Please set `download_data` explicitly to suppress this warning.",
+            stacklevel=1,
+        )
+        download_data = True
+
+    if download_qualities is None:
+        warnings.warn(
+            "`download_qualities` will default to False starting in 0.16. "
+            "Please set `download_qualities` explicitly to suppress this warning.",
+            stacklevel=1,
+        )
+        download_qualities = True
+
     tasks = []
     for task_id in task_ids:
-        tasks.append(get_task(task_id, download_data, download_qualities))
+        tasks.append(
+            get_task(task_id, download_data=download_data, download_qualities=download_qualities)
+        )
     return tasks
 
 
 @openml.utils.thread_safe_if_oslo_installed
 def get_task(
     task_id: int,
-    *dataset_args: Any,
-    download_splits: bool | None = None,
+    download_splits: bool = False,  # noqa: FBT001, FBT002
     **get_dataset_kwargs: Any,
 ) -> OpenMLTask:
     """Download OpenML task for a given task ID.
 
-    Downloads the task representation. By default, this will also download the data splits and
-    the dataset. From version 0.15.0 onwards, the splits nor the dataset will not be downloaded by
-    default.
+    Downloads the task representation.
 
     Use the `download_splits` parameter to control whether the splits are downloaded.
     Moreover, you may pass additional parameter (args or kwargs) that are passed to
     :meth:`openml.datasets.get_dataset`.
-    For backwards compatibility, if `download_data` is passed as an additional parameter and
-    `download_splits` is not explicitly set, `download_data` also overrules `download_splits`'s
-    value (deprecated from Version 0.15.0 onwards).
 
     Parameters
     ----------
     task_id : int
         The OpenML task id of the task to download.
-    download_splits: bool (default=True)
-        Whether to download the splits as well. From version 0.15.0 onwards this is independent
-        of download_data and will default to ``False``.
-    dataset_args, get_dataset_kwargs :
+    download_splits: bool (default=False)
+        Whether to download the splits as well.
+    get_dataset_kwargs :
         Args and kwargs can be used pass optional parameters to :meth:`openml.datasets.get_dataset`.
-        This includes `download_data`. If set to True the splits are downloaded as well
-        (deprecated from Version 0.15.0 onwards). The args are only present for backwards
-        compatibility and will be removed from version 0.15.0 onwards.
 
     Returns
     -------
     task: OpenMLTask
     """
-    if download_splits is None:
-        # TODO(0.15): Switch download splits to False by default, adjust typing above, adjust
-        #  documentation above, and remove warning.
-        warnings.warn(
-            "Starting from Version 0.15.0 `download_splits` will default to ``False`` instead "
-            "of ``True`` and be independent from `download_data`. To disable this message until "
-            "version 0.15 explicitly set `download_splits` to a bool.",
-            FutureWarning,
-            stacklevel=3,
-        )
-        download_splits = get_dataset_kwargs.get("download_data", True)
-
     if not isinstance(task_id, int):
-        # TODO(0.15): Remove warning
-        warnings.warn(
-            "Task id must be specified as `int` from 0.14.0 onwards.",
-            FutureWarning,
-            stacklevel=3,
-        )
-
-    try:
-        task_id = int(task_id)
-    except (ValueError, TypeError) as e:
-        raise ValueError("Dataset ID is neither an Integer nor can be cast to an Integer.") from e
+        raise TypeError(f"Task id should be integer, is {type(task_id)}")
 
     tid_cache_dir = openml.utils._create_cache_directory_for_id(TASKS_CACHE_DIR_NAME, task_id)
 
     try:
         task = _get_task_description(task_id)
-        dataset = get_dataset(task.dataset_id, *dataset_args, **get_dataset_kwargs)
+        dataset = get_dataset(task.dataset_id, **get_dataset_kwargs)
         # List of class labels available in dataset description
         # Including class labels as part of task meta data handles
         #   the case where data download was initially disabled
diff --git a/openml/tasks/task.py b/openml/tasks/task.py
index 1e867184..064b834b 100644
--- a/openml/tasks/task.py
+++ b/openml/tasks/task.py
@@ -145,7 +145,7 @@ class OpenMLTask(OpenMLBase):
         ]
         return [(key, fields[key]) for key in order if key in fields]
 
-    def get_dataset(self, **kwargs) -> datasets.OpenMLDataset:
+    def get_dataset(self, **kwargs: Any) -> datasets.OpenMLDataset:
         """Download dataset associated with task.
 
         Accepts the same keyword arguments as the `openml.datasets.get_dataset`.


Test patch:
diff --git a/tests/test_tasks/test_task_functions.py b/tests/test_tasks/test_task_functions.py
index d269fec5..04618479 100644
--- a/tests/test_tasks/test_task_functions.py
+++ b/tests/test_tasks/test_task_functions.py
@@ -154,7 +154,7 @@ class TestTask(TestBase):
         assert os.path.exists(
             os.path.join(self.workdir, "org", "openml", "test", "tasks", "1", "task.xml")
         )
-        assert os.path.exists(
+        assert not os.path.exists(
             os.path.join(self.workdir, "org", "openml", "test", "tasks", "1", "datasplits.arff")
         )
         assert os.path.exists(