sending ftp file list to mail???

2011-10-06 Thread selahattin ay
hi all. I want to get my ftp list and send the list to my mail adress... my codes are from ftplib import FTP import smtplib from email.MIMEMultipart import MIMEMultipart from email.MIMEText import MIMETextbaglanti = FTP("ftp.guncelyorum.org") baglanti.login("**", "***") print baglanti.dir

Re: PyDev 2.2.3 Released

2011-10-06 Thread rusi
On Oct 6, 11:03 pm, Fabio Zadrozny wrote: > Hi All, > > PyDev 2.2.3 has been released > > Details on PyDev:http://pydev.org > Details on its development:http://pydev.blogspot.com On my debian box I get: $ /opt/Aptana\ Studio\ 3/AptanaStudio3 HandleConsoleMessage(Uncaught TypeError: Object [objec

database connection

2011-10-06 Thread masood shaik
Hi can u please tell me how we can connect to database without changing the permission of db file using sqlite3 -- http://mail.python.org/mailman/listinfo/python-list

Re: Deleting files on a shared server

2011-10-06 Thread Josh English
The problem shows up when the application starts. It tries to read the file but the lock mechanism times out because the file is still around after the last time the application ran. It's a wxPython program. The code to unlink the .lock files is run in the wxApp.OnInit method (before any code t

Re: Is it possible to create C-style "main" function in Python? (for teaching purposes)

2011-10-06 Thread alex23
Dennis Lee Bieber wrote: >         While I wouldn't want to write an FFT in COBOL, one can't deny that > laying out fixed width reports and moving blocks of decimal data between > record layouts is quite easy in COBOL. Well, sure, but there's still plenty of pain in the verbosity :) -- http://ma

Re: L.A. user group?

2011-10-06 Thread Miki Tebeka
Thanks! -- http://mail.python.org/mailman/listinfo/python-list

Re: Deleting files on a shared server

2011-10-06 Thread Steven D'Aprano
Josh English wrote: > This is a follow-up to some questions I posted a month or two ago. I have > two programs running on various Windows XP boxes, sharing several resource > files on a Windows 2003 server. It's a mapped drive on the workstations to > a shared folder. > > I am using a locking uti

Re: A tuple in order to pass returned values ?

2011-10-06 Thread Steven D'Aprano
Jean-Michel Pichavant wrote: > In a general manner, ppl will tend to use the minimum arguments > required. However, do not pack values into tuple if they are not related. How would you return multiple values if not in a tuple? Tuples are *the* mechanism for returning multiple values in Python. I

Deleting files on a shared server

2011-10-06 Thread Josh English
This is a follow-up to some questions I posted a month or two ago. I have two programs running on various Windows XP boxes, sharing several resource files on a Windows 2003 server. It's a mapped drive on the workstations to a shared folder. I am using a locking utility that works by creating ".

Re: passing multiple string to a command line option

2011-10-06 Thread Mahmood Naderan
>Without seeing the code of SimObject and params I can't tell much more. >    File "/home/mahmood/gem5/src/python/m5/params.py", line 159, in convert >      return self.ptype(value) following is part of params.py and I marked line 159. I didn't wrote this code so changing this may cause problem w

Re: encoding problem with BeautifulSoup - problem when writing parsed text to file

2011-10-06 Thread John Gordon
In xDog Walker writes: > What is this io of which you speak? It was introduced in Python 2.6. -- John Gordon A is for Amy, who fell down the stairs gor...@panix.com B is for Basil, assaulted by bears -- Edward Gorey, "The Gashl

Re: encoding problem with BeautifulSoup - problem when writing parsed text to file

2011-10-06 Thread xDog Walker
On Thursday 2011 October 06 10:41, jmfauth wrote: > or  (Python2/Python3) > > >>> import io > >>> with io.open('abc.txt', 'r', encoding='iso-8859-2') as f: > > ...     r = f.read() > ... > > >>> repr(r) > > u'a\nb\nc\n' > > >>> with io.open('def.txt', 'w', encoding='utf-8-sig') as f: > > ...     t

