How to install Python modules in Dynamo Core Runtime 2.8.0?

Hi,
a workaround to avoid changing the sys.path for each version of Dynamo :wink:

import sys
import clr
import System
import re
clr.AddReference('ProtoGeometry')
from Autodesk.DesignScript.Geometry import *

reDir = System.IO.DirectoryInfo(re.__file__)
path_py3_lib = reDir.Parent.Parent.FullName
sys.path.append(path_py3_lib + r'\Lib\site-packages')

OUT = path_py3_lib

It’s possible to install automatically pip at initialization Python3 engine for next versions of Dynamo ?

2 Likes