Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-12-10 Thread Ralf Schmitt
On Wed, Dec 10, 2008 at 6:49 PM, James Y Knight <[EMAIL PROTECTED]> wrote: > > On Dec 10, 2008, at 5:55 AM, Lennart Regebro wrote: > >> Turns out, I created an empty time.py in /tmp, just to see the error >> message. By buildout will when creating eggs from checked out modules, >> copy them to a di

Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-12-10 Thread Lennart Regebro
On Wed, Dec 10, 2008 at 18:49, James Y Knight <[EMAIL PROTECTED]> wrote: > > On Dec 10, 2008, at 5:55 AM, Lennart Regebro wrote: > >> Turns out, I created an empty time.py in /tmp, just to see the error >> message. By buildout will when creating eggs from checked out modules, >> copy them to a dire

Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-12-10 Thread James Y Knight
On Dec 10, 2008, at 5:55 AM, Lennart Regebro wrote: Turns out, I created an empty time.py in /tmp, just to see the error message. By buildout will when creating eggs from checked out modules, copy them to a directory under /tmp, and evidently run python from /tmp to create the eggs. So that pro

Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-12-10 Thread Lennart Regebro
A funny thing just happened to me. I tried out causing this error, just to see how the error message was somehow different, by creating a time.py in /tmp, and running python from there. Then I removed the time.py, and went on working. Two days later, my usage of zc.buildout are broken with a "modu

Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-11-16 Thread Guilherme Polo
On Sun, Nov 16, 2008 at 11:55 AM, Tal Einat <[EMAIL PROTECTED]> wrote: > Steve Holden wrote: >> Tal Einat wrote: >>> It this desired behavior? >>> >>> At the very least the exception should be more detailed, perhaps to >>> the point of suggesting the probable cause of the error (i.e. >>> overriding

Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-11-16 Thread Tal Einat
Steve Holden wrote: > Tal Einat wrote: >> It this desired behavior? >> >> At the very least the exception should be more detailed, perhaps to >> the point of suggesting the probable cause of the error (i.e. >> overriding the time module). >> > How is this different from any other case where you imp

Re: [Python-Dev] datetime.date.today() raises "AttributeError: time"

2008-11-16 Thread Steve Holden
Tal Einat wrote: > For an unknown reason, datetime.date.today() began throwing a cryptic > "AttributeError: time" exception. It took me a while to figure out > that this was caused by an accidental overriding of the built-in > 'time' module. > > Here's an example interactive session which shows th