Menu

#131 Ondoing displaying a spectrum leaves graphics program in dyscuctrional state

3.0.0
closed
nobody
None
3
2018-04-12
2016-07-21
Fogh
No

Undoing a spectrum display operation (dropping a spectrum file on an empty display and doing 'undo')
leaves the program trying to do showMousePosition on a deleted strip:

:
AttributeError: 'StripNd' object has no attribute 'orderedAxes'
Traceback (most recent call last):
File "/home/ccpn/SharedCcpn/svnroots/ccpnv3/branches/ccpnmr3.0.b1/ccpnv3/src/python/ccpn/ui/gui/modules/GuiStrip.py", line 647, in _showMousePosition
(self.axisOrder[0], position.x(), self.axisOrder[1], position.y())
AttributeError: 'StripNd' object has no attribute 'axisOrder'

Discussion

  • Fogh

    Fogh - 2016-07-21
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -1,5 +1,5 @@
    -AFter undoing a spectrum display operation (dropping a spectrum file on an empty display and doing 'undo'
    -leqaves the program trying to do showMousePosition on a deleted strip:
    +Undoing a spectrum display operation (dropping a spectrum file on an empty display and doing 'undo')
    +leaves the program trying to do showMousePosition on a deleted strip:
    
     :
     AttributeError: 'StripNd' object has no attribute 'orderedAxes'
    
    • Priority: 5 --> 3
     
  • wb104

    wb104 - 2016-10-10

    Fixed this problem but then hit another problem: the SpectrumDisplay object is deleted but the graphics is still showing. This then leads to exceptions, e.g. in the 1d case when you click on the display (the Nd case is similar):

    |==============================>>
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/runpy.py", line 170, in _run_module_as_main
    |      "__main__", mod_spec)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/runpy.py", line 85, in _run_code
    |      exec(code, run_globals)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/cProfile.py", line 160, in <module>
    |      main()
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/cProfile.py", line 153, in main
    |      runctx(code, globs, None, options.outfile, options.sort)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/cProfile.py", line 20, in runctx
    |      filename, sort)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/profile.py", line 64, in runctx
    |      prof.runctx(statement, globals, locals)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/cProfile.py", line 100, in runctx
    |      exec(cmd, globals, locals)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/src/python/ccpn/AnalysisAssign/__main__.py", line 17, in <module>
    |      application.start()
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/src/python/ccpn/framework/Framework.py", line 252, in start
    |      self.ui.start()
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/src/python/ccpn/ui/gui/Gui.py", line 138, in start
    |      self.qtApp.start()
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/src/python/ccpn/ui/gui/widgets/Application.py", line 39, in start
    |      self.exec_()
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/site-packages/pyqtgraph/widgets/GraphicsView.py", line 353, in mouseReleaseEvent
    |      QtGui.QGraphicsView.mouseReleaseEvent(self, ev)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/site-packages/pyqtgraph/GraphicsScene/GraphicsScene.py", line 203, in mouseReleaseEvent
    |      if (len(cev) > 0) and self.sendClickEvent(cev[0]):
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/site-packages/pyqtgraph/GraphicsScene/GraphicsScene.py", line 351, in sendClickEvent
    |      debug.printExc("Error sending click event:")
    |    ---- exception caught ---->
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/miniconda/lib/python3.5/site-packages/pyqtgraph/GraphicsScene/GraphicsScene.py", line 349, in sendClickEvent
    |      item.mouseClickEvent(ev)
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/src/python/ccpn/ui/gui/ViewBox.py", line 348, in _mouseClickEvent
    |      self._deselectPeaks()
    |    File "/Users/wb104/svnsf/trunk/ccpnv3/src/python/ccpn/ui/gui/ViewBox.py", line 385, in _deselectPeaks
    |      for spectrumView in self.current.strip.spectrumViews:
    |  AttributeError: 'Strip1d' object has no attribute 'spectrumViews'
    |==============================<<
    
     
  • Luca

    Luca - 2018-04-12
     
  • Luca

    Luca - 2018-04-12

    Fixed

     
  • Luca

    Luca - 2018-04-12
    • status: open --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB
Gen AI apps are built with MongoDB Atlas
Atlas offers built-in vector search and global availability across 125+ regions. Start building AI apps faster, all in one place.
Try Free →