Open deathaxe opened 1 week ago
Downloaded JSCustom today, can't get it to work on macos (No module named 'package_control.package_manager'
):
Traceback (most recent call last):
File "/Applications/Sublime Text.app/Contents/MacOS/Lib/python33/sublime_plugin.py", line 308, in reload_plugin
m = importlib.import_module(modulename)
File "./python3.3/importlib/__init__.py", line 90, in import_module
File "<frozen importlib._bootstrap>", line 1584, in _gcd_import
File "<frozen importlib._bootstrap>", line 1565, in _find_and_load
File "<frozen importlib._bootstrap>", line 1532, in _find_and_load_unlocked
File "/Applications/Sublime Text.app/Contents/MacOS/Lib/python33/sublime_plugin.py", line 1686, in load_module
exec(compile(source, source_path, 'exec'), mod.__dict__)
File "/Users/juliangarnier/Library/Application Support/Sublime Text/Installed Packages/JSCustom.sublime-package/plugin.py", line 4, in <module>
ImportError: No module named 'package_control.package_manager'
Could this be related to not using Python 3.8?
Yes, Package Control 4 runs on python 3.8. Only package_control.events
is being made globally available. package_manager
is a private module abused by some plugins.
EDIT: https://github.com/Thom1729/Sublime-JS-Custom/commit/1d27abd908bac3a97a7f1460649688bcf20384fc fixes PC4 incompatibilities, but it seems not having been released yet.
OK thanks, does it mean it’s not possible to use this package anymore with ST4? Is it possible to downgrade to a compatible version of package manager on macOS? (Can’t find a build anterior to 4)
EDIT: just saw your edit :)
You can wait for next release or temporarily add this repo to PC4 directly.
Package Control: Add repository
https://github.com/Thom1729/Sublime-JS-Custom
)This will tell PC to install JSCustom from latest master.
It is NOT RECOMMENDED to downgrade Package Control. PC3 is no longer working properly on recent MacOS releases and also starts failing on recent Linux releases.
It's also not PC to blame for other packages abusing it.
You can wait for next release or temporarily add this repo to PC4 directly.
- Open command palette
- Call
Package Control: Add repository
- Paste URL of this repo (
https://github.com/Thom1729/Sublime-JS-Custom
)This will tell PC to install JSCustom from latest master.
Great I managed to get it to run, thank you!
I had to instal both versions, the up to date "Sublime-JS-Custom" and the old "JSCustom" one in order to get it to work though. Without installing the old one, I had this error "The settings file "res://Packages/JSCustom/sublime/JS Custom.sublime-settings" could not be opened"
It appears to work, at least I can see the syntaxes in the status bar, but both are loaded at the same time:
Edit: I manually deleted the old JSCustom.sublime-package, and renamed the new one "JSCustom.sublime-package" and it's now working without having to load both.
I forgot about the method installing package with unmodified repository name.
To fix it, you can add the following name translation to Package Control.sublime-settings
"package_name_map":
{
"Sublime-JS-Custom": "JSCustom",
},
Ideally, PC would offer an input to configure such custom naming, when adding new git repositories.
Whoops! When I read the problem, I was sure I'd fixed it — but it doesn't count if I never actually released it. v4.4.0 is out with the patch.
I'm hoping to get some more work done this week.
How about migrating this package to python 3.8
It requires some adjustments due to updated ruamel-yaml library (see: https://github.com/packagecontrol/channel/pull/12).