Ticket #5093 (closed: fixed)

Opened 8 years ago

Last modified 5 years ago

New Python API on OS X won't start from stand alone python

Reported by: Martyn Gigg Owned by: Martyn Gigg
Priority: major Milestone: Release 2.1
Component: Mantid Keywords:
Cc: Blocked By:
Blocking: Tester: Russell Taylor

Description

The new python API uses @executable_path inside the _geometry.so & _api.so libraries to find the dependencies. In MantidPlot this is fine but in standalone python this fails as @executable_path resolves to the location of the python executable. We need to use @loader_path

To reproduce on OS X:

  • Open a console and set the python path: export PYTHONPATH=/Applications/MantidPlot.app/Contents/MacOS
  • Start python
  • Import mantid with 'import mantid' and an import error is raised

Change History

comment:1 Changed 8 years ago by Martyn Gigg

  • Status changed from new to accepted

comment:2 Changed 8 years ago by Martyn Gigg

Use @loader_path in bundle on OS X for new PythonAPI. Refs #5093

The @executable_path references the executable's path but from standalone python this is the location of python and not the Mantid libraries. Use @loader_path instead so that it references the location of loading library.

Changeset: 5b64acec3d5f48734e7b34aae8a0c57fb161a3a2

comment:3 Changed 8 years ago by Martyn Gigg

  • Status changed from accepted to verify
  • Resolution set to fixed

comment:4 Changed 8 years ago by Russell Taylor

  • Status changed from verify to verifying
  • Tester set to Russell Taylor

comment:5 Changed 8 years ago by Russell Taylor

  • Status changed from verifying to closed

Confirmed working in 2.0.2345-g1a0f8f5

comment:6 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 5939

Note: See TracTickets for help on using tickets.