Open benjamin-kirkbride opened 1 year ago
This is also a problem when opening a tab for the first time. The filetype is not known in time. We need a new event for when the tab has changed and everything is "settled"
I tried adding setup_after = ["filetypes"]
to python_tools.py
but that didn't seem to make a difference, not sure why though because I believe this is an issue with the order in which things are getting bound to <<NotebookTabChanged>>
Not sure if my solution is the best/right way to do it, but it does seem robust (based on the test I made)
If we are happy with the way this was done this can be closed
Note
availability_callback
When I open Porcupine:
And the menu items are not there.
If I switch to another tab and switch back, then it works, no more errors.
I assume this is some sort of dependency issue where the options don't get loaded before the plugins do, or something. Thoughts on how to handle this?
Originally posted by @benjamin-kirkbride in https://github.com/Akuli/porcupine/issues/1349#issuecomment-1629851422