Re: Google Cloud Platform and GlassSolver Project

2014-02-10 Thread Duncan Booth
eliasbylar...@gmail.com wrote: > I am fully ready to invest in the Google Cloud Platform, and bring > with me my very own idea: Glass Solver (Sometimes called GlaSolver). One thing you will have to do is find another name for your project. https://developers.google.com/glass/design/branding-guide

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Anssi Saari
Asaf Las writes: > btw, Python could be language of choice for embedded systems if small > footprint > vm could be developed. had seen similar for java having 10-20 KB byte sized > interpreter with very limited set of functions. Well, there's the newish Micro python project. Its footprint is

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Sturla Molden
Wesley wrote: > [Wesley] This is not homework:-) > And actually I am new to algorithm, so you guys can feel free to say anything > you want In general, we cannot sort a sequence in O(n) time. O(n log n) is the lower bound on the complexity. -- https://mail.python.org/mailman/listinfo/python-l

Re: Using virtualenv to bypass sudoer issues

2014-02-10 Thread Jean-Michel Pichavant
Thank you all for you insights. I'll probably go with virtualenv, I'll be able to distribute it among the team. There's still one point worrying me though: We're doing a lot a remote execution. We're using "execnet" http://codespeak.net/execnet/, and I'm not sure it can be compatible with virtua

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Chris Angelico
On Mon, Feb 10, 2014 at 9:20 PM, Sturla Molden wrote: > Wesley wrote: >> [Wesley] This is not homework:-) >> And actually I am new to algorithm, so you guys can feel free to say >> anything you want > > In general, we cannot sort a sequence in O(n) time. O(n log n) is the lower > bound on the co

