On Friday 22 January 2010 06:38:51 am Paul McNett wrote:
> dabo Commit
> Revision 5599
> Date: 2010-01-22 06:38:49 -0800 (Fri, 22 Jan 2010)
> Author: Paul
> Trac: http://trac.dabodev.com/changeset/5599
>
> Changed:
> U   trunk/dabo/ui/uiwx/__init__.py
>
> Log:
> Added some code to ensure a minimal wx version. Yarko on the Pycon-Org list
> had trouble installing Dabo because his system only had wxpython 2.6, and
> Dabo bailed on ImportErrors of wx.lib.AUI. Then he installed 2.8.10, but
> his system was still selecting wxpython 2.6 instead of 2.8, resulting in
> unnecessary spinning of wheels.
>
> This should keep this from happening to future new users.
>
>
>
> Diff:
> Modified: trunk/dabo/ui/uiwx/__init__.py
> ===================================================================
> --- trunk/dabo/ui/uiwx/__init__.py    2010-01-14 19:43:23 UTC (rev 5598)
> +++ trunk/dabo/ui/uiwx/__init__.py    2010-01-22 14:38:49 UTC (rev 5599)
> @@ -10,6 +10,14 @@
>  import warnings
>  from dabo.dLocalize import _
>
> +# Very VERY first thing: ensure a minimal wx is selected:
> +minWx = "2.8"
> +try:
> +     import wxversion
> +except ImportError:
> +     sys.exit("wxPython needs to be at least version %s." % minWx)
> +wxversion.ensureMinimal(minWx)
> +
>  ######################################################
>  # Very first thing: check for proper wxPython build:
>  _failedLibs = []

This change is causing issues with my imports for my custom routines.    Also 
even after I get pass the order issue I get trouble.
 
Traceback (most recent call last):
  File "esStudent.py", line 18, in <module>
    from RAClasses import SchGridBizobj, HeaderToolBar, AppMenu, PesAbout, 
Getlatitudelongitude
  File "/home/johnf/pyProject/pespy/RAClasses.py", line 18, in <module>
    import dabo.ui.uiwx.dControlItemMixin as dcm
  File "/home/johnf/dabo/dabo/ui/uiwx/__init__.py", line 19, in <module>
    wxversion.ensureMinimal(minWx)
  File "/usr/lib/python2.5/site-packages/wxversion.py", line 181, in 
ensureMinimal
    raise AlreadyImportedError("wxversion.ensureMinimal() must be called 
before wxPython is imported")
wxversion.AlreadyImportedError: wxversion.ensureMinimal() must be called 
before wxPython is imported

"import dabo.ui.uiwx.dControlItemMixin as dcm"  is causing me the import issue

If I comment out the new code I get pass the problem of the import but then I 
get.

Traceback (most recent call last):
  File "esStudent.py", line 4237, in <module>
    app.start()
  File "/home/johnf/dabo/dabo/dApp.py", line 379, in start
    self.setup()
  File "/home/johnf/dabo/dabo/dApp.py", line 333, in setup
    self.uiApp = dabo.ui.getUiApp(self, self.UIAppClass, callback=None, 
forceNew=True)
AttributeError: 'module' object has no attribute 'getUiApp'

openSUSE 11.0, Python 2.5.x, wxPython 2.8.10.1, latest SVN of Dabo.

Johnf






_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: 
http://leafe.com/archives/byMID/[email protected]

Reply via email to