From a504ac6100a577cbda1bedf80d69636603ee287c Mon Sep 17 00:00:00 2001 From: danieleades <33452915+danieleades@users.noreply.github.com> Date: Mon, 18 Jul 2022 22:08:16 +0100 Subject: Improve static typing strictness (#10569) --- sphinx/setup_command.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sphinx/setup_command.py') diff --git a/sphinx/setup_command.py b/sphinx/setup_command.py index 5e63df3a7..bbeaa2281 100644 --- a/sphinx/setup_command.py +++ b/sphinx/setup_command.py @@ -7,7 +7,7 @@ import os import sys import warnings from io import StringIO -from typing import Any, Dict +from typing import Any, Dict, Optional from sphinx.application import Sphinx from sphinx.cmd.build import handle_exception @@ -90,15 +90,15 @@ class BuildDoc(Command): def initialize_options(self) -> None: self.fresh_env = self.all_files = False self.pdb = False - self.source_dir: str = None - self.build_dir: str = None + self.source_dir: Optional[str] = None + self.build_dir: Optional[str] = None self.builder = 'html' self.warning_is_error = False self.project = '' self.version = '' self.release = '' self.today = '' - self.config_dir: str = None + self.config_dir: Optional[str] = None self.link_index = False self.copyright = '' # Link verbosity to distutils' (which uses 1 by default). -- cgit v1.2.1