diff --git a/breathe/directives/setup.py b/breathe/directives/setup.py index 58768f89..af0d9b75 100644 --- a/breathe/directives/setup.py +++ b/breathe/directives/setup.py @@ -73,22 +73,22 @@ def set_temp_data( for name, directive in directives.items(): app.add_directive(name, directive) - app.add_config_value("breathe_projects", {}, True) # Dict[str, str] - app.add_config_value("breathe_default_project", "", True) # str + app.add_config_value("breathe_projects", {}, "env") # Dict[str, str] + app.add_config_value("breathe_default_project", "", "env") # str # Provide reasonable defaults for domain_by_extension mapping. Can be overridden by users. app.add_config_value( "breathe_domain_by_extension", {"py": "py", "cs": "cs"}, True ) # Dict[str, str] - app.add_config_value("breathe_domain_by_file_pattern", {}, True) # Dict[str, str] - app.add_config_value("breathe_projects_source", {}, True) - app.add_config_value("breathe_build_directory", "", True) - app.add_config_value("breathe_default_members", (), True) + app.add_config_value("breathe_domain_by_file_pattern", {}, "env") # Dict[str, str] + app.add_config_value("breathe_projects_source", {}, "env") + app.add_config_value("breathe_build_directory", "", "env") + app.add_config_value("breathe_default_members", (), "env") app.add_config_value("breathe_show_define_initializer", False, "env") app.add_config_value("breathe_show_enumvalue_initializer", False, "env") app.add_config_value("breathe_show_include", True, "env") - app.add_config_value("breathe_implementation_filename_extensions", [".c", ".cc", ".cpp"], True) - app.add_config_value("breathe_doxygen_config_options", {}, True) - app.add_config_value("breathe_doxygen_aliases", {}, True) + app.add_config_value("breathe_implementation_filename_extensions", [".c", ".cc", ".cpp"], "env") + app.add_config_value("breathe_doxygen_config_options", {}, "env") + app.add_config_value("breathe_doxygen_aliases", {}, "env") app.add_config_value("breathe_use_project_refids", False, "env") app.add_config_value("breathe_order_parameters_first", False, "env") app.add_config_value("breathe_separate_member_pages", False, "env") diff --git a/breathe/renderer/filter.py b/breathe/renderer/filter.py index 31f90ce3..3860b2f9 100644 --- a/breathe/renderer/filter.py +++ b/breathe/renderer/filter.py @@ -326,7 +326,7 @@ def __call__(self, node_stack) -> str: except AttributeError as e: # Horrible hack to silence errors on filtering unicode objects # until we fix the parsing - if type(data_object) == str: + if type(data_object) is str: return "unicode" else: raise e diff --git a/breathe/renderer/sphinxrenderer.py b/breathe/renderer/sphinxrenderer.py index c2e4ffe9..ea0ecb5f 100644 --- a/breathe/renderer/sphinxrenderer.py +++ b/breathe/renderer/sphinxrenderer.py @@ -1,5 +1,4 @@ import os -import sphinx from breathe.parser import compound, compoundsuper, DoxygenCompoundParser from breathe.project import ProjectInfo diff --git a/pyproject.toml b/pyproject.toml index f3a233a5..df10b389 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,6 +59,7 @@ lint = [ "mypy>=1", "types-docutils", "types-Pygments", + "pytest>=8.0", # for mypy ] test = [ "pytest>=8.0",