Sublime Forum

Can't import lzma

>>> import lzma
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "./python3.3/", line 26, in <module>
ImportError: No module named '_lzma'

Isn’t lzma included by default in Python 3.3? Was it stripped out of the ST3 embedded python?



We do no include it in our build of Python. Your best bet is to compile it and submit it to the default Package Control channel as a dependency.



Reviving the old thread but was curious about availability in sublime text 4, as it seems to be loadable from the console but not from plugins



lzma is included in the Python 3.8 environment. See for info about how to run your plugin on Python 3.8.

1 Like