Re: os.system and quoted strings

2007-02-27 Thread Sriram
manner: cmd = "gvim %s%s.txt" %(dir, fileName) and simply call os.system with cmd. os.system(cmd) Here is a little more detail on string format specifiers http://docs.python.org/lib/typesseq-strings.html HTH Sriram On Feb 27, 7:24 am, "svata" <[EMAIL PROTECTED]> wrote: &

Re: book for a starter

2007-02-27 Thread Sriram
Hi, If you have experience programming, just read the online tutorial at http://docs.python.org/tut/tut.html I find Python Essential Reference (3rd Edition) (Developer's Library) (Paperback) invaluable though. BTW I have the 2nd edition. Amazon link : http://www.amazon.com/gp/pdp/profile/A9N9B1L0

urllib2 on Windows Vista

2006-07-08 Thread Sriram Krishnan
pen '_open', req) File "D:\python24\lib\urllib2.py", line 337, in _call_chain result = func(*args) File "D:\python24\lib\urllib2.py", line 1021, in http_open return self.do_open(httplib.HTTPConnection, req) File "D:\python24\lib\urllib2.py"

Re: urllib2 on Windows Vista

2006-07-09 Thread Sriram Krishnan
Rune Strand wrote: > My wil guess is that it is a firewall problem. Perhaps you'll have to > specify that python.exe is trusted. Tried that - it didn't work. I also tried turning off the User Account Control and ran as full administrator - that didn't work too. -- http://mail.python.org/mailman

Re: editor for Python on Linux

2006-02-19 Thread Sriram Krishnan
Mladen Adamovic wrote: > Hi! > > I wonder which editor or IDE you can recommend me for writing Python > programs. I tried with jEdit but it isn't perfect. > Check out http://wiki.python.org/moin/PythonEditors. I personally use Emacs -- Sriram -- http://mail.python.

Module re, extract on string match

2008-08-04 Thread Sriram Rajan
I am wondering if I can use re.search to extract from a particular location in a string. Example: string1='/Users/sriram/folder1/folder2/folder3/folder4/folder5/file' re.search ('folder3,string1) Thanks, Sriram -- http://mail.python.org/mailman/listinfo/python-list

Pexpect echoes twice for each read

2008-09-09 Thread Sriram Rajan
rrupt!\n") sys.exit(2) ssh_handle.close() Output: --- $ python pexpect_test.py replace_line_break.sh /tmp/ 10.5.254.18 Last login: Tue Sep 9 15:45:05 2008 from sriram-macbook.dhcp.2wire.com $ scp replace_line_break.sh [EMAIL PROTECTED]:/tmp/ scp replace_line_break.sh [EMAIL PROTECTED]:/tmp/

standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
I guess why every programming language has some kind of a 'standard library' built in within it. In my view it must not be called as a 'library' at all. what it does is like a 'bunch of built-in programs ready-made to do stuff'. Lets see what a 'library' does: 1. offers books for customers 1.1 l

Re: standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
On Nov 12, 3:56 pm, "Diez B. Roggisch" wrote: > Sriram Srinivasan schrieb: > > > > > I guess why every programming language has some kind of a 'standard > > library' built in within it. > > In my view it must not be called as a 'library

Re: standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
On Nov 12, 3:56 pm, "Diez B. Roggisch" wrote: > Sriram Srinivasan schrieb: > > > > > I guess why every programming language has some kind of a 'standard > > library' built in within it. > > In my view it must not be called as a 'library

Re: standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
On Nov 12, 4:35 pm, "Diez B. Roggisch" wrote: > Sriram Srinivasan schrieb: > > > > > On Nov 12, 3:56 pm, "Diez B. Roggisch" wrote: > >> Sriram Srinivasan schrieb: > > >>> I guess why every programming language has some kind of a &#

Re: standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
On Nov 12, 6:07 pm, "Diez B. Roggisch" wrote: > > ok let me make it more clear.. > > forget how you use python now.. i am talking about __futuristic__ > > python programming. > > > there is no more python2.x or python3.x or python y.x releases. there > > is only updates of python and standard libr

Re: standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
> You are describing a lending library, which is not the only sort of > library. My personal library doesn't do any of those things. It is just a > room with shelves filled with books. how i see is all libraries are libraries, for a personal library you are the only customer and you are the manag

Re: standard libraries don't behave like standard 'libraries'

2009-11-12 Thread Sriram Srinivasan
> So all libraries written have to use the common subset, which - unless > things are *removed*, which with python3 actually happened - is always > the oldest interpreter. And if a feature goes away, they have to be > rewritten with the then common subset. you see that's the problem with py3. inst