SciTE issues when running a Python script


ApplicationPLAXIS 2D
PLAXIS 3D
Issue status Solved
First Affected VersionPLAXIS 2D CONNECT Edition V20 Update  2
PLAXIS 3D CONNECT Edition V20 Update  2
Found in VersionPLAXIS 2D CONNECT Edition V20 Update  2
PLAXIS 3D CONNECT Edition V20 Update  2
Fixed and Released in VersionPLAXIS 2D CONNECT Edition V20 Update  3
PLAXIS 3D CONNECT Edition V20 Update  3
Issue #SW-47996
Date created5 June 2020
Date modified26 June 2020

Problem description

With PLAXIS CONNECT Edition V20 Update 2, the PLAXIS Python Distribution is placed in a dedicated location within the ProgramData folder. By default, this is:
C:\ProgramData\Bentley\Geotechnical\PLAXIS Python Distribution v1.0.0

This allows for both PLAXIS 2D and PLAXIS 3D applications to access this shared distribution for all the functionality that use Python Scripting facilities, keeping all modules up to date and fully compatible with PLAXIS.

For that reason, SciTE fails to identify the Python properties of a PY script (*.py), which causes issues when you want to run a Python script with SciTE.
One will notice when saving a Python script using the .py extension that the Python code is not rendered with syntax highlighting and, more importantly, option to run the script in Tools > Go (F5) is not available.

Note: this does not affect the options Run Python script or Run Python tool under PLAXIS Expert menu.

Solution/Workaround

This is now solved in PLAXIS 2D and PLAXIS 3D V20 Update 3

When using PLAXIS 2D/3D CONNECT Edition V20 Update 2, please follow the steps below to solve it:

  1. Download and unpack the attached file python_properties_file.zip
  2. Go to the installation folder of PLAXIS 2D/3D and navigate to the SciTE's folder, which is by default
    C:\Program Files\Bentley\Geotechnical\PLAXIS 2D CONNECT Edition V20\tools\wscite
    C:\Program Files\Bentley\Geotechnical\PLAXIS 3D CONNECT Edition V20\tools\wscite
  3. Paste the downloaded python.properties file here (administrative rights are required)
  4. Restart SciTE and PLAXIS 2D/3D and finally:
    1. Start SciTE
    2. Python script files (with .py extension) will be recognized again

Note: this workaround will only work when the PLAXIS Python distribution is installed in the default location:
C:\ProgramData\Bentley\Geotechnical\PLAXIS Python Distribution v1.0.0

This includes separate files for PLAXIS 2D and PLAXIS 3D. The folder to paste the python.properties file is:
C:\Program Files\Plaxis\PLAXIS 2D\tools\wscite
C:\Program Files\Plaxis\PLAXIS 3D\tools\wscite

Be aware that the python.properties file requires the UTF-8 encoding to be recognized by SciTE.

Downloads