Can I use Python Packages in my Custom Extension?

Although we don't support this yet, it's certainly something we will want to support in the future. We're currently tracking the feature request here, so feel free to vote and comment on it!


For local extensions that you are developing, there is a workaround for loading Python packages. The workaround is shared in this discuss forum post.

The solution is also summarized below. The user wanted to add protobuf analysis capabilities to their HLA.

You can modify the sys.path in your extension file to include the directory that you installed the Python package to:

import sys
MY_ADDITIONAL_PACKAGES_PATH = '/packages/install/location'
import protobuf

Note that /packages/install/location is the directory where you installed the packages, not the path to the package itself.

One caveat is that you can't publish extensions to our Extensions Marketplace if it uses external Python packages, mainly because they won't work on other users' PCs. Therefore, external Python package usage is limited to local use only until we add proper support for it.