When file has been moved, doesn't exist anymore (e.g. old cache file) or has not yet been saved, TrailingSpaces will fail because of not checking for the validity of file_name.
Add a simple try/except and report in the status bar a message hinting to check the file path.
When file has been moved, doesn't exist anymore (e.g. old cache file) or has not yet been saved, TrailingSpaces will fail because of not checking for the validity of
file_name
.Add a simple
try
/except
and report in the status bar a message hinting to check the file path.