Thanks a lot for writing and sharing this very nice and helpful software!
A potential caveat for new users is a permission problem for the log file when running rayoptics in a directory for which the user does not have write permissions:
(rayoptics) C:\Users>rayoptics
Traceback (most recent call last):
File "C:\Users\user\Anaconda3\envs\rayoptics\Scripts\rayoptics-script.py", line 9, in <module>
sys.exit(main())
File "C:\Users\users\Anaconda3\envs\rayoptics\lib\site-packages\rayoptics\qtgui\rayopticsapp.py", line 563, in main
logging.basicConfig(filename='rayoptics.log',
File "C:\Users\users\Anaconda3\envs\rayoptics\lib\logging\__init__.py", line 2003, in basicConfig
h = FileHandler(filename, mode,
File "C:\Users\users\Anaconda3\envs\rayoptics\lib\logging\__init__.py", line 1146, in __init__
StreamHandler.__init__(self, self._open())
File "C:\Users\users\Anaconda3\envs\rayoptics\lib\logging\__init__.py", line 1175, in _open
return open(self.baseFilename, self.mode, encoding=self.encoding,
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\rayoptics.log'
Handling this as an exception in line 563 of rayopticsapp.py might be a possible fix:
Thanks a lot for writing and sharing this very nice and helpful software!
A potential caveat for new users is a permission problem for the log file when running
rayoptics
in a directory for which the user does not have write permissions:Handling this as an exception in line 563 of
rayopticsapp.py
might be a possible fix:Since different operating systems use different directories for log files, I find it difficult to find a good cross-platform solution.