Home | History | Annotate | Download | only in harness

Lines Matching refs:path

25 def load_py_module(path):
29 path: String path to python file.
34 assert isinstance(path, str)
36 if not os.path.exists(path):
37 print('Path does not exist: ' + path)
39 path = os.path.abspath(path)
40 module_dir, module_file = os.path.split(path)
41 module_name, _ = os.path.splitext(module_file)
42 # adjust sys.path, runtime counterpart of PYTHONPATH, to temporarily
44 sys.path.append(module_dir)
46 sys.path.pop(0)