getopts confusion

Steve Holden sholden at holdenweb.com
Fri Jun 29 17:17:05 EDT 2001


Not familiar with the gnome.ui module, but you could import it in an
interactive session then see whether it has anything which conflist with
your code (using dir()). The from ... import * usage is dangerous,
especially when the module concerned has not been carefully designed not to
pollute its host namespace. I don't know whether that's the case for
gnome.ui.

regards
 StEVe
--
http://www.holdenweb.com/


"Rob Brown-Bayliss" <rob at ZOOstation.cc> wrote in message
news:mailman.993845146.8762.python-list at python.org...
> On 29 Jun 2001 08:13:50 -0400, Steve Holden wrote:
> > > Error on option -s: unknown option.
> > > Run './gearbox.py --help' to see a full list of available command line
> > > options.
>
> I have checked indentation, it's fine.
>
>
> > I conclude that the getopt code is working correctly, but your
application
> > is somehow failing to test for the options.
> >
> > Hope this helps.
>
> Yes, some.  I played around some more, and the app that fails has a GUI,
> the other is a command line app.  There is a single import I do (from
> gnome.ui import *) that stuffs it up, if the getopt stuff comes before
> this import I don't get that error, if I cut and paste the getops till
> after this import I get the above error.
>
> Does any one know why?
>
> --
>
>   Rob Brown-Bayliss
>  ---======o======---
>   www.ZOOstation.cc
>





More information about the Python-list mailing list