Re: passing multiple string to a command line option

2011-10-06 Thread Miki Tebeka
As far as I see, the problem is not in the command line but in system.cpu[i].workload = process[i] call tree. Without seeing the code of SimObject and params I can't tell much more. -- http://mail.python.org/mailman/listinfo/python-list

Re: L.A. user group?

2011-10-06 Thread Brian Curtin
On Thu, Oct 6, 2011 at 12:24, Miki Tebeka wrote: > Greetings, > > Is there an L.A. Python user group out there? http://socal-piggies.org might work for you. They recently had a meeting in Santa Monica, and I believe many of the members are LA based. -- http://mail.python.org/mailman/listinfo/pyt

PyDev 2.2.3 Released

2011-10-06 Thread Fabio Zadrozny
Hi All, PyDev 2.2.3 has been released Details on PyDev: http://pydev.org Details on its development: http://pydev.blogspot.com Release Highlights: --- * Performance improvements * Major: Fixed critical issue when dealing with zip files. * Added option to create met

Re: encoding problem with BeautifulSoup - problem when writing parsed text to file

2011-10-06 Thread jmfauth
On 6 oct, 06:39, Greg wrote: > Brilliant! It worked. Thanks! > > Here is the final code for those who are struggling with similar > problems: > > ## open and decode file > # In this case, the encoding comes from the charset argument in a meta > tag > # e.g. > fileObj = open(filePath,"r").read() >

L.A. user group?

2011-10-06 Thread Miki Tebeka
Greetings, Is there an L.A. Python user group out there? Thanks, -- Miki -- http://mail.python.org/mailman/listinfo/python-list

Re: passing multiple string to a command line option

2011-10-06 Thread Terry Reedy
On 10/6/2011 11:27 AM, Mahmood Naderan wrote: Dear developers, Suppose I have this list in command line options: ... -b b1,b2,b3 Here is what I wrote: parser = optparse.OptionParser() If you are starting a new project, consider using argparse, which has superceded optparse. # Benchmark opt

Re: Dabo 0.9.4 Released!

2011-10-06 Thread Neal Becker
Ed Leafe wrote: > Yes, it's been over a year, but today we're finally releasing Dabo 0.9.4! > > What can I say? While we've been actively developing Dabo all along, and > committing improvements and fixes regularly, we don't seem to get around to > doing releases as often as we should. Since Dabo

Re: Implementing Python-OAuth2

2011-10-06 Thread Jeff Gaynor
On 10/06/2011 08:34 AM, Kayode Odeyemi wrote: Hello friends, I'm working on a pretty large application that I will like to use oauth2 on as an authentication and authorization mechanism. I understand fairly the technology and I have written my own implementation before I stumbled on python-o

ANN: hgview 1.4.0 - Mercurial log navigator

2011-10-06 Thread Alain Leufroy
Announcing HgView 1.4.0 === HgView home page: http://www.logilab.org/project/hgview Tarball: http://ftp.logilab.org/pub/hgview/hgview-1.4.0.tar.gz Hg repository: http://www.logilab.org/src/hgview About this release == Text mode inside make it int

passing multiple string to a command line option

2011-10-06 Thread Mahmood Naderan
Dear developers, Suppose I have this list in command line options: ... -b b1,b2,b3 Here is what I wrote: parser = optparse.OptionParser() # Benchmark options parser.add_option("-b", "--benchmark", default="", help="The benchmark to be loaded.") process = [] benchmarks = options.benchmark.split(',

Re: A tuple in order to pass returned values ?

2011-10-06 Thread Jean-Michel Pichavant
faucheuse wrote: Hi, (new to python and first message here \o/) I was wondering something : when you do : return value1, value2, value3 It returns a tuple. So if I want to pass these value to a function, the function have to look like : def function(self,(value1, value2, value3)) #self because