Re: Vedr: What does """ means in python?

2014-02-10 Thread Duncan Booth
Gisle Vanem wrote: > Regrading handy uses of ''', you learned me one trick when using Pythonÿ > code in a Windows .bat file: > > rem = ''' > @echo off > echo This is batch > \python32\python %0 > echo All done > exit /b > rem ''' > import sys > print("This is Python") > for i,p in enum

Re: Google Cloud Platform and GlassSolver Project

2014-02-10 Thread EliasL
On Monday, February 10, 2014 4:12:40 AM UTC-5, Duncan Booth wrote: > EliasL wrote: > > > > > I am fully ready to invest in the Google Cloud Platform, and bring > > > with me my very own idea: Glass Solver (Sometimes called GlaSolver). > > > > One thing you will have to do is find another nam

Re: Google Cloud Platform and GlassSolver Project

2014-02-10 Thread EliasL
On Sunday, February 9, 2014 9:57:42 PM UTC-5, Dave Angel wrote: > EliasL Wrote in message: > > > Also I should mention that I will credit whomever writes the scripts. I > > have contacted Google on their Compute Engine which would execute these > > scripts. I am await a reply! > > > > > > >

Re: Google Cloud Platform and GlassSolver Project

2014-02-10 Thread EliasL
Boy am I glad that this is still alive! What do I mean? Click: http://www.speedsolving.com/forum/showthread.php?46268-Introducing-GlassSolver-back-and-better-than-ever!&p=951473 -- https://mail.python.org/mailman/listinfo/python-list

Pylint across Python versions

2014-02-10 Thread thomas . lehmann
Hi, somebody who can tell me about pylint experiences across different Python version. Example: I'm using a construct like this: if sys.version.startswith("3."): unicode = str The reason is that Python 3 does not have this function anymore but pylint yells for Python < 3 about redefinition

Re: Google Cloud Platform and GlassSolver Project

2014-02-10 Thread Mark Lawrence
On 10/02/2014 11:09, EliasL wrote: [all double line spaced stuff snipped] Would you please read and action this https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the double line spacing that you are sending, thanks. -- My fellow Pythonistas, ask not what our language can d

Re: Pylint across Python versions

2014-02-10 Thread Mark Lawrence
On 10/02/2014 11:39, thomas.lehm...@adtech.com wrote: Hi, somebody who can tell me about pylint experiences across different Python version. Example: I'm using a construct like this: if sys.version.startswith("3."): unicode = str The reason is that Python 3 does not have this function an

Re: Pylint across Python versions

2014-02-10 Thread Chris Angelico
On Mon, Feb 10, 2014 at 10:39 PM, wrote: > Example: > I'm using a construct like this: > > if sys.version.startswith("3."): > unicode = str > > The reason is that Python 3 does not have this > function anymore but pylint yells for Python < 3 > about redefinition also it does not happen. > > H

Re: Finding size of Variable

2014-02-10 Thread wxjmfauth
Le samedi 8 février 2014 03:48:12 UTC+1, Steven D'Aprano a écrit : > > > We consider it A GOOD THING that Python spends memory for programmer > > convenience and safety. Python looks for memory optimizations when it can > > save large amounts of memory, not utterly trivial amounts. So in a Py

Re: Using virtualenv to bypass sudoer issues

2014-02-10 Thread Pete Forman
Jean-Michel Pichavant writes: > Thank you all for you insights. > > I'll probably go with virtualenv, I'll be able to distribute it among > the team. > There's still one point worrying me though: > We're doing a lot a remote execution. We're using "execnet" > http://codespeak.net/execnet/, and I'

Re: Finding size of Variable

2014-02-10 Thread Asaf Las
On Monday, February 10, 2014 4:07:14 PM UTC+2, wxjm...@gmail.com wrote: Interesting > >>> sys.getsizeof('a' * 100) here you get string type > >>> sys.getsizeof(('a' * 100 + 'oe' + '\U0001').encode('utf-8')) and here bytes >>> type ('a' * 1) >>> type(('a' * 100 + 'oe' + '\U

Re: Finding size of Variable

2014-02-10 Thread Mark Lawrence
On 10/02/2014 14:25, Asaf Las wrote: On Monday, February 10, 2014 4:07:14 PM UTC+2, wxjm...@gmail.com wrote: Interesting sys.getsizeof('a' * 100) here you get string type sys.getsizeof(('a' * 100 + 'oe' + '\U0001').encode('utf-8')) and here bytes type ('a' * 1) type(('a

Re: Finding size of Variable

2014-02-10 Thread Tim Chase
On 2014-02-10 06:07, wxjmfa...@gmail.com wrote: > Python does not save memory at all. A str (unicode string) > uses less memory only - and only - because and when one uses > explicitly characters which are consuming less memory. > > Not only the memory gain is zero, Python falls back to the > wors

Re: Using virtualenv to bypass sudoer issues

2014-02-10 Thread Jean-Michel Pichavant
> Call the venv version of python and activation is handled. > E.g. in a fabfile > > myenv/bin/python myscript.py > > -- > Pete Forman > -- > https://mail.python.org/mailman/listinfo/python-list wow, the solution is so nice and simple. JM -- IMPORTANT NOTICE: The contents of this emai

Re: Finding size of Variable

2014-02-10 Thread Ned Batchelder
On 2/10/14 9:43 AM, Tim Chase wrote: On 2014-02-10 06:07, wxjmfa...@gmail.com wrote: Python does not save memory at all. A str (unicode string) uses less memory only - and only - because and when one uses explicitly characters which are consuming less memory. Not only the memory gain is zero, P

NYC-based Python Careers

2014-02-10 Thread Matt Battista
Hey everyone! I am a Python developer recruiter based in NYC. I'm currently representing Fortune 500 companies as well as 5 person start ups that have needs for developers with basic to advanced Python skills. If you're looking for a career change in the area or want to experience NYC for the f

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Sturla Molden
Chris Angelico wrote: > That's assuming it really is a sort operation. The problem description > isn't entirely clear on this point, but if it's actually a zip, then > it can definitely be done in O(n). Ah, I didn't read it carefully enough. :-) Granted, a zip can be done in O(n) time and O(1)

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 2:03 AM, Sturla Molden wrote: > Chris Angelico wrote: > >> That's assuming it really is a sort operation. The problem description >> isn't entirely clear on this point, but if it's actually a zip, then >> it can definitely be done in O(n). > > Ah, I didn't read it carefull

Re: NYC-based Python Careers

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 2:06 AM, Matt Battista wrote: > I am a Python developer recruiter based in NYC. I'm currently representing > Fortune 500 companies as well as 5 person start ups that have needs for > developers with basic to advanced Python skills. If you're looking for a > career change

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Oscar Benjamin
On 10 February 2014 15:03, Sturla Molden wrote: > Chris Angelico wrote: > >> That's assuming it really is a sort operation. The problem description >> isn't entirely clear on this point, but if it's actually a zip, then >> it can definitely be done in O(n). > > Ah, I didn't read it carefully enou

Re: Pylint across Python versions

2014-02-10 Thread Ned Batchelder
On 2/10/14 6:39 AM, thomas.lehm...@adtech.com wrote: Hi, somebody who can tell me about pylint experiences across different Python version. Example: I'm using a construct like this: if sys.version.startswith("3."): unicode = str The reason is that Python 3 does not have this function any

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 2:45 AM, Oscar Benjamin wrote: > Something like > > mylist[:] = reorder_generator(mylist) > > won't work because the generator would need to access the data > non-sequentially (it would need to read elements after they were > overwritten). This would have O(1) space an

Re: Using virtualenv to bypass sudoer issues

2014-02-10 Thread Asaf Las
On Monday, February 10, 2014 4:46:31 PM UTC+2, Jean-Michel Pichavant wrote: > > Call the venv version of python and activation is handled. > > E.g. in a fabfile > > > > myenv/bin/python myscript.py > > > > -- > > Pete Forman > > -- > > https://mail.python.org/mailman/listinfo/python-list > >

Fwd: Newcomer Help

2014-02-10 Thread Walter Hughey
I am new to Python programming, actually new to any programming language. I sent the email below to the "pythonmac-...@python.org a few days ago. So far I have not seen a reply, actually, I have not seen anything from pythonmac in any emails although I am supposed to be a member. I don't know

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Oscar Benjamin
On 10 February 2014 15:52, Chris Angelico wrote: > On Tue, Feb 11, 2014 at 2:45 AM, Oscar Benjamin > wrote: >> Something like >> >> mylist[:] = reorder_generator(mylist) >> >> won't work because the generator would need to access the data >> non-sequentially (it would need to read elements af

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Grant Edwards
On 2014-02-09, Chris Angelico wrote: > Heavy computation might be unideal in Python, but if you can grunge > it into NumPy operations, that won't be a problem. While one might thing Python is not suitable for heavy number crunching, it actually gets used for that a lot due to the wide variety of

Re: system wide mutex

2014-02-10 Thread Grant Edwards
On 2014-02-09, Asaf Las wrote: > Hi > > Which one is most recommended to use for mutex alike locking to > achieve atomic access to single resource: > > - fcntl.lockf > - os.open() with O_SHLOCK and O_EXLOCK > - https://pypi.python.org/pypi/lockfile/0.9.1 > - https://pypi.python.org/pypi/zc.lock

Re: Newcomer Help

2014-02-10 Thread Rustom Mody
On Monday, February 10, 2014 9:40:22 PM UTC+5:30, Walter Hughey wrote: > I am new to Python programming, actually new to any programming language. I > sent the email below to the "python...@python.org a few days ago. So far I > have not seen a reply, actually, I have not seen anything from python

Re: system wide mutex

2014-02-10 Thread Miki Tebeka
IIRC creating a directory is atomic in most environments. On Sunday, February 9, 2014 2:39:51 AM UTC-8, Asaf Las wrote: > Hi > > > > Which one is most recommended to use for mutex alike locking to > > achieve atomic access to single resource: > > > > - fcntl.lockf > > - os.open() with O_

PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Rick Johnson
## START CODE ### def foo(): # foo represents a patternless function # or method that returns a Boolean value # based on some internal test. # if 1==1: return True return False # # The fun begins when two tiny chars are forgott

Re: Help with python functions?

2014-02-10 Thread tn156
On Monday, September 23, 2013 6:48:20 PM UTC-4, Terry Reedy wrote: > On 9/23/2013 6:32 PM, kjaku...@gmail.com wrote: > > > On Monday, September 23, 2013 9:56:45 AM UTC-4, Steven D'Aprano wrote: > > >> On Mon, 23 Sep 2013 05:57:34 -0700, kjakupak wrote: > > >> > > >> Now you're done! On to the n

Re: Help with python functions?

2014-02-10 Thread tn156
On Monday, September 23, 2013 6:48:20 PM UTC-4, Terry Reedy wrote: > On 9/23/2013 6:32 PM, kjaku...@gmail.com wrote: > > > On Monday, September 23, 2013 9:56:45 AM UTC-4, Steven D'Aprano wrote: > > >> On Mon, 23 Sep 2013 05:57:34 -0700, kjakupak wrote: > > >> > > >> Now you're done! On to the n

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Mark Lawrence
On 10/02/2014 18:45, Rick Johnson wrote: ## START CODE ### def foo(): # foo represents a patternless function # or method that returns a Boolean value # based on some internal test. # if 1==1: return True return False

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Ned Batchelder
On 2/10/14 1:45 PM, Rick Johnson wrote: ## START CODE ### def foo(): # foo represents a patternless function # or method that returns a Boolean value # based on some internal test. # if 1==1: return True return False #

Re: Newcomer Help

2014-02-10 Thread Walter Hughey
Thank you for your reply. One quick question, when I reply should it be replay to all or to the person who sent the emial? Apple does install a version of Python, normally a somewhat older version. My computer has 2.5 and 2.6 installed and I have opened it and inserted code that works. I do n

Re: Newcomer Help

2014-02-10 Thread Grant Edwards
On 2014-02-10, Walter Hughey wrote: > Apple does install a version of Python, normally a somewhat older > version. My computer has 2.5 and 2.6 installed and I have opened it > and inserted code that works. I do need a way to write the code, test > it, and then save a copy to turn in for the assig

[RELEASED] Python 3.3.4

2014-02-10 Thread Georg Brandl
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On behalf of the Python development team, I'm very happy to announce the release of Python 3.3.4. Python 3.3.4 includes several security fixes and over 120 bug fixes compared to the Python 3.3.3 release. This release fully supports OS X 10.9 Maverick

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Rotwang
On 10/02/2014 18:45, Rick Johnson wrote: [...] 3. Implicit introspection is evil, i prefer all references to a callable's names to result in a CALL to that callable, not an introspection! So, for example, none of isinstance(x, myclass) map(myfunc, range(10)) x = p

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Ned Batchelder
On 2/10/14 4:12 PM, Rotwang wrote: On 10/02/2014 18:45, Rick Johnson wrote: [...] 3. Implicit introspection is evil, i prefer all references to a callable's names to result in a CALL to that callable, not an introspection! So, for example, none of isinstance(x, myclass)

Re: Newcomer Help

2014-02-10 Thread Gisle Vanem
"Walter Hughey" wrote: Thank you for your reply. One quick question, when I reply should it be replay to all or to the person who sent the emial? When replying, the most important thing to remember is... order. A: Because it messes up the order in which people normally read text. Q: Why is i

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 5:45 AM, Rick Johnson wrote: > if foo: # <- forgot parenthesis! > print 'implicit conversion to bool bites!' You also forgot the parentheses on the second line, and that's nothing to do with boolification :) ChrisA -- https://mail.python.org/mailman/listinfo/python-l

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Terry Reedy
On 2/10/2014 4:12 PM, Rotwang wrote: On 10/02/2014 18:45, Rick Johnson wrote: [...] 3. Implicit introspection is evil, i prefer all references to a callable's names to result in a CALL to that callable, not an introspection! So, for example, none of isinstance(x, myclass)

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Steven D'Aprano
On Sun, 09 Feb 2014 06:17:03 +0100, Skybuck Flying wrote: > " > I got to know about Python a few months ago and today, I want to develop > only using Python because of its code readability. This is not a healthy > bias. To play my own devil's advocate, I have a question. What are the > kinds of so

Drawing polygons in python turtle

2014-02-10 Thread geniusrko
Hi can anyone help finding the angle to draw different polygons shapes in this example import turtle wm = turtle.Screen() alex = turtle.Turtle() for i in range(5): alex.left(216) alex.forward(50) wm.exitonclick() Why do we use 216 -- https://mail.python.org/mailman/listinfo/python-li

Re:Drawing polygons in python turtle

2014-02-10 Thread Dave Angel
genius...@gmail.com Wrote in message: > Hi > can anyone help finding the angle to draw different polygons shapes > > in this example > > import turtle > wm = turtle.Screen() > alex = turtle.Turtle() > for i in range(5): > alex.left(216) > alex.forward(50) > wm.exitonclick() > > Why d

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Gregory Ewing
Chris Angelico wrote: mylist = reorder_generator(mylist) You can iterate over it, but can't index it. But hey, it complies with the space/time requirements! Rather than a generator, you could use a view object that rearranges the indices when you access an element. That would comply with the s

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 1:44:28 AM UTC+2, geni...@gmail.com wrote: > Hi > > can anyone help finding the angle to draw different polygons shapes > in this example > import turtle > wm = turtle.Screen() > alex = turtle.Turtle() > for i in range(5): > alex.left(216) > alex.forward(50

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 2:23:11 AM UTC+2, Asaf Las wrote: > On Tuesday, February 11, 2014 1:44:28 AM UTC+2, geni...@gmail.com wrote: > > Hi > > > > can anyone help finding the angle to draw different polygons shapes > > in this example > > import turtle > > wm = turtle.Screen() > > alex =

Re: Fwd: Newcomer Help

2014-02-10 Thread Ned Deily
In article <675340207.6922848.1392048622415.javamail.r...@okbu.edu>, Walter Hughey wrote: > I am new to Python programming, actually new to any programming language. I > sent the email below to the "pythonmac-...@python.org a few days ago. So far > I have not seen a reply, actually, I have not

Re: Drawing polygons in python turtle

2014-02-10 Thread geniusrko
Well how about the star of david what are the angles -- https://mail.python.org/mailman/listinfo/python-list

Re: Sorting dictionary by datetime value

2014-02-10 Thread pete suchsland
How about make it simple by using sorted(a.values()) ... >>> a = {} >>> a['first'] = datetime.datetime.now() >>> a['second'] = datetime.datetime.now() >>> a['third'] = datetime.datetime.now() >>> a['forth'] = datetime.datetime.now() >>> a['fifth'] = datetime.datetime.now() >>> sorted(a.values())

New to Py 3.3.3 having prob. with large integer div. float.

2014-02-10 Thread hlauk . h . bogart
I am coming off Python 2.6.6 32 bite platform and now in win 8.1 64 bite. I had no problems with gmpy in 2.6.6 and large integer floating points where you could control the length of the floating point by entering the bite size of the divisor(s) you are using. That would give the limit length of th

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 4:13:16 AM UTC+2, geni...@gmail.com wrote: > Well how about the star of david what are the angles hexagon is not constructed similar to your program for pentagon because crossing path can't jump from one triangle to another. you have 60 degrees turn after 2 turns edg

Re: Sorting dictionary by datetime value

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 1:31 PM, pete suchsland wrote: > How about make it simple by using sorted(a.values()) ... > a = {} a['first'] = datetime.datetime.now() a['second'] = datetime.datetime.now() a['third'] = datetime.datetime.now() a['forth'] = datetime.datetime.now() >

Re: Drawing polygons in python turtle

2014-02-10 Thread geniusrko
so does that mean i have to draw two separate triangles -- https://mail.python.org/mailman/listinfo/python-list

Re: Sorting dictionary by datetime value

2014-02-10 Thread Asaf Las
Why not use collections.OrderedDict ? There are nice examples in doc: http://docs.python.org/3.3/library/collections.html?highlight=ordered#ordereddict-examples-and-recipes -- https://mail.python.org/mailman/listinfo/python-list

Re: What is the recommended python module for SQL database access?

2014-02-10 Thread Walter Hurry
Chris Angelico wrote: > Broad recommendation: Single application, tiny workload, concurrency > not an issue, simplicity desired? Go SQLite. Big complex job, need > performance, lots of things reading and writing at once, want > networked access? Go PGSQL. And don't go MySQL if PG is an option. > >

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 4:51:56 AM UTC+2, geni...@gmail.com wrote: > so does that mean i have to draw two separate triangles If you need view of crossing triangles - yes, this is the simplest recipe. -- https://mail.python.org/mailman/listinfo/python-list

Re: Drawing polygons in python turtle

2014-02-10 Thread geniusrko
Is there a better way of drawing such as another modules -- https://mail.python.org/mailman/listinfo/python-list

Re: What is the recommended python module for SQL database access?

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 4:57:30 AM UTC+2, Walter Hurry wrote: > Chris Angelico wrote: > > > > And definitely don't go for a non-free option (MS-SQL, DB2, etc) > > unless you've looked into it really closely and you are absolutely > > thoroughly *sure* that you need that system (which probably

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 5:01:33 AM UTC+2, geni...@gmail.com wrote: > Is there a better way of drawing such as another modules Could you please elaborate with question? What do you mean? -- https://mail.python.org/mailman/listinfo/python-list

Re: Drawing polygons in python turtle

2014-02-10 Thread geniusrko
A better way to draw stuff on screen -- https://mail.python.org/mailman/listinfo/python-list

Re: What is the recommended python module for SQL database access?

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 1:57 PM, Walter Hurry wrote: > Chris Angelico wrote: > >> Broad recommendation: Single application, tiny workload, concurrency >> not an issue, simplicity desired? Go SQLite. Big complex job, need >> performance, lots of things reading and writing at once, want >> networked

Re: Drawing polygons in python turtle

2014-02-10 Thread geniusrko
Going off-topic Which resource do you recommend for learning this wonderful language -- https://mail.python.org/mailman/listinfo/python-list

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 5:06:11 AM UTC+2, geni...@gmail.com wrote: > A better way to draw stuff on screen It depends on particular case/figure you wish to draw. Drawing is separate knowledge field with its own set of algorithms. Geometry is field of wonders. i never dealt with this stuff

Re: Drawing polygons in python turtle

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 5:19:52 AM UTC+2, geni...@gmail.com wrote: > Going off-topic Which resource do you recommend for learning this > wonderful language My advice won't be good as mentioned before i never dealt with it. You have chance to discover that country yourself or wait for advic

Re: What is the recommended python module for SQL database access?

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 2:02 PM, Asaf Las wrote: > On Tuesday, February 11, 2014 4:57:30 AM UTC+2, Walter Hurry wrote: >> Chris Angelico wrote: >> > >> > And definitely don't go for a non-free option (MS-SQL, DB2, etc) >> > unless you've looked into it really closely and you are absolutely >> > th

Re: What is the recommended python module for SQL database access?

2014-02-10 Thread Asaf Las
On Tuesday, February 11, 2014 5:31:35 AM UTC+2, Chris Angelico wrote: > On Tue, Feb 11, 2014 at 2:02 PM, Asaf Las wrote: > > > On Tuesday, February 11, 2014 4:57:30 AM UTC+2, Walter Hurry wrote: > >> Chris Angelico wrote: > >> > > >> > And definitely don't go for a non-free option (MS-SQL, DB2, e

Error getting while running python function

2014-02-10 Thread Jaydeep Patil
I have defined one function as below. def InfoDir(msg): msg1 = wx.MessageDialog(msg) msg1.ShowModal() msg1.Destroy() InfoDir("Testing") It gives below error. msg1 = wx.MessageDialog(msg) File "C:\Python27\lib\site-packages\wx-2.8-msw-unicode\wx\_windows.py", line

Re: Error getting while running python function

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 3:07 PM, Jaydeep Patil wrote: > I have defined one function as below. > > def InfoDir(msg): > msg1 = wx.MessageDialog(msg) > msg1.ShowModal() > msg1.Destroy() > > InfoDir("Testing") > > > It gives below error. > msg1 = wx.MessageDialog(msg) > F

Re: Newcomer Help

2014-02-10 Thread William Ray Wing
On Feb 10, 2014, at 11:10 AM, Walter Hughey wrote: > I am new to Python programming, actually new to any programming language. I > sent the email below to the "pythonmac-...@python.org a few days ago. So far > I have not seen a reply, actually, I have not seen anything from pythonmac in > any

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread CM
On Saturday, February 8, 2014 10:43:47 PM UTC-5, Steven D'Aprano wrote: > PyPy can generate code which is comparable to compiled C in speed. > Perhaps you mean, "if execution speed is the most important thing, using > a naive Python interpreter may not be fast enough". Given that the OP seems

Re: Error getting while running python function

2014-02-10 Thread Jaydeep Patil
On Tuesday, 11 February 2014 09:37:23 UTC+5:30, Jaydeep Patil wrote: > I have defined one function as below. > > > > def InfoDir(msg): > > msg1 = wx.MessageDialog(msg) > > msg1.ShowModal() > > msg1.Destroy() > > > > InfoDir("Testing") > > > > > > It gives belo

Re: Error getting while running python function

2014-02-10 Thread Jaydeep Patil
On Tuesday, 11 February 2014 09:42:35 UTC+5:30, Chris Angelico wrote: > On Tue, Feb 11, 2014 at 3:07 PM, Jaydeep Patil > wrote: > > > I have defined one function as below. > > > > > > def InfoDir(msg): > > > msg1 = wx.MessageDialog(msg) > > > msg1.ShowModal() > > >

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Tim Daneliuk
On 02/08/2014 05:54 PM, Sam wrote: I got to know about Python a few months ago and today, I want to develop only using Python because of its code readability. This is not a healthy bias. To play my own devil's advocate, I have a question. What are the kinds of software that are not advisable t

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 3:21 PM, CM wrote: > On Saturday, February 8, 2014 10:43:47 PM UTC-5, Steven D'Aprano wrote: > >> PyPy can generate code which is comparable to compiled C in speed. >> Perhaps you mean, "if execution speed is the most important thing, using >> a naive Python interpreter may

Re: Error getting while running python function

2014-02-10 Thread Chris Angelico
On Tue, Feb 11, 2014 at 3:34 PM, Jaydeep Patil wrote: > There is not parent window such. I just write a simple function to define. > There is no class. > Is it possible to work like the way i am doing? You could try reading the docs; there might be a way to say "no parent window" (maybe pass it N

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Steven D'Aprano
On Mon, 10 Feb 2014 10:20:33 +, Sturla Molden wrote: > Wesley wrote: >> [Wesley] This is not homework:-) >> And actually I am new to algorithm, so you guys can feel free to say >> anything you want > > In general, we cannot sort a sequence in O(n) time. O(n log n) is the > lower bound on the

Re: Sort one sequence by O(n) in time and O(1) in space

2014-02-10 Thread Tim Daneliuk
On 02/10/2014 04:20 AM, Sturla Molden wrote: In general, we cannot sort a sequence in O(n) time. O(n log n) is the lower bound on the complexity. Only true for sorting that involve comparison. However, sorts that use the values of the inputs as positional keys have a lower bound complexity (om

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Steven D'Aprano
On Mon, 10 Feb 2014 22:40:48 -0600, Tim Daneliuk wrote: > On 02/08/2014 05:54 PM, Sam wrote: >> I got to know about Python a few months ago and today, I want to >> develop only using Python because of its code readability. This is not >> a healthy bias. To play my own devil's advocate, I have a qu

Get a datetime with nanoseconds

2014-02-10 Thread Igor Korot
Hi, ALL, I am woking on an application for digital forensic. In this application I am getting this 2 pieces of information: atime - long representing the time stamp atime_nano - long representing the nanoseconds. What I'd like to do is to have a python datetime object which will be a representati

Re: What are the kinds of software that are not advisable to be developed using Python?

2014-02-10 Thread Tim Daneliuk
On 02/10/2014 11:35 PM, Steven D'Aprano wrote: On Mon, 10 Feb 2014 22:40:48 -0600, Tim Daneliuk wrote: On 02/08/2014 05:54 PM, Sam wrote: I got to know about Python a few months ago and today, I want to develop only using Python because of its code readability. This is not a healthy bias. To p

Send commands to USB device in Python

2014-02-10 Thread Setia Budi
Hi fellows, I am facing difficulties in order to send USB commands to an RFID reader. This is the command reference of the device: https://github.com/mti-rfid/RFID_Explorer I am working with the MTI RU-824 model. The manufacturer of the device only provide a driver for Windows (using .Net), but

Re: PyWart: More surpises via "implict conversion to boolean" (and other steaming piles!)

2014-02-10 Thread Steven D'Aprano
On Mon, 10 Feb 2014 10:45:40 -0800, Rick Johnson wrote: > ## START CODE ### > def foo(): > # foo represents a patternless function Patternless? I have never heard that term before in this context. Do you mean a parameter-less or argument-less functio

Re: New to Py 3.3.3 having prob. with large integer div. float.

2014-02-10 Thread casevh
On Monday, February 10, 2014 6:40:03 PM UTC-8, hlauk.h...@gmail.com wrote: > I am coming off Python 2.6.6 32 bite platform and now in win 8.1 64 bite. > I had no problems with gmpy in 2.6.6 and large integer floating points where > you could control the length of the floating point by entering the

[RELEASED] Python 3.4.0 release candidate 1

2014-02-10 Thread Larry Hastings
On behalf of the Python development team, I'm delighted to announce the first release candidate of Python 3.4. This is a preview release, and its use is not recommended for production settings. Python 3.4 includes a range of improvements of the 3.x series, including hundreds of small improvemen