bug: aenea raises WindowsError when Userdirectory is not set in natlink
nihlaeth opened this issue · 4 comments
nihlaeth commented
pull request #131 introduced a bug: userDirectory can be ''
Error loading _translated_grammars from C:\NatLink\NatLink\MacroSystem\_translated_grammars.py
Traceback (most recent call last):
File "C:\NatLink\NatLink\MacroSystem\core\natlinkmain.py", line 309, in loadFile
imp.load_module(modName,fndFile,fndName,fndDesc)
File "C:\NatLink\NatLink\MacroSystem\_translated_grammars.py", line 2, in <module>
import dragonfly_grammars
File "c:\users\nihlaeth\git\dragonfly-grammars\dragonfly_grammars\__init__.py", line 5, in <module>
import dragonfly_grammars.aenea_
File "c:\users\nihlaeth\git\dragonfly-grammars\dragonfly_grammars\aenea_.py", line 26, in <module>
import aenea
File "c:\users\nihlaeth\git\aenea\client\aenea\__init__.py", line 18, in <module>
import aenea.communications
File "c:\users\nihlaeth\git\aenea\client\aenea\communications.py", line 30, in <module>
_server_config.write()
File "c:\users\nihlaeth\git\aenea\client\aenea\configuration.py", line 56, in write
os.makedirs(os.path.split(self._path)[0])
File "C:\Python27-32bit\Lib\os.py", line 157, in makedirs
mkdir(name, mode)
WindowsError: [Error 3] The system cannot find the path specified: ''
nirvdrum commented
Sorry about that. I'll get a fix together shortly.
nihlaeth commented
wow, you're fast. I should have said I was working on a fix myself :)
nirvdrum commented
Well, I hadn't started yet :-) Thanks for the fix! And, again, sorry this broke for you. It proved a bit tricky to test without setting up a whole new Natlink environment.
nihlaeth commented
I get it, this stuff is hard to test in any case. So many setups, so many configs. And it isn't like there's an api spec available for natlink either...