newbie questions about sys.path, wxpython, IDLE and pythonwin

Mark Hammond MHammond at skippinet.com.au
Tue Jul 13 19:11:27 EDT 1999


MB wrote in message <378B7A69.12874AAC at gnet.tn>...
>I need to know exactly how the sys.path is built. In my system I have no
>pythonpath variable but the sys.path returns a list. I suppose it was
>built by default. This list doesn't contain all my python
>subdirectories. So I want to know when and how this list was built ?
>(yes I examined the registry and found references to python directories
>but they don't match my sys.path)

Python uses a combination of the values you found in the registry, and some
default values - things like ".\lib" are added always, regardless of the
registry.  Remember, you have the same source to see how it works that I do.

>Another question in relation with the first. I downloaded wxPython an
>tried to run the demo.py from the pythonwin GUI (opening
>c:\wxpython\demo\demo.py and running it). It runs perfectly.

>From what I hear, you dont want to try running it a second time or it
crashes Pythonwin :-)

>Other thing. I examined demo.py through the debugger under pythonwin I
>found this statement:
>'import miscc'
>The interpreter import this module but is not able to locate it. When I
>type >>> miscc it says that is a built-in module. Are there modules that
>are not python files ? What is a built-in module ? I didn't find its
>definition in the docs.

I have no idea - may be wxPython thing.  Certainly not built-in to Python
1.5.2.

>Last question. About the  syntaxic ':' at the end of a line when it
>begins with def, class,if ,when,etc... Is it absolutely necessary for
>the language ?
Yes.

Mark.







More information about the Python-list mailing list