Skip to content

Commit 38373a6

Browse files
authored
ci: fix update documentation script (#910)
Fix update documentation script
1 parent 7b534df commit 38373a6

4 files changed

Lines changed: 11 additions & 5 deletions

File tree

.github/workflows/update-septic-docs-pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
with:
5151
add-paths: |
5252
packages/septic/public/*
53-
packages/septic/package.json
53+
packages/extension/package.json
5454
labels: "documentation"
5555
branch: "septic-documentation-${{ env.REF }}"
5656
title: "docs: update Septic documentation for ${{ env.REF }}"

.vscode/launch.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@
77
"configurations": [
88
{
99
"name": "Update Documentation",
10-
"type": "python",
10+
"type": "debugpy",
1111
"request": "launch",
1212
"program": "${workspaceRoot}/scripts/main.py",
13+
"args": ["latest"],
1314
"console": "integratedTerminal",
1415
"justMyCode": true
1516
},

scripts/src/parse_doxygen.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,9 @@ def parse_object_doxygen_doc(doxygen: str) -> Optional[SepticObject]:
9898
attr = parse_attribute(attr_dox)
9999
if attr:
100100
attributes.append(attr)
101-
return SepticObject(name, description, attributes, parents)
101+
return SepticObject(
102+
name=name, description=description, attributes=attributes, parents=parents
103+
)
102104

103105

104106
def parse_attribute(attribute: str) -> Optional[Attribute]:

scripts/src/versioning.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,11 @@ def get_existing_versions(path: Path):
4545
dir_match = re.match(r"v(\d+)_(\d+)", dir.split("\\")[-1])
4646
if not dir_match:
4747
continue
48-
meta = read_meta_file(path / dir / meta_info_name)
49-
versions.append(tuple(int(x) for x in meta["version"].split(".")))
48+
try:
49+
meta = read_meta_file(path / dir / meta_info_name)
50+
versions.append(tuple(int(x) for x in meta["version"].split(".")))
51+
except Exception as e:
52+
print(f"Error reading meta file for {dir}: {e}")
5053
return versions
5154

5255

0 commit comments

Comments
 (0)