Ticket #2827 (closed: fixed)

Opened 9 years ago

Last modified 5 years ago

Segfault generated by retrieving wrong property name in python

Reported by: Peter Peterson Owned by: Peter Peterson
Priority: major Milestone: Iteration 28
Component: Mantid Keywords:
Cc: Blocked By:
Blocking: Tester: Vickie Lynch

Description (last modified by Peter Peterson) (diff)

This is a bug seen explicitly in FindSNSNeXus, but it probably exists in other python algorithms. To reproduce it:

  • In PyExec change the 10th line to be self.getProperty("UseWebService")
  • Use the algorithm from another algorithm like SNSPowderReduction

Change History

comment:1 Changed 9 years ago by Peter Peterson

  • Status changed from new to accepted

comment:2 Changed 9 years ago by Peter Peterson

  • Description modified (diff)

comment:3 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:4 Changed 9 years ago by Peter Peterson

  • Milestone changed from Iteration 29 to Iteration 28

comment:5 Changed 9 years ago by Peter Peterson

Here is an algorithm to call the broken version of FindSNSNeXus:

from MantidFramework import *

class BrokenAlgorithm(PythonAlgorithm):
    def name(self):
        return "BrokenAlgorithm"

    def PyInit(self):
        pass

    def PyExec(self):
        import mantidsimple
        globals()["FindSNSNeXus"] = mantidsimple.FindSNSNeXus

        result = FindSNSNeXus(Instrument="PG3",
                              RunNumber=1370, Extension="_event.nxs")
        print "***", result, "gives '%s'" %  result.getProperty("ResultPath").value 

mtd.registerPyAlgorithm(BrokenAlgorithm())

comment:6 Changed 9 years ago by Peter Peterson

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

(In [11144]) Boost was helping a little to much and we should have be grabing the GIL. Fixes #2827.

comment:7 Changed 9 years ago by Vickie Lynch

  • Status changed from verify to verifying
  • Tester set to Vickie Lynch

comment:8 Changed 9 years ago by Vickie Lynch

  • Status changed from verifying to closed

SegFault with above script before svn update, but not after. Ran short SNSPowderReduction script without SegFault.

comment:9 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 3674

Note: See TracTickets for help on using tickets.