Ticket #1592 (closed: fixed)

Opened 10 years ago

Last modified 5 years ago

Importing mantid into wrong python shouldn't segfault

Reported by: Peter Peterson Owned by: Martyn Gigg
Priority: critical Milestone: Release 2.6
Component: Python Keywords: Maintenance
Cc: Blocked By:
Blocking: Tester: Roman Tolchenov

Description

On SNS analysis computers more than one python is installed. It is quite easy to start the python that mantid wasn't compiled against and segfault during from MantidFramework import mtd. Try to print an error message before breaking.

Change History

comment:1 Changed 10 years ago by Nick Draper

  • Owner set to Martyn Gigg
  • Status changed from new to assigned
  • Component set to Mantid

comment:2 Changed 10 years ago by Nick Draper

  • Milestone changed from Iteration 26 to Iteration 27

Bulk move of tickets to iteration 27, if your ticket is essential for Iteration 26 then move it back.

comment:3 Changed 10 years ago by Nick Draper

  • Milestone changed from Iteration 27 to Iteration 28

Bulk move of tickets at the end of iteration 27

comment:4 Changed 9 years ago by Nick Draper

  • Milestone changed from Iteration 28 to Iteration 29

Bulk move of tickets at the end of iteration 28

comment:5 Changed 9 years ago by Nick Draper

  • Milestone changed from Iteration 29 to Iteration 30

Accepted and assigned tickets moved at iteration 29 code freeze

comment:6 Changed 9 years ago by Nick Draper

  • Milestone changed from Iteration 30 to Iteration 31

Bulk move of tickets to iteration 31 at the iteration 30 code freeze

comment:7 Changed 9 years ago by Nick Draper

  • Milestone changed from Iteration 32 to Iteration 33

Moved to iteration 33 at iteration 32 code freeze

comment:8 Changed 8 years ago by Nick Draper

  • Milestone changed from Release 2.1 to Release 2.2

Moved at end of release 2.1

comment:9 Changed 8 years ago by Nick Draper

  • Milestone changed from Release 2.2 to Release 2.3

Moved at the end of release 2.2

comment:10 Changed 8 years ago by Nick Draper

  • Milestone changed from Release 2.3 to Release 2.4

Moved to milestone 2.4

comment:11 Changed 8 years ago by Martyn Gigg

  • Milestone changed from Release 2.4 to Release 2.5

comment:12 Changed 8 years ago by Martyn Gigg

  • Priority changed from minor to blocker
  • Milestone changed from Release 2.5 to Release 2.6

Moved to task for maintenance at start of next release.

comment:13 Changed 7 years ago by Nick Draper

  • Keywords Maintenance added
  • Priority changed from blocker to critical

comment:14 Changed 7 years ago by Martyn Gigg

  • Status changed from assigned to accepted

comment:15 Changed 7 years ago by Martyn Gigg

Perform a check on the Python version on startup. Refs #1592

Now only Python versions with matching major/minor numbers will be able to import mantid.

Changeset: 7f525562f4f3e0c1387da316700ad1b64512e367

comment:16 Changed 7 years ago by Martyn Gigg

Merge branch 'feature/1592_runtime_py_version_check' into develop

comment:17 Changed 7 years ago by Martyn Gigg

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

Branch: feature/1592_runtime_py_version_check

Tester: This will require using version of Python with a different major.minor number than was used to build Mantid. On Windows you can download this: http://www.python.org/download/releases/2.6.6/. Mac should have several versions installed and Linux package managers generally have other versions available to install.

Importing the new Python API, import mantid, should exit with an ImportError saying that that there is a version mismatch.

comment:18 Changed 7 years ago by Roman Tolchenov

  • Status changed from verify to verifying
  • Tester set to Roman Tolchenov

comment:19 Changed 7 years ago by Roman Tolchenov

Merge remote-tracking branch 'origin/feature/1592_runtime_py_version_check' into master

comment:20 Changed 7 years ago by Roman Tolchenov

  • Status changed from verifying to closed

It works

comment:21 Changed 7 years ago by Nick Draper

  • Component changed from Mantid to Framework

comment:22 Changed 7 years ago by Nick Draper

  • Component changed from Framework to Python API

comment:23 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 2439

Note: See TracTickets for help on using tickets.