RE: Total Beginner - Extracting Data from a Database Online (Screenshot)

2013-05-27 Thread Phil Connell
On 28 May 2013 02:21, "Carlos Nepomuceno" wrote: > > > > Date: Mon, 27 May 2013 17:58:00 -0700 > > Subject: Re: Total Beginner - Extracting Data from a Database Online (Screenshot) > > From: logan.c.gra...@gmail.com > > To: python-list@python.org > [...] >

Re: TypeError: unsupported operand type(s) for %: 'NoneType' and 'tuple'

2013-05-27 Thread Νίκος Γκρ33κ
Τη Κυριακή, 26 Μαΐου 2013 7:45:42 μ.μ. UTC+3, ο χρήστης Mark Lawrence έγραψε: > What has this got to do with Python? What do your questions have to do with a proper reply? -- http://mail.python.org/mailman/listinfo/python-list

Re: I want to know how to implement concurrent threads in Python

2013-05-27 Thread Fábio Santos
On 28 May 2013 05:06, "Daniel Gagliardi" wrote: > > fuck! fuck! i'm gonna be fired if i didnt get this shit! i told my boss id do it. fuck! im gonna pipe some crakc. fuck... So do it. You've already been told how to. It's true that python does not do real concurrent execution, but if most of you

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Νίκος Γκρ33κ
Τη Τρίτη, 28 Μαΐου 2013 1:18:06 π.μ. UTC+3, ο χρήστης Chris Angelico έγραψε: > You're effectively asking people to put in a few minutes' work, > sometimes quite a few minutes, to help you. Is it too much to hope > that you'll spend one more minute on your posts? No it is not, you are right, i sh

Re: How to: Setuptools

2013-05-27 Thread rusi
On May 28, 9:09 am, Carlos Nepomuceno wrote: > > > > Date: Mon, 27 May 2013 20:54:53 -0700 > > Subject: Re: How to: Setuptools > > From: rustompm...@gmail.com > [...] > > > Oooff! Talk of using sledgehammers to crack nuts... > > > All that is needed is to v

Re: Python error codes and messages location

2013-05-27 Thread Vito De Tullio
Fábio Santos wrote: >> > > Speaking of PEPs and exceptions. When do we get localized exceptions? >> > >> > What do you mean by "localized exceptions"? >> > >> > Please, tell me it's *NOT* a proposal to send the exception message in >> > the >> > locale language! >> It is. I think I read it mention

RE: How to: Setuptools

2013-05-27 Thread Carlos Nepomuceno
> Date: Mon, 27 May 2013 20:54:53 -0700 > Subject: Re: How to: Setuptools > From: rustompm...@gmail.com [...] > > Oooff! Talk of using sledgehammers to crack nuts... > > All that is needed is to visit http://peak.telecommunity.com/dist/ez_setup.py > with the

Re: I want to know how to implement concurrent threads in Python

2013-05-27 Thread Daniel Gagliardi
fuck! fuck! i'm gonna be fired if i didnt get this shit! i told my boss id do it. fuck! im gonna pipe some crakc. fuck... 2013/5/26 Mark Lawrence > On 26/05/2013 20:10, Daniel Gagliardi wrote: > >> I want to know how to implement concurrent threads in Python >> >> > google, bing, duckduckgo, ya

Re: How to: Setuptools

2013-05-27 Thread rusi
On May 28, 8:06 am, Carlos Nepomuceno wrote: > > > > Date: Mon, 27 May 2013 19:57:47 -0700 > > Subject: Re: How to: Setuptools > > From: rustompm...@gmail.com > > To: python-l...@python.org > > > On May 28, 6:45 am, Carlos Nepomuceno > > wrote: > >> curl -

Re: Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Bryan Britten
On Monday, May 27, 2013 7:58:05 PM UTC-4, Dave Angel wrote: > On 05/27/2013 04:47 PM, Bryan Britten wrote: > > > Hey, everyone! > > > > > > I'm very new to Python and have only been using it for a couple of days, > > but have some experience in programming (albeit mostly statistical > > progra

RE: How to: Setuptools

2013-05-27 Thread Carlos Nepomuceno
> Date: Mon, 27 May 2013 19:57:47 -0700 > Subject: Re: How to: Setuptools > From: rustompm...@gmail.com > To: python-list@python.org > > On May 28, 6:45 am, Carlos Nepomuceno > wrote: >> curl -Ohttp://peak.telecommunity.com/dist/ez_setup.py >> python ez_set

