Skip to content

Commit 156b15a

Browse files
authored
Merge pull request #208 from scipy/release_2.0
Release 2.0
2 parents 2a4eba9 + cd2475f commit 156b15a

File tree

2 files changed

+24
-1
lines changed

2 files changed

+24
-1
lines changed

docs/changelog.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,28 @@
11
# Changelog
22

3+
## 2.0 (2025-08-05)
4+
5+
- The default for the CLI option `--doctest-only-doctests` is changed to `False`.
6+
**This is a breaking change.** From now on, the default behavior of
7+
`$ pytest --doctest-modules` is to collect both doctests and unit tests, which aligns
8+
with the rest of the ecosystem. To retain the previous behavior of only collecting
9+
doctests, use `$ pytest --doctest-modules --doctest-only-doctests=true` explicitly.
10+
See [gh-198](https://github.com/scipy/scipy_doctest/issues/198) for details.
11+
12+
- A new `pytest_extra_requires` key was added to `DTConfig`. This allows to express
13+
dependencies of individual functions or modules, and only collect doctests if
14+
the specified requirements are met. As a made-up example,
15+
16+
```
17+
config = DTConfig()
18+
config.pytest_extra_requires ={"full.func.name" : ["cupy", "numpy>2"]}
19+
```
20+
21+
will only collect doctests from the docstring of `full.func.name` if `cupy` is available,
22+
and if `numpy` is at version `2.0` or above.
23+
Parsing requirements relies on the [`packaging` module from PyPA](https://github.com/pypa/packaging).
24+
25+
326
## 1.8 (2025-05-29)
427

528
- Add a CLI option, `--doctest-only-doctests={true,false}` to control whether to only

scipy_doctest/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"""
44

55

6-
__version__ = "1.9.0.dev0"
6+
__version__ = "2.0.0"
77

88
try:
99
# register internal modules with pytest; obscure errors galore otherwise

0 commit comments

Comments
 (0)