Ken McIvor wrote:
>> This qualifies as a wx bug, doesn't it?
> I believe so.  I'll file it.

I agree - a segfault is ALWAYS a bug.

>> If wx doesn't retain the reference, then instead of a segfault  
>> shouldn't it raise an exception?
> 
> I'd expect wx.GetApp() to work like the rest of wxPython and always  
> return the wx.App instance.

If a wx.App has not been created, it returns None:

 >>> import wx
 >>> wx.GetApp()
 >>> a = wx.GetApp()
 >>> print a
None

Which is probably what it should do if the wxApp() has been deleted.

In any case, you can only create one wxApp per program instance, and it 
can not be destroyed and re-started, so keeping a global instance around 
is probably the way to go.

-Chris

-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[EMAIL PROTECTED]

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to