Re: How to: Setuptools

2013-05-27 Thread rusi
On May 28, 6:45 am, Carlos Nepomuceno wrote: > curl -Ohttp://peak.telecommunity.com/dist/ez_setup.py > python ez_setup.py Curl comes built into windows?? Does not seem so... http://serverfault.com/questions/483754/is-there-a-built-in-command-line-tool-under-windows-like-wget-curl Also given that

RE: Minor consistency question in io.IOBase

2013-05-27 Thread Carlos Nepomuceno
> Date: Mon, 27 May 2013 14:22:17 -0700 > Subject: Minor consistency question in io.IOBase > From: dwight.g...@gmail.com > To: python-list@python.org > > Hi, so, I don't necessarily know if this is the right place to ask this > question since it's kindof a

RE: How to: Setuptools

2013-05-27 Thread Carlos Nepomuceno
curl -O http://peak.telecommunity.com/dist/ez_setup.py python ez_setup.py > Date: Mon, 27 May 2013 18:32:43 -0700 > Subject: How to: Setuptools > From: r...@aarden.us > To: python-list@python.org > > I would like to use easy_install, but can't figure out ho

Re: Future standard GUI library

2013-05-27 Thread Denis McMahon
On Tue, 28 May 2013 08:21:25 +1000, Chris Angelico wrote: > I'll use XML when I have to, but if I'm inventing my own protocol, > nope. There are just too many quirks with it. How do you represent an > empty string named Foo? > > or equivalently > > How do you represent an empty list named Fo

How to: Setuptools

2013-05-27 Thread ray
I would like to use easy_install, but can't figure out how to install it. I have 64-bit Python 2.7.5 on Windows 7. Following the instructions on https://pypi.python.org/pypi/setuptools, it says: Download ez_setup.py and run it; it will download the appropriate .egg file and install it for you.

RE: Total Beginner - Extracting Data from a Database Online (Screenshot)

2013-05-27 Thread Carlos Nepomuceno
> Date: Mon, 27 May 2013 17:58:00 -0700 > Subject: Re: Total Beginner - Extracting Data from a Database Online > (Screenshot) > From: logan.c.gra...@gmail.com > To: python-list@python.org [...] > > Oh goodness, yes, I have no clue. For example: # to retri

Re: Total Beginner - Extracting Data from a Database Online (Screenshot)

2013-05-27 Thread logan . c . graham
On Saturday, May 25, 2013 6:33:25 PM UTC-7, John Ladasky wrote: > On Friday, May 24, 2013 4:36:35 PM UTC-7, Carlos Nepomuceno wrote: > > > #to create the tables list > > > tables=[[re.findall('(.*?)',r,re.S) for r in > > re.findall('(.*?)',t,re.S)] for t in > > re.findall('(.*?)',page,re.S)] >

Re: How to get an integer from a sequence of bytes

2013-05-27 Thread Dave Angel
On 05/27/2013 08:31 PM, Steven D'Aprano wrote: On Mon, 27 May 2013 11:30:18 -0400, Ned Batchelder wrote: On 5/27/2013 10:45 AM, Mok-Kong Shen wrote: From an int one can use to_bytes to get its individual bytes, but how can one reconstruct the int from the sequence of bytes? The next thing

RE: How to get an integer from a sequence of bytes

2013-05-27 Thread Carlos Nepomuceno
> From: steve+comp.lang.pyt...@pearwood.info > Subject: Re: How to get an integer from a sequence of bytes > Date: Mon, 27 May 2013 15:00:39 + > To: python-list@python.org > > On Mon, 27 May 2013 16:45:05 +0200, Mok-Kong Shen wrote: > >> From an int one

Re: How to get an integer from a sequence of bytes

2013-05-27 Thread Steven D'Aprano
On Mon, 27 May 2013 11:30:18 -0400, Ned Batchelder wrote: > On 5/27/2013 10:45 AM, Mok-Kong Shen wrote: >> From an int one can use to_bytes to get its individual bytes, but how >> can one reconstruct the int from the sequence of bytes? >> >> > The next thing in the docs after int.to_bytes is int.f

RE: Ldap module and base64 oncoding

2013-05-27 Thread Joseph L. Casale
> Note that all modules in python-ldap up to 2.4.10 including module 'ldif' > expect raw byte strings to be passed as arguments. It seems to me you're > passing a Unicode object in the entry dictionary which will fail in case an > attribute value contains NON-ASCII chars. Yup, I was. > python-lda

