Sublime Forum

Create Package File Not working


I have made plugin and placed under ‘Packages’ folder.

All its feature are working fine no issues at all, my plugin requires python 3.8 so created the .python-version with 3.8 in it in the root of my plugin folder.

But now i want to create its .sublime-package everytime i hit Create Package File it gives error on type hinting and f strings, which is weird since its supported on python 3.8 and my plugin is also working fine.

Example error

Traceback (most recent call last):
  File "./python3.3/", line 115, in compile_file
  File "./python3.3/", line 125, in compile
py_compile.PyCompileError:   File "/Users/abhishek/Library/Application Support/Sublime Text 3/Packages/pyrock/src/commands/", line 41
    response: Optional[Dict] = Network.get(...)
SyntaxError: invalid syntax

From error it looks like its still using python 3.3 to compile the package.



Package Control 3.x supports python 3.3 only. It doesn’t know anything about python 3.8 being an option.

Unfortunatelly, compiler is always invoked, even for default package profile, which excludes compiled modules. Thus any python 3.8+ source is not supported.



So what are my options here?

The plugin is working fine, its just that i am not able to Create package for it.



Just zip the content of your package’s folder, name the archive <Package Name>.sublime-package.

Shipping compiled modules is however not easily possible, without manually creating a plugin, which compiles code using python 3.8.

Note: Package Control downloads archives from ordinary upstream code repositories and installs them as sublime-package file.



Its giving this error now

Error loading /Users/abhishek/Library/Application Support/Sublime Text 3/Installed Packages/pyrock.sublime-package: File is not a zip file