gillescastel / inkscape-figures

Inkscape figure manager
MIT License
557 stars 119 forks source link

implemented real check for macos vs linux #15

Closed MichaelMaex closed 4 years ago

MichaelMaex commented 4 years ago

The current system loads fswatch only when inotify fails to import. The try except only catches ImportError. On my system (macos Mojave) inotify failed to load, throwing an AttributeError, thus crashing the program. Instead of catching all types of errors (which would catch legitimate errors on linux), it seemed better to directly check the os to decide whether fswatch (for macos) of inotify (for linux) should be used.

gillescastel commented 4 years ago

Thanks for the pull request! I've restructured the code that checks for inotify in 34c20b3aece7, so this pull request now has conflicting files. However, your issue should be fixed, as I updated the logic as well. Closing.