Re: Short-circuit Logic

2013-05-27 Thread Nobody
On Mon, 27 May 2013 13:11:28 -0700, Ahmed Abdulshafy wrote: > On Sunday, May 26, 2013 2:13:47 PM UTC+2, Steven D'Aprano wrote: > >> What the above actually tests for is whether x is so small that (1.0+x) >> cannot be distinguished from 1.0, which is not the same thing. It is >> also quite arbitrar

Re: Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Dave Angel
On 05/27/2013 04:47 PM, Bryan Britten wrote: Hey, everyone! I'm very new to Python and have only been using it for a couple of days, but have some experience in programming (albeit mostly statistical programming in SAS or R) so I'm hoping someone can answer this question in a technical way, b

Re: Python error codes and messages location

2013-05-27 Thread Fábio Santos
On 27 May 2013 19:36, "Fábio Santos" wrote: > > > On 27 May 2013 19:23, "Vito De Tullio" wrote: > > > > Fábio Santos wrote: > > > > >> This should make life easier for us > > > http://docs.python.org/3/whatsnew/3.3.html#pep-3151-reworking-the-os-and-io-exception-hierarchy > > > > > > Speaking of

Re: Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Fábio Santos
On 27 May 2013 22:36, "Bryan Britten" wrote: > > Try to not sigh audibly as I ask what I'm sure are two asinine questions. > > 1) How is this approach different from twtrDict = [json.loads(line) for line in urllib.urlopen(urlStr)]? > The suggested approach made use of generators. Just because you

Re: Future standard GUI library

2013-05-27 Thread Roy Smith
In article , Chris Angelico wrote: > I'll use XML when I have to, but if I'm inventing my own protocol, > nope. There are just too many quirks with it. How do you represent an > empty string named Foo? > > > > or equivalently > > > > How do you represent an empty list named Foo? The same w

Re: Future standard GUI library

2013-05-27 Thread Chris Angelico
On Tue, May 28, 2013 at 3:13 AM, Michael Torrie wrote: > On 05/27/2013 09:31 AM, Wolfgang Keller wrote: >>> HTTP handles that just fine, with your choice of XML, >> >> And XML is definitely not suitable as a marshalling format for a RPC >> protocol. >> >> XML-over-HTTP is a true cerebral flatulanc

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Chris Angelico
On Tue, May 28, 2013 at 2:56 AM, Νίκος Γκρ33κ wrote: > Τη Δευτέρα, 27 Μαΐου 2013 6:52:32 μ.μ. UTC+3, ο χρήστης Chris Angelico έγραψε: > >> Oh, and you may want to hire a typist, too. At the moment, your posts >> make you appear not to care about the job. > > I always make typos when iam typing fas

Re: Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Denis McMahon
On Mon, 27 May 2013 14:29:38 -0700, Bryan Britten wrote: > Try to not sigh audibly as I ask what I'm sure are two asinine > questions. > > 1) How is this approach different from twtrDict = [json.loads(line) for > line in urllib.urlopen(urlStr)]? > > 2) How do I tell how many JSON objects are on

Re: Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Bryan Britten
Try to not sigh audibly as I ask what I'm sure are two asinine questions. 1) How is this approach different from twtrDict = [json.loads(line) for line in urllib.urlopen(urlStr)]? 2) How do I tell how many JSON objects are on each line? -- http://mail.python.org/mailman/listinfo/python-list

Minor consistency question in io.IOBase

2013-05-27 Thread dwight . guth
Hi, so, I don't necessarily know if this is the right place to ask this question since it's kindof a rather technical one which gets into details of the python interpreter itself, but I thought I'd start here and if nobody knew the answer, they could let me know if it makes sense to ask on pytho

Re: Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Roy Smith
In article <10be5c62-4c58-4b4f-b00a-82d85ee4e...@googlegroups.com>, Bryan Britten wrote: > If I use the following code: > > > import urllib > > urlStr = "https://stream.twitter.com/1/statuses/sample.json"; > > fileHandle = urllib.urlopen(urlStr) > > twtrText = fileHandle.readlines() > > >

Reading *.json from URL - json.loads() versus urllib.urlopen.readlines()

