f



C++ assertion "wxAssertFailure" failed

[[ This message was both posted and mailed: see
   the 'To' and 'Newsgroups' headers for details. ]]

Hello,

I'm trying to run Faces (a project management application implemented in 
Python using wxPython for the GUI, see http://faces.homeip.net/) on my Mac 
(G5 with Mac OS X 10.4.6), but so far it won't work.

Here's the traceback I get:

"/Library/Frameworks/Python.framework/Versions/2.4/bin/python" -O  
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/bin/faces.py"  && echo Exit status: $? && exit 1
Traceback (most recent call last):
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/bin/faces.py", line 5, in ?
    sys.exit(main())
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/gui/plangui.py", line 1181, in main
    app = FacesApp(False)
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/metapie/gui/controller.py", line 1136, in __init__
    wx.App.__init__(self, *args, **kwargs)
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/_core.py", line 7700, in __init__
    self._BootstrapApp()
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/_core.py", line 7352, in _BootstrapApp
    return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/gui/plangui.py", line 1089, in OnInit
    self.show_splash(True)
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/gui/plangui.py", line 1098, in show_splash
    text = RenderToBitmap(splash_text)
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 353, in RenderToBitmap
    width, height, dy = GetFullExtent(str, dc, enclose)
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 346, in GetFullExtent
    RenderToRenderer(str, renderer, enclose)
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 329, in 
RenderToRenderer
    p.Parse(str, 1)
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 137, in characterData
    self.y = self.mayY = self.maxY + self.dc.GetTextExtent("M")[1]
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/_gdi.py", line 3435, in GetTextExtent
    return _gdi_.DC_GetTextExtent(*args, **kwargs)
wx._core.PyAssertionError: C++ assertion "wxAssertFailure" failed in 
/Users/kevino/oss/wx26/wxWidgets/src/mac/carbon/dc.cpp(1482): Invalid DC

Here is what I did:

- Installed Python from 
http://pythonmac.org/packages/py24-fat/dmg/Universal-MacPython-2.4.3-2006-04-
07.dmg
- Installed Numeric from 
http://prdownloads.sourceforge.net/numpy/Numeric-24.2.tar.gz?download
- Installed Matplotlib from 
http://pythonmac.org/packages/py24-fat/mpkg/matplotlib-0.87.2-py2.4-
macosx10.4.mpkg.zip
- Installed wxPython from 
http://pythonmac.org/packages/py24-fat/dmg/wxPython2.6-osx-unicode-2.6.3.2rc2-
universal10.4-py2.4.dmg
- Installed Cheetah from 
http://prdownloads.sourceforge.net/cheetahtemplate/Cheetah-
1.0.tar.gz?download
- Installed Faces from 
http://prdownloads.sourceforge.net/faces-project/faces-pm-
0.8.2.tar.gz?download
- Renamed bin/faces to faces.py and opened it with PythonLauncher.app

BTW: The wxpython and matplotlib demos work fine.

What did I wrong?

TIA for any help,

Sincerely,

Wolfgang Keller

0
Wolfgang
5/17/2006 7:45:08 PM
comp.soft-sys.wxwindows 21076 articles. 0 followers. Post Follow

3 Replies
2115 Views

Similar Articles

[PageSpeed] 39

Wolfgang Keller wrote:
> [[ This message was both posted and mailed: see
>    the 'To' and 'Newsgroups' headers for details. ]]
> 
> Hello,
> 
> I'm trying to run Faces (a project management application implemented in 
> Python using wxPython for the GUI, see http://faces.homeip.net/) on my Mac 
> (G5 with Mac OS X 10.4.6), but so far it won't work.
> 
> Here's the traceback I get:
> 
> "/Library/Frameworks/Python.framework/Versions/2.4/bin/python" -O  
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/faces/bin/faces.py"  && echo Exit status: $? && exit 1
> Traceback (most recent call last):
>   File 
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/faces/bin/faces.py", line 5, in ?
>     sys.exit(main())
>   File 
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/faces/gui/plangui.py", line 1181, in main
>     app = FacesApp(False)
>   File 
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/metapie/gui/controller.py", line 1136, in __init__
>     wx.App.__init__(self, *args, **kwargs)
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/_core.py", line 7700, in __init__
>     self._BootstrapApp()
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/_core.py", line 7352, in _BootstrapApp
>     return _core_.PyApp__BootstrapApp(*args, **kwargs)
>   File 
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/faces/gui/plangui.py", line 1089, in OnInit
>     self.show_splash(True)
>   File 
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/faces/gui/plangui.py", line 1098, in show_splash
>     text = RenderToBitmap(splash_text)
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 353, in RenderToBitmap
>     width, height, dy = GetFullExtent(str, dc, enclose)
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 346, in GetFullExtent
>     RenderToRenderer(str, renderer, enclose)
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 329, in 
> RenderToRenderer
>     p.Parse(str, 1)
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/lib/fancytext.py", line 137, in characterData
>     self.y = self.mayY = self.maxY + self.dc.GetTextExtent("M")[1]
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/_gdi.py", line 3435, in GetTextExtent
>     return _gdi_.DC_GetTextExtent(*args, **kwargs)
> wx._core.PyAssertionError: C++ assertion "wxAssertFailure" failed in 
> /Users/kevino/oss/wx26/wxWidgets/src/mac/carbon/dc.cpp(1482): Invalid DC

