I’m developing a plugin which allows me to create a file which is pre-saved so that I can execute it immediately. The file is deleted upon closure so it’s useful to quickly test code. However, I’m having problems loading and retrieving settings. I have the sublime.load_settings(...) which produces the correct <sublime.Settings object at ...>. My problem lies where I use settings.get(...) which seems to return None when I first start up Sublime. However, if I save the plugin file - it reloads the plugin and the retrieval of the settings works fine. It’s very odd and has only recently begun happening.
I can’t really give any test code to recreate the problem as I can’t tell if it’s a local problem or not. Any idea why trying to get the settings when the plugin loads doesn’t work. FYI, the call to settings.get happens in the global scope (not in a TextCommand class) and I assign the results to global variables instead of giving each class a self.settings attribute.