2013-05-27 Thread Bryan Britten
Hey, everyone! I'm very new to Python and have only been using it for a couple of days, but have some experience in programming (albeit mostly statistical programming in SAS or R) so I'm hoping someone can answer this question in a technical way, but without using an abundant amount of jargon.

Re: Short-circuit Logic

2013-05-27 Thread Nobody
On Sun, 26 May 2013 04:11:56 -0700, Ahmed Abdulshafy wrote: > I'm having a hard time wrapping my head around short-circuit logic that's > used by Python, coming from a C/C++ background; so I don't understand why > the following condition is written this way!> > > if not allow_zero and abs(x)

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Νίκος Γκρ33κ
I have checked the database through phpMyAdmin and it is indeed UTF-8. I have no idea why python 3.3.1 chooses to work with latin-iso only -- http://mail.python.org/mailman/listinfo/python-list

Re: Short-circuit Logic

2013-05-27 Thread Ahmed Abdulshafy
On Sunday, May 26, 2013 2:13:47 PM UTC+2, Steven D'Aprano wrote: > On Sun, 26 May 2013 04:11:56 -0700, Ahmed Abdulshafy wrote: > > > > > Hi, > > > I'm having a hard time wrapping my head around short-circuit logic > > > that's used by Python, coming from a C/C++ background; so I don't > > > u

Re: Short-circuit Logic

2013-05-27 Thread Ahmed Abdulshafy
On Sunday, May 26, 2013 1:11:56 PM UTC+2, Ahmed Abdulshafy wrote: > Hi, > > I'm having a hard time wrapping my head around short-circuit logic that's > used by Python, coming from a C/C++ background; so I don't understand why the > following condition is written this way!> > > > > if not

Re: 64-bit Python for Solaris

2013-05-27 Thread Matchek
2013/5/21 Maciej (Matchek) Bliziński : > the ${prefix}/lib/pythonX.Y/_sysconfigdata.py file contains > system-specific information ...and is installed in an architecture-independent directory by the Python installer. This looks broken to me. -- http://mail.python.org/mailman/listinfo/python-lis

SQLObject 1.3.3 and 1.4.1

2013-05-27 Thread Oleg Broytman
Hello! I'm pleased to announce bugfix releases 1.3.3 and 1.4.1. What's new in SQLObject === * Fixed bugs in pickling and unpickling (remove/restore a weak proxy to self, fixed cache handling). * Added an example of using SQLObject with web.py to the links page. Contribut

Re: serialize a class to XML and back

2013-05-27 Thread Irmen de Jong
On 27-5-2013 2:39, Roy Smith wrote: > In article <51a28f42$0$15870$e4fe5...@news.xs4all.nl>, > Irmen de Jong wrote: > >> On 26-5-2013 22:48, Roy Smith wrote: >> >>> The advantage of pickle over json is that pickle can serialize many >>> types of objects that json can't. The other side of the c

Re: Python error codes and messages location

2013-05-27 Thread Fábio Santos
On 27 May 2013 19:23, "Vito De Tullio" wrote: > > Fábio Santos wrote: > > >> This should make life easier for us > > http://docs.python.org/3/whatsnew/3.3.html#pep-3151-reworking-the-os-and-io-exception-hierarchy > > > > Speaking of PEPs and exceptions. When do we get localized exceptions? > > Wha

Re: Python error codes and messages location

2013-05-27 Thread Vito De Tullio
Fábio Santos wrote: >> This should make life easier for us > http://docs.python.org/3/whatsnew/3.3.html#pep-3151-reworking-the-os-and-io-exception-hierarchy > > Speaking of PEPs and exceptions. When do we get localized exceptions? What do you mean by "localized exceptions"? Please, tell me it's

Re: Python error codes and messages location

2013-05-27 Thread Terry Jan Reedy
On 5/27/2013 12:54 PM, Carlos Nepomuceno wrote: I think PEP 3151 is a step ahead! That's almost exactly what I was looking for. Why did it take so long to have that implemented? Since this PEP involved changing existing features, rather than adding som

Re: Python error codes and messages location

2013-05-27 Thread Mark Lawrence
On 27/05/2013 17:54, Carlos Nepomuceno wrote: I think PEP 3151 is a step ahead! That's almost exactly what I was looking for. Why did it take so long to have that implemented? Lack of volunteers. -- If you're using GoogleCrap™ please read this http:/

Re: Future standard GUI library

