scikit-base 1.1.0__tar.gz → 1.2.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {scikit_base-1.1.0/scikit_base.egg-info → scikit_base-1.2.0}/PKG-INFO +6 -5
- {scikit_base-1.1.0 → scikit_base-1.2.0}/README.md +2 -2
- {scikit_base-1.1.0 → scikit_base-1.2.0}/pyproject.toml +6 -9
- {scikit_base-1.1.0 → scikit_base-1.2.0/scikit_base.egg-info}/PKG-INFO +6 -5
- {scikit_base-1.1.0 → scikit_base-1.2.0}/scikit_base.egg-info/SOURCES.txt +2 -1
- {scikit_base-1.1.0 → scikit_base-1.2.0}/scikit_base.egg-info/requires.txt +1 -1
- scikit_base-1.2.0/scikit_base.egg-info/top_level.txt +1 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/__init__.py +1 -1
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/testing/test_all_objects.py +9 -5
- scikit_base-1.2.0/skbase/testing/tests/__init__.py +2 -0
- scikit_base-1.2.0/skbase/testing/tests/test_quicktester.py +47 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/_import.py +0 -1
- scikit_base-1.1.0/docs/source/conf.py +0 -304
- scikit_base-1.1.0/scikit_base.egg-info/top_level.txt +0 -5
- {scikit_base-1.1.0 → scikit_base-1.2.0}/LICENSE +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/scikit_base.egg-info/dependency_links.txt +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/scikit_base.egg-info/zip-safe +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/setup.cfg +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/_exceptions.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/_nopytest_tests.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_base.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_clone_base.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_clone_plugins.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_meta.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/_object_html_repr.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/_pprint.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/tests/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/tests/test_object_html_repr.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/tests/test_pprint.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_tagmanager.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/lookup/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/lookup/_lookup.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/lookup/tests/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/lookup/tests/test_lookup.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/testing/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/testing/utils/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/testing/utils/_conditional_fixtures.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/testing/utils/inspect.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/conftest.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/mock_package/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/mock_package/test_mock_package.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_base.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_baseestimator.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_deep_equals.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_exceptions.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_lookup.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_lookup_metaclasses.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_meta.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/tests/test_tagaliaser.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/_check.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/_iter.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/_nested_iter.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/_utils.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/deep_equals/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/deep_equals/_common.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/deep_equals/_deep_equals.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/_dependencies.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/tests/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/tests/test_check_dependencies.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/tests/test_safe_import.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/doctest_run.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/git_diff.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/random_state.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/stderr_mute.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/stdout_mute.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_check.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_deep_equals.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_iter.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_nested_iter.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_random_state.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_std_mute.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/tests/test_utils.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/_named_objects.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/_type_checks.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/tests/__init__.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/tests/test_iterable_named_objects.py +0 -0
- {scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/tests/test_type_validations.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scikit-base
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.2.0
|
|
4
4
|
Summary: Base classes for sklearn-like parametric objects
|
|
5
5
|
Author-email: sktime developers <sktime.toolbox@gmail.com>
|
|
6
6
|
Maintainer: Franz Király
|
|
@@ -55,7 +55,8 @@ Classifier: Programming Language :: Python :: 3.11
|
|
|
55
55
|
Classifier: Programming Language :: Python :: 3.12
|
|
56
56
|
Classifier: Programming Language :: Python :: 3.13
|
|
57
57
|
Classifier: Programming Language :: Python :: 3.14
|
|
58
|
-
|
|
58
|
+
Classifier: Programming Language :: Python :: 3.15
|
|
59
|
+
Requires-Python: <3.16,>=3.10
|
|
59
60
|
Description-Content-Type: text/markdown
|
|
60
61
|
License-File: LICENSE
|
|
61
62
|
Provides-Extra: all-extras
|
|
@@ -90,7 +91,7 @@ Requires-Dist: nbsphinx>=0.8.6; extra == "docs"
|
|
|
90
91
|
Requires-Dist: numpydoc; extra == "docs"
|
|
91
92
|
Requires-Dist: pydata-sphinx-theme; extra == "docs"
|
|
92
93
|
Requires-Dist: sphinx-issues<7.0.0; extra == "docs"
|
|
93
|
-
Requires-Dist: sphinx-gallery<0.
|
|
94
|
+
Requires-Dist: sphinx-gallery<0.23.0; extra == "docs"
|
|
94
95
|
Requires-Dist: sphinx-panels; extra == "docs"
|
|
95
96
|
Requires-Dist: sphinx-design<0.7.0; extra == "docs"
|
|
96
97
|
Requires-Dist: Sphinx!=7.2.0,<10.0.0; extra == "docs"
|
|
@@ -115,7 +116,7 @@ Dynamic: license-file
|
|
|
115
116
|
`skbase` provides base classes for creating scikit-learn-like parametric objects,
|
|
116
117
|
along with tools to make it easier to build your own packages that follow these design patterns.
|
|
117
118
|
|
|
118
|
-
:rocket: Version 1.
|
|
119
|
+
:rocket: Version 1.2.0 is now available. Check out our
|
|
119
120
|
[release notes](https://skbase.readthedocs.io/en/latest/changelog.html).
|
|
120
121
|
|
|
121
122
|
| Overview | |
|
|
@@ -141,7 +142,7 @@ For trouble shooting or more information, see our
|
|
|
141
142
|
[detailed installation instructions](https://skbase.readthedocs.io/en/latest/user_documentation/installation.html).
|
|
142
143
|
|
|
143
144
|
- **Operating system**: macOS · Linux · Windows 8.1 or higher
|
|
144
|
-
- **Python version**: Python 3.10, 3.11, 3.12, 3.13, and 3.
|
|
145
|
+
- **Python version**: Python 3.10, 3.11, 3.12, 3.13, 3.14, and 3.15
|
|
145
146
|
- **Package managers**: [pip]
|
|
146
147
|
|
|
147
148
|
[pip]: https://pip.pypa.io/en/stable/
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
`skbase` provides base classes for creating scikit-learn-like parametric objects,
|
|
8
8
|
along with tools to make it easier to build your own packages that follow these design patterns.
|
|
9
9
|
|
|
10
|
-
:rocket: Version 1.
|
|
10
|
+
:rocket: Version 1.2.0 is now available. Check out our
|
|
11
11
|
[release notes](https://skbase.readthedocs.io/en/latest/changelog.html).
|
|
12
12
|
|
|
13
13
|
| Overview | |
|
|
@@ -33,7 +33,7 @@ For trouble shooting or more information, see our
|
|
|
33
33
|
[detailed installation instructions](https://skbase.readthedocs.io/en/latest/user_documentation/installation.html).
|
|
34
34
|
|
|
35
35
|
- **Operating system**: macOS · Linux · Windows 8.1 or higher
|
|
36
|
-
- **Python version**: Python 3.10, 3.11, 3.12, 3.13, and 3.
|
|
36
|
+
- **Python version**: Python 3.10, 3.11, 3.12, 3.13, 3.14, and 3.15
|
|
37
37
|
- **Package managers**: [pip]
|
|
38
38
|
|
|
39
39
|
[pip]: https://pip.pypa.io/en/stable/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "scikit-base"
|
|
3
|
-
version = "1.
|
|
3
|
+
version = "1.2.0"
|
|
4
4
|
description = "Base classes for sklearn-like parametric objects"
|
|
5
5
|
authors = [
|
|
6
6
|
{name = "sktime developers", email = "sktime.toolbox@gmail.com"},
|
|
@@ -31,8 +31,9 @@ classifiers = [
|
|
|
31
31
|
"Programming Language :: Python :: 3.12",
|
|
32
32
|
"Programming Language :: Python :: 3.13",
|
|
33
33
|
"Programming Language :: Python :: 3.14",
|
|
34
|
+
"Programming Language :: Python :: 3.15",
|
|
34
35
|
]
|
|
35
|
-
requires-python = ">=3.10,<3.
|
|
36
|
+
requires-python = ">=3.10,<3.16"
|
|
36
37
|
dependencies = []
|
|
37
38
|
|
|
38
39
|
[project.optional-dependencies]
|
|
@@ -71,7 +72,7 @@ docs = [
|
|
|
71
72
|
"numpydoc",
|
|
72
73
|
"pydata-sphinx-theme",
|
|
73
74
|
"sphinx-issues<7.0.0",
|
|
74
|
-
"sphinx-gallery<0.
|
|
75
|
+
"sphinx-gallery<0.23.0",
|
|
75
76
|
"sphinx-panels",
|
|
76
77
|
"sphinx-design<0.7.0",
|
|
77
78
|
"Sphinx!=7.2.0,<10.0.0",
|
|
@@ -144,15 +145,11 @@ exclude_dirs = ["*/tests/*", "*/testing/*"]
|
|
|
144
145
|
zip-safe = true
|
|
145
146
|
|
|
146
147
|
[tool.setuptools.package-data]
|
|
147
|
-
|
|
148
|
+
skbase = [
|
|
148
149
|
"*.csv",
|
|
149
150
|
"*.csv.gz",
|
|
150
|
-
"*.arff",
|
|
151
|
-
"*.arff.gz",
|
|
152
151
|
"*.txt",
|
|
153
|
-
"*.ts",
|
|
154
|
-
"*.tsv",
|
|
155
152
|
]
|
|
156
153
|
|
|
157
154
|
[tool.setuptools.packages.find]
|
|
158
|
-
|
|
155
|
+
include = ["skbase", "skbase.*"]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scikit-base
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.2.0
|
|
4
4
|
Summary: Base classes for sklearn-like parametric objects
|
|
5
5
|
Author-email: sktime developers <sktime.toolbox@gmail.com>
|
|
6
6
|
Maintainer: Franz Király
|
|
@@ -55,7 +55,8 @@ Classifier: Programming Language :: Python :: 3.11
|
|
|
55
55
|
Classifier: Programming Language :: Python :: 3.12
|
|
56
56
|
Classifier: Programming Language :: Python :: 3.13
|
|
57
57
|
Classifier: Programming Language :: Python :: 3.14
|
|
58
|
-
|
|
58
|
+
Classifier: Programming Language :: Python :: 3.15
|
|
59
|
+
Requires-Python: <3.16,>=3.10
|
|
59
60
|
Description-Content-Type: text/markdown
|
|
60
61
|
License-File: LICENSE
|
|
61
62
|
Provides-Extra: all-extras
|
|
@@ -90,7 +91,7 @@ Requires-Dist: nbsphinx>=0.8.6; extra == "docs"
|
|
|
90
91
|
Requires-Dist: numpydoc; extra == "docs"
|
|
91
92
|
Requires-Dist: pydata-sphinx-theme; extra == "docs"
|
|
92
93
|
Requires-Dist: sphinx-issues<7.0.0; extra == "docs"
|
|
93
|
-
Requires-Dist: sphinx-gallery<0.
|
|
94
|
+
Requires-Dist: sphinx-gallery<0.23.0; extra == "docs"
|
|
94
95
|
Requires-Dist: sphinx-panels; extra == "docs"
|
|
95
96
|
Requires-Dist: sphinx-design<0.7.0; extra == "docs"
|
|
96
97
|
Requires-Dist: Sphinx!=7.2.0,<10.0.0; extra == "docs"
|
|
@@ -115,7 +116,7 @@ Dynamic: license-file
|
|
|
115
116
|
`skbase` provides base classes for creating scikit-learn-like parametric objects,
|
|
116
117
|
along with tools to make it easier to build your own packages that follow these design patterns.
|
|
117
118
|
|
|
118
|
-
:rocket: Version 1.
|
|
119
|
+
:rocket: Version 1.2.0 is now available. Check out our
|
|
119
120
|
[release notes](https://skbase.readthedocs.io/en/latest/changelog.html).
|
|
120
121
|
|
|
121
122
|
| Overview | |
|
|
@@ -141,7 +142,7 @@ For trouble shooting or more information, see our
|
|
|
141
142
|
[detailed installation instructions](https://skbase.readthedocs.io/en/latest/user_documentation/installation.html).
|
|
142
143
|
|
|
143
144
|
- **Operating system**: macOS · Linux · Windows 8.1 or higher
|
|
144
|
-
- **Python version**: Python 3.10, 3.11, 3.12, 3.13, and 3.
|
|
145
|
+
- **Python version**: Python 3.10, 3.11, 3.12, 3.13, 3.14, and 3.15
|
|
145
146
|
- **Package managers**: [pip]
|
|
146
147
|
|
|
147
148
|
[pip]: https://pip.pypa.io/en/stable/
|
|
@@ -2,7 +2,6 @@ LICENSE
|
|
|
2
2
|
README.md
|
|
3
3
|
pyproject.toml
|
|
4
4
|
setup.cfg
|
|
5
|
-
docs/source/conf.py
|
|
6
5
|
scikit_base.egg-info/PKG-INFO
|
|
7
6
|
scikit_base.egg-info/SOURCES.txt
|
|
8
7
|
scikit_base.egg-info/dependency_links.txt
|
|
@@ -30,6 +29,8 @@ skbase/lookup/tests/__init__.py
|
|
|
30
29
|
skbase/lookup/tests/test_lookup.py
|
|
31
30
|
skbase/testing/__init__.py
|
|
32
31
|
skbase/testing/test_all_objects.py
|
|
32
|
+
skbase/testing/tests/__init__.py
|
|
33
|
+
skbase/testing/tests/test_quicktester.py
|
|
33
34
|
skbase/testing/utils/__init__.py
|
|
34
35
|
skbase/testing/utils/_conditional_fixtures.py
|
|
35
36
|
skbase/testing/utils/inspect.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
skbase
|
|
@@ -342,6 +342,7 @@ class QuickTester:
|
|
|
342
342
|
"""
|
|
343
343
|
from _pytest.outcomes import Skipped
|
|
344
344
|
|
|
345
|
+
from skbase.utils.stderr_mute import StderrMute
|
|
345
346
|
from skbase.utils.stdout_mute import StdoutMute
|
|
346
347
|
|
|
347
348
|
tests_to_run = self._check_none_str_or_list_of_str(
|
|
@@ -464,7 +465,10 @@ class QuickTester:
|
|
|
464
465
|
print_if_verbose(f"{key}")
|
|
465
466
|
|
|
466
467
|
try:
|
|
467
|
-
with
|
|
468
|
+
with (
|
|
469
|
+
StdoutMute(active=verbose < 2),
|
|
470
|
+
StderrMute(active=verbose < 2),
|
|
471
|
+
):
|
|
468
472
|
test_fun(**deepcopy(args))
|
|
469
473
|
results[key] = "PASSED"
|
|
470
474
|
print_if_verbose("PASSED")
|
|
@@ -541,7 +545,7 @@ class QuickTester:
|
|
|
541
545
|
obj = [obj]
|
|
542
546
|
if not isinstance(obj, list):
|
|
543
547
|
raise ValueError(msg)
|
|
544
|
-
if not np.all(isinstance(x, str) for x in obj):
|
|
548
|
+
if not np.all([isinstance(x, str) for x in obj]):
|
|
545
549
|
raise ValueError(msg)
|
|
546
550
|
return obj
|
|
547
551
|
|
|
@@ -715,12 +719,12 @@ class TestAllObjects(BaseFixtureGenerator, QuickTester):
|
|
|
715
719
|
f"found {type(names)}"
|
|
716
720
|
)
|
|
717
721
|
|
|
718
|
-
assert np.all(isinstance(est, object_class) for est in objects), (
|
|
722
|
+
assert np.all([isinstance(est, object_class) for est in objects]), (
|
|
719
723
|
"list elements of first return returned by create_test_instances_and_names "
|
|
720
724
|
"all must be an instance of the class"
|
|
721
725
|
)
|
|
722
726
|
|
|
723
|
-
assert np.all(isinstance(name,
|
|
727
|
+
assert np.all([isinstance(name, str) for name in names]), (
|
|
724
728
|
"list elements of second return returned by create_test_instances_and_names"
|
|
725
729
|
" all must be strings"
|
|
726
730
|
)
|
|
@@ -909,7 +913,7 @@ class TestAllObjects(BaseFixtureGenerator, QuickTester):
|
|
|
909
913
|
|
|
910
914
|
def test_repr(self, object_instance):
|
|
911
915
|
"""Check that __repr__ call to instance does not raise exceptions."""
|
|
912
|
-
repr(object_instance)
|
|
916
|
+
_ = repr(object_instance)
|
|
913
917
|
|
|
914
918
|
def test_repr_html(self, object_instance):
|
|
915
919
|
"""Check that _repr_html_ call to instance does not raise exceptions."""
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
"""Regression tests for QuickTester input checks and output muting."""
|
|
3
|
+
|
|
4
|
+
import sys
|
|
5
|
+
from typing import List
|
|
6
|
+
|
|
7
|
+
import pytest
|
|
8
|
+
|
|
9
|
+
from skbase.testing import BaseFixtureGenerator, QuickTester
|
|
10
|
+
from skbase.tests.conftest import Parent
|
|
11
|
+
|
|
12
|
+
__author__: List[str] = ["yash-sangwan"]
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class _NoisyTester(BaseFixtureGenerator, QuickTester):
|
|
16
|
+
"""Minimal test class that writes to both output streams."""
|
|
17
|
+
|
|
18
|
+
def test_writes_to_streams(self, object_class):
|
|
19
|
+
"""Write a marker to stdout and to stderr."""
|
|
20
|
+
sys.stdout.write("stdout-marker")
|
|
21
|
+
sys.stderr.write("stderr-marker")
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
@pytest.mark.parametrize("bad", [42, ["a", 5], {"a": 1}])
|
|
25
|
+
def test_check_none_str_or_list_of_str_rejects_invalid(bad):
|
|
26
|
+
"""Invalid input raises; a generator passed to np.all would never raise."""
|
|
27
|
+
with pytest.raises(ValueError, match="must be None, str, or list of str"):
|
|
28
|
+
QuickTester._check_none_str_or_list_of_str(bad, var_name="x")
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
@pytest.mark.parametrize(
|
|
32
|
+
"good, expected", [(None, None), ("a", ["a"]), (["a", "b"], ["a", "b"])]
|
|
33
|
+
)
|
|
34
|
+
def test_check_none_str_or_list_of_str_accepts_valid(good, expected):
|
|
35
|
+
"""Valid input is returned, coerced to list of str."""
|
|
36
|
+
assert QuickTester._check_none_str_or_list_of_str(good, var_name="x") == expected
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
@pytest.mark.parametrize("verbose, muted", [(0, True), (2, False)])
|
|
40
|
+
def test_run_tests_mutes_stdout_and_stderr(capsys, verbose, muted):
|
|
41
|
+
"""Both streams are muted below verbose=2, and both are shown at verbose=2."""
|
|
42
|
+
_NoisyTester().run_tests(
|
|
43
|
+
Parent, tests_to_run="test_writes_to_streams", verbose=verbose
|
|
44
|
+
)
|
|
45
|
+
captured = capsys.readouterr()
|
|
46
|
+
assert ("stdout-marker" not in captured.out) is muted
|
|
47
|
+
assert ("stderr-marker" not in captured.err) is muted
|
|
@@ -1,304 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env python3
|
|
2
|
-
# -*- coding: utf-8 -*-
|
|
3
|
-
# copyright: skbase developers, BSD-3-Clause License (see LICENSE file)
|
|
4
|
-
"""Configure skbase Sphinx documentation."""
|
|
5
|
-
|
|
6
|
-
# -- Path setup --------------------------------------------------------------
|
|
7
|
-
|
|
8
|
-
# If extensions (or modules to document with autodoc) are in another directory,
|
|
9
|
-
# add these directories to sys.path here. If the directory is relative to the
|
|
10
|
-
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
|
11
|
-
|
|
12
|
-
import datetime
|
|
13
|
-
import inspect
|
|
14
|
-
import os
|
|
15
|
-
import sys
|
|
16
|
-
|
|
17
|
-
import skbase
|
|
18
|
-
|
|
19
|
-
# -- Path setup --------------------------------------------------------------
|
|
20
|
-
|
|
21
|
-
# When we build the docs on readthedocs, we build the package and want to
|
|
22
|
-
# use the built files in order for sphinx to be able to properly read the
|
|
23
|
-
# Cython files. Hence, we do not add the source code path to the system path.
|
|
24
|
-
env_rtd = os.environ.get("READTHEDOCS")
|
|
25
|
-
# Check if on Read the docs
|
|
26
|
-
if not env_rtd == "True":
|
|
27
|
-
print("Not on ReadTheDocs")
|
|
28
|
-
sys.path.insert(0, os.path.abspath("../.."))
|
|
29
|
-
|
|
30
|
-
# -- Project information -----------------------------------------------------
|
|
31
|
-
|
|
32
|
-
current_year = datetime.datetime.now().year
|
|
33
|
-
project = "skbase"
|
|
34
|
-
copyright = f"{current_year} (BSD-3-Clause License)"
|
|
35
|
-
author = "skbase Developers"
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
# The full version, including alpha/beta/rc tags
|
|
39
|
-
release = skbase.__version__
|
|
40
|
-
|
|
41
|
-
# -- General configuration ---------------------------------------------------
|
|
42
|
-
|
|
43
|
-
# Add any Sphinx extension module names here, as strings. They can be
|
|
44
|
-
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
|
45
|
-
# ones.
|
|
46
|
-
extensions = [
|
|
47
|
-
"sphinx.ext.autodoc",
|
|
48
|
-
"sphinx.ext.autosummary",
|
|
49
|
-
"numpydoc",
|
|
50
|
-
"sphinx.ext.intersphinx",
|
|
51
|
-
"sphinx.ext.linkcode", # link to GitHub source code via linkcode_resolve()
|
|
52
|
-
"nbsphinx", # integrates example notebooks
|
|
53
|
-
"sphinx_gallery.load_style",
|
|
54
|
-
"myst_parser",
|
|
55
|
-
"sphinx_panels",
|
|
56
|
-
"sphinx_issues",
|
|
57
|
-
"sphinx_design",
|
|
58
|
-
]
|
|
59
|
-
|
|
60
|
-
myst_enable_extensions = ["colon_fence"]
|
|
61
|
-
|
|
62
|
-
# -- Internationalization ------------------------------------------------
|
|
63
|
-
# specifying the natural language populates some key tags
|
|
64
|
-
language = "en"
|
|
65
|
-
|
|
66
|
-
# Use bootstrap CSS from theme.
|
|
67
|
-
panels_add_bootstrap_css = False
|
|
68
|
-
|
|
69
|
-
# Add any paths that contain templates here, relative to this directory.
|
|
70
|
-
templates_path = ["_templates"]
|
|
71
|
-
|
|
72
|
-
# The suffix(es) of source filenames.
|
|
73
|
-
# You can specify multiple suffix as a list of string:
|
|
74
|
-
source_suffix = {
|
|
75
|
-
".rst": "restructuredtext",
|
|
76
|
-
".md": "markdown",
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
# The main toctree document.
|
|
80
|
-
master_doc = "index"
|
|
81
|
-
|
|
82
|
-
# List of patterns, relative to source directory, that match files and
|
|
83
|
-
# directories to ignore when looking for source files.
|
|
84
|
-
# This pattern also affects html_static_path and html_extra_path.
|
|
85
|
-
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "**.ipynb_checkpoints"]
|
|
86
|
-
|
|
87
|
-
# add_module_names = False
|
|
88
|
-
|
|
89
|
-
# The name of the Pygments (syntax highlighting) style to use.
|
|
90
|
-
pygments_style = "sphinx"
|
|
91
|
-
|
|
92
|
-
# Members and inherited-members default to showing methods and attributes from
|
|
93
|
-
# a class or those inherited.
|
|
94
|
-
# Member-order orders the documentation in the order of how the members are
|
|
95
|
-
# defined in the source code.
|
|
96
|
-
autodoc_default_options = {
|
|
97
|
-
"members": True,
|
|
98
|
-
"inherited-members": True,
|
|
99
|
-
"member-order": "bysource",
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
# If true, '()' will be appended to :func: etc. cross-reference text.
|
|
103
|
-
add_function_parentheses = False
|
|
104
|
-
|
|
105
|
-
# Link to GitHub repo for github_issues extension
|
|
106
|
-
issues_github_path = "sktime/skbase"
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
def linkcode_resolve(domain, info):
|
|
110
|
-
"""Return URL to source code corresponding.
|
|
111
|
-
|
|
112
|
-
Parameters
|
|
113
|
-
----------
|
|
114
|
-
domain : str
|
|
115
|
-
info : dict
|
|
116
|
-
|
|
117
|
-
Returns
|
|
118
|
-
-------
|
|
119
|
-
url : str
|
|
120
|
-
"""
|
|
121
|
-
|
|
122
|
-
def find_source():
|
|
123
|
-
# try to find the file and line number, based on code from numpy:
|
|
124
|
-
# https://github.com/numpy/numpy/blob/main/doc/source/conf.py#L286
|
|
125
|
-
obj = sys.modules[info["module"]]
|
|
126
|
-
for part in info["fullname"].split("."):
|
|
127
|
-
obj = getattr(obj, part)
|
|
128
|
-
|
|
129
|
-
fn = inspect.getsourcefile(obj)
|
|
130
|
-
fn = os.path.relpath(fn, start=os.path.dirname(skbase.__file__))
|
|
131
|
-
source, lineno = inspect.getsourcelines(obj)
|
|
132
|
-
return fn, lineno, lineno + len(source) - 1
|
|
133
|
-
|
|
134
|
-
if domain != "py" or not info["module"]:
|
|
135
|
-
return None
|
|
136
|
-
try:
|
|
137
|
-
filename = "skbase/%s#L%d-L%d" % find_source()
|
|
138
|
-
except Exception:
|
|
139
|
-
filename = info["module"].replace(".", "/") + ".py"
|
|
140
|
-
return f"https://github.com/sktime/skbase/blob/{version_match}/{filename}"
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
# -- Options for HTML output -------------------------------------------------
|
|
144
|
-
|
|
145
|
-
# The theme to use for HTML and HTML Help pages. See the documentation for
|
|
146
|
-
# a list of builtin themes.
|
|
147
|
-
|
|
148
|
-
html_theme = "pydata_sphinx_theme"
|
|
149
|
-
|
|
150
|
-
# Define the json_url for our version switcher.
|
|
151
|
-
json_url = "https://skbase.readthedocs.io/en/latest/_static/switcher.json"
|
|
152
|
-
|
|
153
|
-
# This uses code from the py-data-sphinx theme's own conf.py
|
|
154
|
-
# Define the version we use for matching in the version switcher.
|
|
155
|
-
version_match = os.environ.get("READTHEDOCS_VERSION")
|
|
156
|
-
|
|
157
|
-
# If READTHEDOCS_VERSION doesn't exist, we're not on RTD
|
|
158
|
-
# If it is an integer, we're in a PR build and the version isn't correct.
|
|
159
|
-
if not version_match or version_match.isdigit():
|
|
160
|
-
# For local development, infer the version to match from the package.
|
|
161
|
-
if "dev" in release or "rc" in release:
|
|
162
|
-
version_match = "latest"
|
|
163
|
-
# We want to keep the relative reference if we are in dev mode
|
|
164
|
-
# but we want the whole url if we are effectively in a released version
|
|
165
|
-
json_url = "_static/switcher.json"
|
|
166
|
-
else:
|
|
167
|
-
version_match = "v" + release
|
|
168
|
-
|
|
169
|
-
html_theme_options = {
|
|
170
|
-
"logo": {
|
|
171
|
-
"text": "skbase",
|
|
172
|
-
"alt_text": "skbase",
|
|
173
|
-
},
|
|
174
|
-
"icon_links": [
|
|
175
|
-
{
|
|
176
|
-
"name": "GitHub",
|
|
177
|
-
"url": "https://github.com/sktime/skbase",
|
|
178
|
-
"icon": "fab fa-github",
|
|
179
|
-
},
|
|
180
|
-
{
|
|
181
|
-
"name": "Discord",
|
|
182
|
-
"url": "https://discord.com/invite/54ACzaFsn7",
|
|
183
|
-
"icon": "fab fa-discord",
|
|
184
|
-
},
|
|
185
|
-
{
|
|
186
|
-
"name": "LinkedIn",
|
|
187
|
-
"url": "https://www.linkedin.com/company/scikit-time/",
|
|
188
|
-
"icon": "fab fa-linkedin",
|
|
189
|
-
},
|
|
190
|
-
{
|
|
191
|
-
"name": "PyPI",
|
|
192
|
-
"url": "https://pypi.org/project/skbase",
|
|
193
|
-
"icon": "fa-solid fa-box",
|
|
194
|
-
},
|
|
195
|
-
],
|
|
196
|
-
"icon_links_label": "Quick Links",
|
|
197
|
-
"show_nav_level": 1,
|
|
198
|
-
"show_prev_next": False,
|
|
199
|
-
"use_edit_page_button": False,
|
|
200
|
-
"navbar_start": ["navbar-logo", "version-switcher"],
|
|
201
|
-
"navbar_center": ["navbar-nav"],
|
|
202
|
-
"switcher": {
|
|
203
|
-
"json_url": json_url,
|
|
204
|
-
"version_match": version_match,
|
|
205
|
-
},
|
|
206
|
-
"header_links_before_dropdown": 6,
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
html_context = {
|
|
210
|
-
"github_user": "sktime",
|
|
211
|
-
"github_repo": "skbase",
|
|
212
|
-
"github_version": "main",
|
|
213
|
-
"doc_path": "docs/source/",
|
|
214
|
-
"default_mode": "light",
|
|
215
|
-
}
|
|
216
|
-
html_sidebars = {"**": ["sidebar-nav-bs.html", "sidebar-ethical-ads.html"]}
|
|
217
|
-
|
|
218
|
-
# Add any paths that contain custom static files (such as style sheets) here,
|
|
219
|
-
# relative to this directory. They are copied after the builtin static files,
|
|
220
|
-
# so a file named "default.css" will overwrite the builtin "default.css".
|
|
221
|
-
html_static_path = ["_static"]
|
|
222
|
-
|
|
223
|
-
# -- Options for HTMLHelp output ---------------------------------------------
|
|
224
|
-
# Output file base name for HTML help builder.
|
|
225
|
-
htmlhelp_basename = "skbasedoc"
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
# -- Options for LaTeX output ------------------------------------------------
|
|
229
|
-
# latex_elements = {
|
|
230
|
-
# The paper size ('letterpaper' or 'a4paper').
|
|
231
|
-
# 'papersize': 'letterpaper',
|
|
232
|
-
# The font size ('10pt', '11pt' or '12pt').
|
|
233
|
-
# 'pointsize': '10pt',
|
|
234
|
-
# Additional stuff for the LaTeX preamble.
|
|
235
|
-
# 'preamble': '',
|
|
236
|
-
# Latex figure (float) alignment
|
|
237
|
-
# 'figure_align': 'htbp',
|
|
238
|
-
# }
|
|
239
|
-
|
|
240
|
-
# Grouping the document tree into LaTeX files. List of tuples
|
|
241
|
-
# (source start file, target name, title,
|
|
242
|
-
# author, documentclass [howto, manual, or own class]).
|
|
243
|
-
latex_documents = [
|
|
244
|
-
(
|
|
245
|
-
master_doc,
|
|
246
|
-
"skbase.tex",
|
|
247
|
-
"skbase Documentation",
|
|
248
|
-
"skbase developers",
|
|
249
|
-
"manual",
|
|
250
|
-
),
|
|
251
|
-
]
|
|
252
|
-
|
|
253
|
-
# -- Extension configuration -------------------------------------------------
|
|
254
|
-
|
|
255
|
-
# -- Options for numpydoc extension ------------------------------------------
|
|
256
|
-
# see http://stackoverflow.com/q/12206334/562769
|
|
257
|
-
numpydoc_show_class_members = True
|
|
258
|
-
# this is needed for some reason...
|
|
259
|
-
# see https://github.com/numpy/numpydoc/issues/69
|
|
260
|
-
numpydoc_class_members_toctree = False
|
|
261
|
-
|
|
262
|
-
numpydoc_validation_checks = {"all", "GL01", "SA01", "EX01"}
|
|
263
|
-
|
|
264
|
-
# -- Options for sphinx-copybutton extension----------------------------------
|
|
265
|
-
copybutton_prompt_text = r">>> |\.\.\. |\$ |In \[\d*\]: | {2,5}\.\.\.: | {5,8}: "
|
|
266
|
-
copybutton_prompt_is_regexp = True
|
|
267
|
-
|
|
268
|
-
# -- Options for nbsphinx extension ------------------------------------------
|
|
269
|
-
nbsphinx_execute = "never" # always # whether to run notebooks
|
|
270
|
-
nbsphinx_allow_errors = False # False
|
|
271
|
-
nbsphinx_timeout = 600 # seconds, set to -1 to disable timeout
|
|
272
|
-
|
|
273
|
-
# add Binder launch button at the top
|
|
274
|
-
current_file = "{{ env.doc2path( env.docname, base=None) }}"
|
|
275
|
-
|
|
276
|
-
# make sure Binder points to latest stable release, not main
|
|
277
|
-
binder_base = "https://mybinder.org/v2/gh//skbase/"
|
|
278
|
-
binder_url = binder_base + f"{version_match}?filepath={current_file}"
|
|
279
|
-
nbsphinx_prolog = f"""
|
|
280
|
-
.. |binder| image:: https://mybinder.org/badge_logo.svg
|
|
281
|
-
.. _Binder: {binder_url}
|
|
282
|
-
|
|
283
|
-
|Binder|_
|
|
284
|
-
"""
|
|
285
|
-
|
|
286
|
-
# add link to original notebook at the bottom
|
|
287
|
-
notebook_url = f"https://github.com/sktime/skbase/tree/{version_match}/{current_file}"
|
|
288
|
-
nbsphinx_epilog = f"""
|
|
289
|
-
----
|
|
290
|
-
|
|
291
|
-
Generated using nbsphinx_. The Jupyter notebook can be found here_.
|
|
292
|
-
|
|
293
|
-
.. _here: {notebook_url}
|
|
294
|
-
.. _nbsphinx: https://nbsphinx.readthedocs.io/
|
|
295
|
-
"""
|
|
296
|
-
|
|
297
|
-
# -- Options for intersphinx extension ---------------------------------------
|
|
298
|
-
|
|
299
|
-
# Example configuration for intersphinx: refer to the Python standard library.
|
|
300
|
-
intersphinx_mapping = {
|
|
301
|
-
"python": ("https://docs.python.org/{.major}".format(sys.version_info), None),
|
|
302
|
-
"scikit-learn": ("https://scikit-learn.org/stable/", None),
|
|
303
|
-
"sktime": ("https://www.sktime.net/en/stable/", None),
|
|
304
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/base/_pretty_printing/tests/test_object_html_repr.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/utils/dependencies/tests/test_check_dependencies.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scikit_base-1.1.0 → scikit_base-1.2.0}/skbase/validate/tests/test_iterable_named_objects.py
RENAMED
|
File without changes
|
|
File without changes
|