Opened 4 years ago

Last modified 2 months ago

#3009 new defect

"Quit GRASS GIS" button only exits GUI

Reported by: cmbarton Owned by: grass-dev@…
Priority: normal Milestone: 7.8.3
Component: wxGUI Version: unspecified
Keywords: "quit grass gis button" Cc:
CPU: Unspecified Platform: MacOSX

Description

For some time, quitting GRASS from the GUI opens a dialog (see attached) with buttons to "Close GUI" and "Quit GRASS GIS".

But both do the same thing: quitting the GUI but not exiting GRASS. At least that is what happens on the Mac. Is this the case on other platforms too?

Attachments (1)

GRASS_quit_dialog.png (22.1 KB) - added by cmbarton 4 years ago.
Quit GRASS dialog

Download all attachments as: .zip

Change History (12)

Changed 4 years ago by cmbarton

Attachment: GRASS_quit_dialog.png added

Quit GRASS dialog

comment:1 Changed 4 years ago by annakrat

Platform: UnspecifiedMacOSX

Yes, other platforms work.

comment:2 Changed 4 years ago by neteler

Milestone: 7.0.57.0.6

comment:3 Changed 2 years ago by neteler

Milestone: 7.0.67.0.7

comment:4 Changed 13 months ago by martinl

Still relevant?

comment:5 Changed 13 months ago by cmbarton

Yes. Quit GRASS button does not work on the Mac

comment:6 Changed 13 months ago by martinl

Milestone: 7.0.77.6.2

comment:7 Changed 3 months ago by nila

This is still an issue with 7.8 branch and master (7.9.dev), with Python 3.8.2 and wxPython 4.0.7.post2.

comment:8 Changed 3 months ago by nila

I believe I have found the cause of this issue.

In gui/wxpython/lmgr/frame.py:2533-2536 GMFrame.OnCloseWindowOrExit():

        if ret != wx.ID_CANCEL:
            self._closeWindow(event)
            if ret == wx.ID_YES:
                self._quitGRASS()

in self._closeWindow self (the GMFrame) will be destroyed and self._quitGRASS will never be reached.

comment:9 Changed 3 months ago by nila

I was wrong in my previous assessment.

Now I found the bug and the PR#408 may fix this issue.

comment:10 in reply to:  8 Changed 2 months ago by annakrat

Replying to nila:

I believe I have found the cause of this issue.

In gui/wxpython/lmgr/frame.py:2533-2536 GMFrame.OnCloseWindowOrExit():

        if ret != wx.ID_CANCEL:
            self._closeWindow(event)
            if ret == wx.ID_YES:
                self._quitGRASS()

in self._closeWindow self (the GMFrame) will be destroyed and self._quitGRASS will never be reached.

Are you sure this is not the case? It seems like that would be a problem. Not sure what the solution would be, perhaps moving the os.kill to the GMApp OnExit? handler.

comment:11 Changed 2 months ago by neteler

Milestone: 7.6.27.8.3
Note: See TracTickets for help on using tickets.