Environment Variables

Oasis montaj does not ship with its own Python interpreter. It uses dynamic loading and the version independent Python C API for embedded Python script executions. This means any Windows x64 Python distribution that uses Python 3.4 or higher can be used.

The location of the Python interpreter used and its behaviour during embedded Python script executions inside Oasis montaj can be controlled in two ways:

  1. Using global environment variables. These will override any registry keys. A GEOSOFT_ prefix needs to be added to the registry entry equivalent in this case.
  2. Adding registry entires to the Core Enviroment registry key for the montaj install at HKEY_LOCAL_MACHINE\SOFTWARE\Geosoft\Core\Environment  

Optional environment variables will override the default behavior:

  1. PYTHON_HOME: Location of Python distribution (3.4+) to use.
  2. PYTHON_DLL: Oasis montaj will attempt to launch a background process of the Python.exe interpreter it finds at the home and then uses process inspection to determine the location of its Python dll which it would need to load to embed the interpreter within montaj. This variable should not be necessary but is provided in case some situations arise where this mechanism does not work properly.
  3. PYTHON_SHOW_CONSOLE : Spawns a console for the duration of every script. print statements and any other console data will be directed to and from this console. The console will require user input to dismiss it.