Skip to content

Commit 54abdeb

Browse files
committed
fix(type): remove ClassVar from Directive.option_spec override
ty flags option_spec: ClassVar as an invalid class-variable override of Directive.option_spec which is an instance variable in docutils.
1 parent 272ba6f commit 54abdeb

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

docs/tox_conf.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
from sphinx.util.logging import getLogger
1111

1212
if TYPE_CHECKING:
13+
from collections.abc import Callable
14+
1315
from docutils.parsers.rst.states import RSTState, RSTStateMachine
1416
from sphinx.domains.std import StandardDomain
1517

@@ -19,7 +21,7 @@
1921
class ToxConfig(SphinxDirective):
2022
name = "conf"
2123
has_content = True
22-
option_spec: ClassVar[dict[str, Any]] = {
24+
option_spec: ClassVar[dict[str, Callable[[str], Any]]] = {
2325
"keys": unchanged_required,
2426
"version_added": unchanged,
2527
"version_deprecated": unchanged,

0 commit comments

Comments
 (0)