2013-05-27 Thread Michael Torrie
On 05/27/2013 09:22 AM, Wolfgang Keller wrote: >> suppose I now want the app natively on my phone (because that's all >> the rage). It's an iPhone. Oh. Apple doesn't support Python. >> Okay, rewrite the works, including business logic, in Objective C. >> Now I want it on my android phone. > >

Re: Future standard GUI library

2013-05-27 Thread Michael Torrie
On 05/27/2013 09:31 AM, Wolfgang Keller wrote: >> HTTP handles that just fine, with your choice of XML, > > And XML is definitely not suitable as a marshalling format for a RPC > protocol. > > XML-over-HTTP is a true cerebral flatulance of some hopelessly clueless > moron. Hmm. Well I think th

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Νίκος Γκρ33κ
Τη Δευτέρα, 27 Μαΐου 2013 6:52:32 μ.μ. UTC+3, ο χρήστης Chris Angelico έγραψε: > So you want to pay someone who won't ask for money? > It may be sordid, but you're going to have to discuss money at some > point if you're serious about paying someone. > Oh, and you may want to hire a typist, too. A

RE: Python error codes and messages location

2013-05-27 Thread Carlos Nepomuceno
Thanks so much guys! I'm not planning to prepare for every possible situation, but I certainly am responsible to handle most common errors. So it's really important to know what a function/method returns when called. Exception handling may take lots of code, but I'm used to it. It's much better

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Chris Angelico
On Tue, May 28, 2013 at 1:37 AM, Νίκος Γκρ33κ wrote: > Τη Δευτέρα, 27 Μαΐου 2013 5:45:25 μ.μ. UTC+3, ο χρήστης Mark Lawrence έγραψε: > >> Sure, all you need do is get your cheque book out. Also have you ever >> heard the expression "patience is a virtue"? > > Well, if i'am gonna pay someone and i

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Νίκος Γκρ33κ
Τη Δευτέρα, 27 Μαΐου 2013 5:45:25 μ.μ. UTC+3, ο χρήστης Mark Lawrence έγραψε: > Sure, all you need do is get your cheque book out. Also have you ever > heard the expression "patience is a virtue"? Well, if i'am gonna pay someone and i will at some point because i want my script to be also re-w

Re: Future standard GUI library

2013-05-27 Thread Wolfgang Keller
> HTTP handles that just fine, with your choice of XML, And XML is definitely not suitable as a marshalling format for a RPC protocol. XML-over-HTTP is a true cerebral flatulance of some hopelessly clueless moron. Sincerely, Wolfgang -- http://mail.python.org/mailman/listinfo/python-list

Re: How to get an integer from a sequence of bytes

2013-05-27 Thread Ned Batchelder
On 5/27/2013 10:45 AM, Mok-Kong Shen wrote: From an int one can use to_bytes to get its individual bytes, but how can one reconstruct the int from the sequence of bytes? The next thing in the docs after int.to_bytes is int.from_bytes: http://docs.python.org/3.3/library/stdtypes.html#int.from_

Re: Future standard GUI library

2013-05-27 Thread Wolfgang Keller
> Your back end exposes services and business logic, and your front end > can be in HTMLv5 and Javascript, or QtQuick, PyGTK, or Visual > Studio. If you do need a native interface, it's a heck of a lot > easier to rewrite just the frontend then the entire stack. Any decent database CRUD framework

Re: How to get an integer from a sequence of bytes

2013-05-27 Thread Steven D'Aprano
On Mon, 27 May 2013 16:45:05 +0200, Mok-Kong Shen wrote: > From an int one can use to_bytes to get its individual bytes, but how > can one reconstruct the int from the sequence of bytes? Here's one way: py> n = 11999102937234 py> m = 0 py> for b in n.to_bytes(6, 'big'): ... m = 256*m + b ...

How to get an integer from a sequence of bytes

2013-05-27 Thread Mok-Kong Shen
From an int one can use to_bytes to get its individual bytes, but how can one reconstruct the int from the sequence of bytes? Thanks in advance. M. K. Shen -- http://mail.python.org/mailman/listinfo/python-list

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Mark Lawrence
On 27/05/2013 15:16, Νίκος Γκρ33κ wrote: I cant solve this plz help! Sure, all you need do is get your cheque book out. Also have you ever heard the expression "patience is a virtue"? -- If you're using GoogleCrap™ please read this http://wiki.python.org/moin/GoogleGroupsPython. Mark La

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Michael Torrie
On 05/26/2013 11:06 PM, Νίκος Γκρ33κ wrote: > But iu have it set up for 'utf-8' as seen in this statement. > > con = pymysql.connect( db = 'metrites', host = 'localhost', user = > 'me', passwd = 'somepass', charset='utf-8', init_command='SET NAMES UTF8' ) That might not help... see below. > >

Re: Encodign issue in Python 3.3.1 (once again)

2013-05-27 Thread Νίκος Γκρ33κ
I cant solve this plz help! -- http://mail.python.org/mailman/listinfo/python-list

Re: Python error codes and messages location

2013-05-27 Thread Fábio Santos
On Mon, May 27, 2013 at 2:11 PM, Steven D'Aprano wrote: > On Mon, 27 May 2013 13:46:50 +0100, Fábio Santos wrote: > >> Speaking of PEPs and exceptions. When do we get localized exceptions? > > > We're waiting for you to volunteer. When can you start? I'd love to work on that but my C is too shabb

Re: Python error codes and messages location

2013-05-27 Thread Steven D'Aprano
On Mon, 27 May 2013 13:46:50 +0100, Fábio Santos wrote: > Speaking of PEPs and exceptions. When do we get localized exceptions? We're waiting for you to volunteer. When can you start? -- Steven -- http://mail.python.org/mailman/listinfo/python-list

Re: Problems with python and pyQT

2013-05-27 Thread Chris “Kwpolska” Warrick
On Mon, May 27, 2013 at 11:26 AM, wrote: > Hi, > i'm new with python: so excuse me for my questions > i have this code: > > def updateLog(self, text): > self.ui.logTextEdit.moveCursor(QTextCursor.End) > self.ui.logTextEdit.insertHtml(""+text) > self.ui.logTextEdit.

Re: Python error codes and messages location

2013-05-27 Thread Fábio Santos
On 27 May 2013 12:41, "Mark Lawrence" wrote: > This should make life easier for us http://docs.python.org/3/whatsnew/3.3.html#pep-3151-reworking-the-os-and-io-exception-hierarchy Speaking of PEPs and exceptions. When do we get localized exceptions? -- http://mail.python.org/mailman/listinfo/pyth

Scary Pranks

2013-05-27 Thread MoneyMaker
http://horrorhorrorhorror.webs.com/scary-pranks -- http://mail.python.org/mailman/listinfo/python-list

Re: This mail never gets delivered. Any ideas why?

2013-05-27 Thread Mark Lawrence
On 27/05/2013 10:15, Νίκος Γκρ33κ wrote: Please, do you see an error in this? As i said the 2nd solution doesnt provide an error but also doesn't get the mail send too. At least you're improving. Yesterday you were chasing after two hours, it's now up to four hours 15 minutes. Keep doublin

Re: Python error codes and messages location

2013-05-27 Thread Mark Lawrence
On 27/05/2013 07:11, Cameron Simpson wrote: BTW, I recommend importing "errno" and using symbolic names. It makes things much more readable, and accomodates the situation where the symbols map to different numbers on different platforms. And have a catch-all. For example: Cheers, This shou

Re: Piping processes works with 'shell = True' but not otherwise.

2013-05-27 Thread Luca Cerone
> > > Will it violate privacy / NDA to post the command line? Even if we > > can't actually replicate your system, we may be able to see something > > from the commands given. > > Unfortunately yes.. -- http://mail.python.org/mailman/listinfo/python-list

Re: How to create new python file with increament number, if doesn't exist?

2013-05-27 Thread Jens Thoms Toerring
Avnesh Shakya wrote: >I want to create a new python file like 'data0.0.5', but if it is already > exist then it should create 'data0.0.6', if it's also exist then next like > 'data0.0.7'. I have done, but with range, please give me suggestion so that > I can do it with specifying range. > I wa

Re: How to create new python file with increament number, if doesn't exist?

2013-05-27 Thread Avnesh Shakya
Thanks On Mon, May 27, 2013 at 4:19 PM, Denis McMahon wrote: > On Mon, 27 May 2013 02:27:59 -0700, Avnesh Shakya wrote: > > > I want to create a new python file like 'data0.0.5', but if it is > > already exist then it should create 'data0.0.6', if it's also exist > > then next like 'data0.0.7'.

Re: how to compare two json file line by line using python?

2013-05-27 Thread Denis McMahon
On Sun, 26 May 2013 21:32:40 -0700, Avnesh Shakya wrote: >how to compare two json file line by line using python? Actually I am >doing it in this way.. Oh what a lot of homework you have today. Did you ever stop to think what the easiest way to compare two json datasets is? -- Denis M

Re: How to create new python file with increament number, if doesn't exist?

2013-05-27 Thread Denis McMahon
On Mon, 27 May 2013 02:27:59 -0700, Avnesh Shakya wrote: > I want to create a new python file like 'data0.0.5', but if it is > already exist then it should create 'data0.0.6', if it's also exist > then next like 'data0.0.7'. I have done, but with range, please give > me suggestion so that I can do

How to create new python file with increament number, if doesn't exist?

2013-05-27 Thread Avnesh Shakya
hi, I want to create a new python file like 'data0.0.5', but if it is already exist then it should create 'data0.0.6', if it's also exist then next like 'data0.0.7'. I have done, but with range, please give me suggestion so that I can do it with specifying range. I was trying this way and it'

Problems with python and pyQT

2013-05-27 Thread silusilusilu
Hi, i'm new with python: so excuse me for my questions i have this code: def updateLog(self, text): self.ui.logTextEdit.moveCursor(QTextCursor.End) self.ui.logTextEdit.insertHtml(""+text) self.ui.logTextEdit.moveCursor(QTextCursor.End) logTextEdit is a QTextEdit o

Re: This mail never gets delivered. Any ideas why?

2013-05-27 Thread Νίκος Γκρ33κ
Please, do you see an error in this? As i said the 2nd solution doesnt provide an error but also doesn't get the mail send too. -- http://mail.python.org/mailman/listinfo/python-list

Re: Piping processes works with 'shell = True' but not otherwise.

2013-05-27 Thread Chris Angelico
On Mon, May 27, 2013 at 9:58 AM, Luca Cerone wrote: >> Could you provide the *actual* commands you're using, rather than the >> generic "program1" and "program2" placeholders? It's *very* common for >> people to get the tokenization of a command line wrong (see the Note box in >> http://docs.py

Re: help?? on functions

2013-05-27 Thread John Ladasky
Steven gave you a lot of good advice. Let me add just one remark. Python already has a builtin function called "input." If you define a variable with the same name as a builtin and then you try to use that builtin, you will be in for a (usually unpleasant) surprise. -- http://mail.python.org/

Re: Ldap module and base64 oncoding

2013-05-27 Thread Michael Ströder
Joseph L. Casale wrote: > After parsing the data for a user I am simply taking a value from the ldif > file and writing > it back out to another which fails, the value parsed is: > > officestreetaddress:: T3R0by1NZcOfbWVyLVN0cmHDn2UgMQ== > > > File "C:\Python27\lib\site-packages\ldif.py", lin

Re: Python error codes and messages location

2013-05-27 Thread Chris Angelico
On Mon, May 27, 2013 at 4:11 PM, Cameron Simpson wrote: > On 27May2013 04:49, Carlos Nepomuceno wrote: > | That's bad! I'd like to check all the IOError codes that may be > | raised by a function/method but the information isn't there. > > No, you really don't. Heh. I concur. Opening a file can

Re: Solving the problem of mutual recursion

2013-05-27 Thread Chris Angelico
On Mon, May 27, 2013 at 4:07 PM, Ian Kelly wrote: > On Sun, May 26, 2013 at 10:36 PM, Peter Brooks > wrote: >> This makes complete sense - any atomic action should be atomic, so two >> threads can't be doing it at the same time. They can be doing anything >> else though. >> >> If two threads crea

Re: help?? on functions

2013-05-27 Thread lokeshkoppaka
On Monday, May 27, 2013 11:18:34 AM UTC+5:30, Steven D'Aprano wrote: > On Sun, 26 May 2013 21:48:34 -0700, lokeshkoppaka wrote: > > > > > def shuffle(input, i, j): > > > pass > > > input = input[i:j+1] +input[0:i] + input[j+1:] > > > > "pass" does nothing. Take it out. > > > > >

Re: Solving the problem of mutual recursion

2013-05-27 Thread Ian Kelly
On Mon, May 27, 2013 at 12:19 AM, Ian Kelly wrote: > 7) Since the program being tested does basically nothing except start > and exit threads, the extra 40% probably represents the overhead of > all that starting and stopping, which would be done outside the GIL. To test this, I tried running the