Skip to content

Commit db3689b

Browse files
committed
fix: Replace type pipe with Optional
1 parent 7e3f6cd commit db3689b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: code_embedder/script_metadata_extractor.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import re
2-
from typing import Protocol
2+
from typing import Optional, Protocol
33

44
from code_embedder.script_metadata import ScriptMetadata
55

@@ -40,7 +40,7 @@ def _is_code_block_start(self, line: str) -> bool:
4040
def _is_code_block_end(self, line: str) -> bool:
4141
return line.strip() == self._code_block_end
4242

43-
def _start_new_block(self, line: str, row: int) -> dict | None:
43+
def _start_new_block(self, line: str, row: int) -> Optional[dict]:
4444
tag_items = line.split(self._path_separator)
4545
path = tag_items[1].strip()
4646
extraction_type = tag_items[2].strip() if len(tag_items) > 2 else "full"

0 commit comments

Comments
 (0)