[Tutor] python logging module: two handlers writing to the same file - okay?

2007-12-14 Thread Hans Fangohr
Dear all, I am trying to set up a logging system with the following specs: - all messages should be printed to stdout and to a file (here called log.log). - we have two types of loggers that the code uses: 'normal' and 'short'. - The 'short' logger just prints less detail (it basically needs

Re: [Tutor] Python Versions

2007-12-14 Thread Tiger12506
> Despite what your english teacher might have tried to make you > believe, they were wrong about the lack of a neutral in english. Just > like ending sentences with prepositions has always been done and > always will be done, the use of "they" to refer to someone of > indeterminate gender has bee

Re: [Tutor] ipython / readline problem

2007-12-14 Thread Thorsten Kampe
* Tiago Saboga (Thu, 13 Dec 2007 17:05:55 -0200) > On Thu, Dec 13, 2007 at 07:41:08AM -0500, Kent Johnson wrote: > > Tiago Saboga wrote: > >> : 'ascii' codec can't encode > >> character u'\xe7' in position 2: ordinal not in range(128) > >> > >> === > >> > >> What

[Tutor] How to get python to differentiate between CR, LF, and CRLF in a string (not a file)?

2007-12-14 Thread R. Alan Monroe
Is is possible to get python to differentiate between CR, LF, and CRLF in a string (not a file)? This is a triple quoted string I've pasted into the source (putting r to indicate raw string made no difference). It contains a mixture of CR, LF and CRLF (I can see this by enabling visible End of Line

Re: [Tutor] upper and lower case input for file name

2007-12-14 Thread Kent Johnson
Bryan Fodness wrote: > > Is there an easy way that an input can be upper or lower case? > > The file name is TEST.TXT, and I get. > > - > > Enter File (if not local, enter path):test.txt > > Traceback (most recent call

[Tutor] upper and lower case input for file name

2007-12-14 Thread Bryan Fodness
Is there an easy way that an input can be upper or lower case? The file name is TEST.TXT, and I get. - Enter File (if not local, enter path):test.txt Traceback (most recent call last): File "test.py", line 52, in

Re: [Tutor] using quotes in IDLE

2007-12-14 Thread Ole Henning Jensen
- Original Message - From: "Jim Morcombe" <[EMAIL PROTECTED]> To: Sent: Friday, December 14, 2007 2:43 AM Subject: [Tutor] using quotes in IDLE A really dumb question... When typing things into IDLE, how are quotes meant to work? If I type" employee.name = "Susan" then IDLE ignores

Re: [Tutor] Python Editor For Mac Os X

2007-12-14 Thread Kent Johnson
chinni wrote: > Hi which editor for python on Mac os x platform is best with color > syntax compiler etc... You will get as many answers for 'best' as there are editors :-) it really depends on your preferences. I like TextMate myself. Kent ___ Tutor

Re: [Tutor] Python Versions

2007-12-14 Thread Tiger12506
My apologies for mistaking your gender. Because English does not have adequate neutral gender indication, I tend to use the male as such, as they do in Spanish, and perhaps many other languages. At any rate, that's how it's written in the Bible. I presumed that it was an issue with raw input be

Re: [Tutor] Python Editor For Mac Os X

2007-12-14 Thread Jeff Younker
On Dec 13, 2007, at 8:32 PM, chinni wrote: > Hi which editor for python on Mac os x platform is best with color > syntax compiler etc... I'm pretty happy with Eclipse + Pydev. - Jeff Younker - [EMAIL PROTECTED] - ___ Tutor maillist - Tutor@python.

Re: [Tutor] Python Versions

2007-12-14 Thread Alan Gauld
"Gman" <[EMAIL PROTECTED]> wrote in message # Filename: func_param.py def printMax(a, b): > >>>if a > b: > print a, 'is maximum' > else: > print b, 'is maximum' > printMax(3, 4) > SyntaxError: invalid syntax OK, I think this is because you have tried to use the

Re: [Tutor] using quotes in IDLE

2007-12-14 Thread Alan Gauld
"Jim Morcombe" <[EMAIL PROTECTED]> wrote > When typing things into IDLE, how are quotes meant to work? > > If I type" > >employee.name = "Susan" > > then IDLE ignores the last " and I get an error. Quotes should work the same in Idle as anywhere else! I suspect what you are doing is trying to cr

Re: [Tutor] Python Editor For Mac Os X

2007-12-14 Thread Evert Rol
> On Dec 14, 2007 10:02 AM, chinni <[EMAIL PROTECTED]> wrote: >> Hi which editor for python on Mac os x platform is best with color >> syntax >> compiler etc... > > You can try emacs, vim, textmate, eclipse(?) I like Aquamacs Emacs myself, but since Emacs has a steep learning curve, that may b