|
66 | 66 | ) |
67 | 67 | from .util import RST_EXTENSIONS |
68 | 68 |
|
69 | | -# XXX: Work around to get snooty working with Python 3.8 until we can fix |
70 | | -# our implicit data flow issues. |
71 | | -multiprocessing.set_start_method("fork") |
72 | | - |
73 | 69 | NO_CHILDREN = (n.SubstitutionReference,) |
74 | 70 | logger = logging.getLogger(__name__) |
75 | 71 |
|
@@ -581,7 +577,7 @@ def handle_directive( |
581 | 577 | return doc |
582 | 578 |
|
583 | 579 | openapi_fileid, filepath = util.reroot_path( |
584 | | - Path(argument_text), self.docpath, self.project_config.source_path |
| 580 | + FileId(argument_text), self.docpath, self.project_config.source_path |
585 | 581 | ) |
586 | 582 |
|
587 | 583 | try: |
@@ -619,7 +615,7 @@ def create_page() -> Tuple[Page, EmbeddedRstParser]: |
619 | 615 | return doc |
620 | 616 |
|
621 | 617 | _, filepath = util.reroot_path( |
622 | | - Path(argument_text), self.docpath, self.project_config.source_path |
| 618 | + FileId(argument_text), self.docpath, self.project_config.source_path |
623 | 619 | ) |
624 | 620 |
|
625 | 621 | # Attempt to read the literally included file |
@@ -747,7 +743,7 @@ def _locate_text(text: str) -> int: |
747 | 743 | return doc |
748 | 744 |
|
749 | 745 | fileid, path = util.reroot_path( |
750 | | - Path(argument_text), self.docpath, self.project_config.source_path |
| 746 | + FileId(argument_text), self.docpath, self.project_config.source_path |
751 | 747 | ) |
752 | 748 |
|
753 | 749 | # Validate if file exists |
@@ -855,9 +851,8 @@ def validate_list_table( |
855 | 851 | return |
856 | 852 |
|
857 | 853 | def add_static_asset(self, raw_path: str, upload: bool) -> StaticAsset: |
858 | | - path = Path(raw_path) |
859 | 854 | fileid, path = util.reroot_path( |
860 | | - path, self.docpath, self.project_config.source_path |
| 855 | + FileId(raw_path), self.docpath, self.project_config.source_path |
861 | 856 | ) |
862 | 857 | static_asset = StaticAsset.load(raw_path, fileid, path, upload) |
863 | 858 | self.static_assets.add(static_asset) |
@@ -1190,9 +1185,7 @@ def create_page(filename: str) -> Tuple[Page, EmbeddedRstParser]: |
1190 | 1185 | giza_node.path, |
1191 | 1186 | filename, |
1192 | 1187 | text, |
1193 | | - n.Root( |
1194 | | - (-1,), [], self.config.get_fileid(PurePath(filename)), {} |
1195 | | - ), |
| 1188 | + n.Root((-1,), [], self.config.get_fileid(FileId(filename)), {}), |
1196 | 1189 | ) |
1197 | 1190 | return ( |
1198 | 1191 | page, |
@@ -1272,9 +1265,7 @@ def create_page(filename: str) -> Tuple[Page, EmbeddedRstParser]: |
1272 | 1265 | giza_node.path, |
1273 | 1266 | filename, |
1274 | 1267 | giza_node.text, |
1275 | | - n.Root( |
1276 | | - (-1,), [], self.config.get_fileid(PurePath(filename)), {} |
1277 | | - ), |
| 1268 | + n.Root((-1,), [], self.config.get_fileid(FileId(filename)), {}), |
1278 | 1269 | ) |
1279 | 1270 | return ( |
1280 | 1271 | page, |
|
0 commit comments