The Faces code uses the fancytext module in a way that exposes a bug. 
I'll make a fix for fancytext, but in the meantime you can probably just 
comment out the call to show_splash in the Faces code and it will 
probably work fine.  It just won't show the splash screen at startup.

-- 
Robin Dunn
Software Craftsman
http://wxPython.org  Java give you jitters?  Relax with wxPython!


---------------------------------------------------------------------
To unsubscribe, e-mail: wx-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wx-users-help@lists.wxwidgets.org

0
robin
5/18/2006 11:38:16 PM
Hello.

and thanks for your reply.

> The Faces code uses the fancytext module in a way that exposes a bug. 
> I'll make a fix for fancytext, but in the meantime you can probably just 
> comment out the call to show_splash in the Faces code 

Done.

> and it will probably work fine.

Not yet. :-(

Here comes the next traceback:

Traceback (most recent call last):
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/gui/plangui.py", line 1246, in ?
    sys.exit(main())
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/gui/plangui.py", line 1217, in main
    app.add_model(app.session)
  File 
"/Library/Frameworks/Python.framework/Versions/Current/lib/python2.4/site-
packages/metapie/gui/controller.py", line 814, in add_model
    new_model.register()
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/faces/gui/plangui.py", line 890, in register
    session.Session.register(self)
  File 
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/metapie/gui/session.py", line 193, in register
    controller().register_view(\
  File 
"/Library/Frameworks/Python.framework/Versions/Current/lib/python2.4/site-
packages/metapie/gui/controller.py", line 961, in register_view
    active=False)
  File 
"/Library/Frameworks/Python.framework/Versions/Current/lib/python2.4/site-
packages/metapie/gui/menupanel.py", line 292, in insert_content
    content.insert(title, id, bitmap, pos)
  File 
"/Library/Frameworks/Python.framework/Versions/Current/lib/python2.4/site-
packages/metapie/gui/menupanel.py", line 187, in insert
    sizer.Insert(pos, button, 0, flag=wx.EXPAND)
  File 
"//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/wx-2.6-mac-unicode/wx/_core.py", line 11721, in Insert
    return _core_.Sizer_Insert(*args, **kwargs)
wx._core.PyAssertionError: C++ assertion "wxAssertFailure" failed in 
/Users/kevino/oss/wx26/wxWidgets/src/common/list.cpp(326): invalid index in 
wxListBase::Item

Sincerely,

Wolfgang Keller

0
Wolfgang
5/19/2006 6:21:45 PM
Wolfgang Keller wrote:
> Hello.
> 
> and thanks for your reply.
> 
>> The Faces code uses the fancytext module in a way that exposes a bug. 
>> I'll make a fix for fancytext, but in the meantime you can probably just 
>> comment out the call to show_splash in the Faces code 
> 
> Done.
> 
>> and it will probably work fine.
> 
> Not yet. :-(
> 
> Here comes the next traceback:

> "/Library/Frameworks/Python.framework/Versions/Current/lib/python2.4/site-
> packages/metapie/gui/menupanel.py", line 187, in insert
>     sizer.Insert(pos, button, 0, flag=wx.EXPAND)
>   File 
> "//Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/wx-2.6-mac-unicode/wx/_core.py", line 11721, in Insert
>     return _core_.Sizer_Insert(*args, **kwargs)
> wx._core.PyAssertionError: C++ assertion "wxAssertFailure" failed in 
> /Users/kevino/oss/wx26/wxWidgets/src/common/list.cpp(326): invalid index in 
> wxListBase::Item

Looks like they are trying to insert an item into a sizer at a position 
that is larger than the number of items already in the sizer.  Please 
take this up with the Faces developers as it's their bug.

-- 
Robin Dunn
Software Craftsman
http://wxPython.org  Java give you jitters?  Relax with wxPython!


---------------------------------------------------------------------
To unsubscribe, e-mail: wx-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wx-users-help@lists.wxwidgets.org

0
robin
5/19/2006 7:27:23 PM
Reply: