Bizarre error from help()
Peter Hansen
peter at engcorp.com
Wed Aug 10 07:32:37 EDT 2005
Ben Finney wrote:
> Roy Smith <roy at panix.com> wrote:
>
>>I've got a directory where I keep all sorts of little snippets of
>>python code for testing. When I start up python in that directory,
>>I get the error I reported. It turns out, I've got a file called
>>"string.py" in it [...]
>>
>>something in the help system must be doing an "import string".
>
> All hail the coming of PEP 328:
>
> <URL:http://www.python.org/peps/pep-0328.html>
Which, unless I misunderstand, would do nothing to change the behaviour
of the OP's situation unless the mistakingly named "string.py" module
was actually inside a package. If it was just in the current directory
at the time, I don't think the PEP328 would have affected the situation.
-Peter
More information about the Python-list
mailing list