Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Python
Unable to strip \n characters
 

Index | Next | Previous | View Flat


zubeido at yahoo

May 20, 2007, 3:50 AM


Views: 63
Permalink
Unable to strip \n characters

Hi
Im writing a personal wrapper to the perl script offered by
rapidshare, so that im able to use multiple files and glob pathnames,
but im using a file so i can track and resume any uploading data. The
problem is the lines come with a \n character that im not bein able to
take out,

files = f.readlines()
for upload in files:
upload.strip("\n")
final_args = "./rsapiresume.pl %s prem user password"
% (upload)
print upload
#os.system( final_args )

My upload string still comes with the \n making the system call look
like this:

./rsapiresume.pl filename_to_upload
prem user password

I've already tried replace but it doesn't work either

--
http://mail.python.org/mailman/listinfo/python-list

Subject User Time
Unable to strip \n characters zubeido at yahoo May 20, 2007, 3:50 AM
    Re: Unable to strip \n characters __peter__ at web May 20, 2007, 4:19 AM
    Re: Unable to strip \n characters michael at jedimindworks May 20, 2007, 5:41 AM
    Re: Unable to strip \n characters michael at jedimindworks May 20, 2007, 5:49 AM
    Re: Unable to strip \n characters afriere at yahoo May 20, 2007, 11:05 PM
    Re: Unable to strip \n characters zubeido at yahoo May 21, 2007, 1:37 PM
    Re: Unable to strip \n characters afriere at yahoo May 23, 2007, 12:23 AM

  Index | Next | Previous | View Flat
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.