Sublime Forum

Plugin dev : reload plugin = empty completions slots

#1

Hello,

I wrote following test plugin and it is giving strange results in sublime3 (linux debian 64bit).

When editing and reloading the plugin the auto complete will show ‘empty’ slots in the auto-complete dropdownbox. and will do nothing when you select a slot.
But when I restart sublime it seems the slots are correctly filled.
If I change the plugin and it reloads it, then sublime shows again empty dropdown boxes.

So as long as I start with a clean sublime it works fine, but this is a pain in the ass to develop :smile:

Thanks a lot !

Sven

===

import sublime, sublime_plugin
class completionAssist(sublime_plugin.EventListener):
def on_query_completions(self, view, prefix, locations):
autocompletionsToReturn = ‘my’,‘asdf’], ‘auto’,‘asdf’], ‘complete’,‘asdf’] ]
return (autocompletionsToReturn, sublime.INHIBIT_WORD_COMPLETIONS | sublime.INHIBIT_EXPLICIT_COMPLETIONS)

0 Likes