Dabo 0.9.4 Released!

2011-10-06 Thread Ed Leafe
Yes, it's been over a year, but today we're finally releasing Dabo 0.9.4! What can I say? While we've been actively developing Dabo all along, and committing improvements and fixes regularly, we don't seem to get around to doing releases as often as we should. Since Dabo has a W

Implementing Python-OAuth2

2011-10-06 Thread Kayode Odeyemi
Hello friends, I'm working on a pretty large application that I will like to use oauth2 on as an authentication and authorization mechanism. I understand fairly the technology and I have written my own implementation before I stumbled on python-oauth2. I need advise on leveraging python-oauth2 a

Re: Writing file out to another machine

2011-10-06 Thread Dave Angel
On 01/-10/-28163 02:59 PM, Dennis Lee Bieber wrote: On Wed, 05 Oct 2011 21:36:34 -0400, Terry Reedy declaimed the following in gmane.comp.python.general: On 10/5/2011 5:31 PM, Chris Angelico wrote: On Thu, Oct 6, 2011 at 8:22 AM, John Gordon wrote: I assume he intended "S:" to indicate a re

The hyper fused upper part of Nike Air Max displays the humanity

2011-10-06 Thread fashion fans
The hyper fused upper part of Nike Air Max displays the humanity of the designer because of its lightweight, breathability and a feeling of plusher fitness. The mesh inner collar, and the soft springy cushion http://www.outlet-nike-air-max.com/inside can protect the feet against most possible inj

Re: encoding problem with BeautifulSoup - problem when writing parsed text to file

2011-10-06 Thread Chris Angelico
On Thu, Oct 6, 2011 at 8:29 PM, Ulrich Eckhardt wrote: > Just wondering, why do you split the latter two parts? I would have used > codecs.open() to open the file and define the encoding in a single step. Is > there a downside to this approach? > Those two steps still happen, even if you achieve

Re: encoding problem with BeautifulSoup - problem when writing parsed text to file

2011-10-06 Thread Ulrich Eckhardt
Am 06.10.2011 05:40, schrieb Steven D'Aprano: (4) Do all your processing in Unicode, not bytes. (5) Encode the text into bytes using UTF-8 encoding. (6) Write the bytes to a file. Just wondering, why do you split the latter two parts? I would have used codecs.open() to open the file and defi

Re: httplib2 download forbidden

2011-10-06 Thread Mauro Zaccariotto
On 6 Ott, 09:05, Tim Roberts wrote: > Mauro Zaccariotto wrote: > > >Hi! does anyone know what's happening herehttp://code.google.com/p/httplib2/ > >? I get this: > >"403. That s an error. > >Your client does not have permission to get URL /p/httplib2/ from this > >server. That s all we know." > >

Re: Simplest way to resize an image-like array

2011-10-06 Thread John Ladasky
On Oct 1, 2:22 am, John Ladasky wrote: > On Sep 30, 1:51 pm, Jon Clements wrote: > > > Is something like > >http://docs.scipy.org/doc/scipy/reference/generated/scipy.misc.imresi... > > any use? > > There we go!  That's the kind of method I was seeking.  I didn't think > to look outside of scipy.i

Re: httplib2 download forbidden

2011-10-06 Thread Tim Roberts
Mauro Zaccariotto wrote: > >Hi! does anyone know what's happening here http://code.google.com/p/httplib2/ >? I get this: >"403. That’s an error. >Your client does not have permission to get URL /p/httplib2/ from this >server. That’s all we know." It's working for me. Do you have some kind of pro

Re: urllib and parsing

2011-10-06 Thread Tim Roberts
luca72 wrote: > >Hello i have a simple question: >up to now if i have to parse a page i do as follow: >... >Now i have the site that is open by an html file like this: >... >how can i open it with urllib, please note i don't have to parse this >file, but i have to parse the site where he point. W