File tree Expand file tree Collapse file tree 1 file changed +21
-10
lines changed
misc/scripts/models-as-data Expand file tree Collapse file tree 1 file changed +21
-10
lines changed Original file line number Diff line number Diff line change 1616import tarfile
1717import shutil
1818
19+
1920def missing_module (module_name : str ) -> None :
20- print (f"ERROR: { module_name } is not installed. Please install it with 'pip install { module_name } '." )
21+ print (
22+ f"ERROR: { module_name } is not installed. Please install it with 'pip install { module_name } '."
23+ )
2124 sys .exit (1 )
2225
26+
2327try :
2428 import yaml
2529except ImportError :
@@ -41,14 +45,19 @@ def missing_module(module_name: str) -> None:
4145
4246
4347# A project to generate models for
44- Project = TypedDict ("Project" , {
45- "name" : Required [str ],
46- "git-repo" : str ,
47- "git-tag" : str ,
48- "with-sinks" : bool ,
49- "with-sources" : bool ,
50- "with-summaries" : bool ,
51- }, total = False )
48+ Project = TypedDict (
49+ "Project" ,
50+ {
51+ "name" : Required [str ],
52+ "git-repo" : str ,
53+ "git-tag" : str ,
54+ "with-sinks" : bool ,
55+ "with-sources" : bool ,
56+ "with-summaries" : bool ,
57+ },
58+ total = False ,
59+ )
60+
5261
5362def should_generate_sinks (project : Project ) -> bool :
5463 return project .get ("with-sinks" , True )
@@ -107,7 +116,9 @@ def clone_project(project: Project) -> str:
107116 return target_dir
108117
109118
110- def run_in_parallel [T , U ](
119+ def run_in_parallel [
120+ T , U
121+ ](
111122 func : Callable [[T ], U ],
112123 items : List [T ],
113124 * ,
You can’t perform that action at this time.
0 commit comments