SublimeText / Origami

Split the window however you like! Create new panes, delete panes, move and clone views from pane to pane.
MIT License
1.21k stars 82 forks source link

Add .python-version to support newest ST4 #174

Closed gerardroche closed 1 year ago

gerardroche commented 1 year ago

To provide for backward compatibility, Sublime Text 4050 will continue to run all plugins using Python 3.3.

Any package that wishes to use Python 3.8 must create a file named .python-version in the root of the packages. This file should contain either the text 3.3 or 3.8 to select the version of Python to use. If a file named .python-version is not present, or it contains any value other than 3.8, then Python 3.3 will be used.

All plugins in a package will use the same version of Python. Any package with a .python-version file containing 3.8 loaded in older builds of Sublime Text will try to run the plugins using Python 3.3.

https://www.sublimetext.com/docs/api_environments.html#python-version

rchl commented 1 year ago

Any specific benefits that you have in mind with that?

Since we have separate release branch for ST4 anyway, I don't really see any problem with that but just curious.

deathaxe commented 1 year ago

All plugins should opt-in to more recent plugin-host if possible. That's no question of "benefit" but the possibility of hopefully getting rid of the older one at some point.

gerardroche commented 1 year ago

Origami seems to work fine in ST4 and Python 3.8. So now Origami runs in the newer Python 3.8 host in ST4. There are probably some trivial benefits in terms of performance, but as deathaxe says, it's really more about future compatibility.