From 3a10072b38e710ac30b2e027ab19f22d3843974e Mon Sep 17 00:00:00 2001 From: Namnn07 Date: Wed, 30 Aug 2023 14:47:50 +0700 Subject: [PATCH] update version 1.3.0 --- docs/conf.py | 2 +- sphinx_needs/needsfile.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 969433171..eeacb5560 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -362,7 +362,7 @@ def custom_defined_func(): needs_build_json = True # build needs_json for every needs-id to make detail panel -needs_build_json_per_id = False +needs_build_json_per_id = True # Add any paths that contain templates here, relative to this directory. templates_path = ["_templates"] diff --git a/sphinx_needs/needsfile.py b/sphinx_needs/needsfile.py index 25d75dc06..ffae56193 100644 --- a/sphinx_needs/needsfile.py +++ b/sphinx_needs/needsfile.py @@ -93,11 +93,12 @@ def wipe_version(self, version: str) -> None: if version in self.needs_list["versions"]: del self.needs_list["versions"][version] - def write_json(self, needs_file: str = "needs.json", needs_path=None) -> None: + def write_json(self, needs_file: str = "needs.json", needs_path: str = "") -> None: # We need to rewrite some data, because this kind of data gets overwritten during needs.json import. self.needs_list["created"] = datetime.now().isoformat() self.needs_list["current_version"] = self.current_version self.needs_list["project"] = self.project + print(f"tye:{type(needs_path)}") if needs_path: needs_dir = needs_path else: