truncate_path has introduced an error when loading the Settings window, since cal_series_path is None by default. Perhaps truncate path needs to accept None and just return that if so?
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Users\thom_\anaconda3\envs\pycam\lib\tkinter\__init__.py", line 1892, in __call__
return self.func(*args)
File "C:\Users\thom_\Documents\Work\PyCamPermanent\pycam\gui\figures_analysis.py", line 2980, in generate_frame
self.cal_series_label = ttk.Label(path_frame, text=self.cal_series_path_short, width=self.path_widg_length,
File "C:\Users\thom_\Documents\Work\PyCamPermanent\pycam\gui\figures_analysis.py", line 3127, in cal_series_path_short
return truncate_path(self.cal_series_path, self.path_str_length)
File "C:\Users\thom_\Documents\Work\PyCamPermanent\pycam\utils.py", line 293, in truncate_path
raise ValueError("path length should be greater than 0")
ValueError: path length should be greater than 0
truncate_path
has introduced an error when loading the Settings window, sincecal_series_path
isNone
by default. Perhaps truncate path needs to acceptNone
and just return that if so?