Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix RuntimeError raised on ST4170+ #412

Merged
merged 1 commit into from
Feb 20, 2024
Merged

Conversation

deathaxe
Copy link
Contributor

Package Control's events module uses sublime.Settings() to provide cross-python-version events. Using events at import time therefore raises a RuntimeError as of ST4170 upon ST start as this API is not yet ready then.

This commit therefore removes Package Control dependency.

Instead all modules are removed from sys.module cache to force reloading each time main.py is reloaded. This strategy is used by various plugins with success.

Package Control's `events` module uses `sublime.Settings()` to provide
cross-python-version events. Using events at import time therefore raises
a `RuntimeError` as of ST4170 upon ST start as this API is not yet ready then.

This commit therefore removes Package Control dependency.

Instead all modules are removed from sys.module cache to force reloading each
time main.py is reloaded. This strategy is used by various plugins with success.
@randy3k
Copy link
Owner

randy3k commented Feb 20, 2024

Thank you. I was also looking into the cause.

@randy3k randy3k merged commit 2be6de8 into randy3k:master Feb 20, 2024
@Afrowave Afrowave mentioned this pull request Feb 20, 2024
@gobijan
Copy link
Contributor

gobijan commented Feb 20, 2024

You guys are amazing <3

@deathaxe deathaxe deleted the fix/st4170 branch February 20, 2024 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants