I encounter this error when running dharma on Windows
Traceback (most recent call last): File "d:\softwares\python\python38\lib\runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "d:\softwares\python\python38\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "D:\softwares\Python\Python38\Scripts\dharma.exe\__main__.py", line 9, in <module> File "d:\softwares\python\python38\lib\site-packages\dharma\dharma.py", line 71, in main dharma.process_grammars(args.grammars) File "d:\softwares\python\python38\lib\site-packages\dharma\core\dharma.py", line 520, in process_grammars grammars.insert(0, open(os.path.relpath(os.path.join(os.path.dirname(os.path.abspath(__file__)), File "d:\softwares\python\python38\lib\ntpath.py", line 703, in relpath raise ValueError("path is on mount %r, start on mount %r" % ( ValueError: path is on mount 'd:', start on mount 'E:'
Suggest fix:
remove os.path.relpath in dharma.py:517grammars.insert(0, open(os.path.join(os.path.dirname(os.path.abspath(__file__)), os.path.normcase(path))))
I encounter this error when running dharma on Windows
Traceback (most recent call last): File "d:\softwares\python\python38\lib\runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "d:\softwares\python\python38\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "D:\softwares\Python\Python38\Scripts\dharma.exe\__main__.py", line 9, in <module> File "d:\softwares\python\python38\lib\site-packages\dharma\dharma.py", line 71, in main dharma.process_grammars(args.grammars) File "d:\softwares\python\python38\lib\site-packages\dharma\core\dharma.py", line 520, in process_grammars grammars.insert(0, open(os.path.relpath(os.path.join(os.path.dirname(os.path.abspath(__file__)), File "d:\softwares\python\python38\lib\ntpath.py", line 703, in relpath raise ValueError("path is on mount %r, start on mount %r" % ( ValueError: path is on mount 'd:', start on mount 'E:'
Suggest fix: remove
os.path.relpath
indharma.py:517
grammars.insert(0, open(os.path.join(os.path.dirname(os.path.abspath(__file__)), os.path.normcase(path))))