options for plotting points on geographic map

2011-09-28 Thread CM
Recommendations sought for using Python to plot points/custom markers (and maybe other things?) on a map of an area of the U.S. of maybe 100 miles radius. (This would be a "political" map showing towns, such as from Google Maps or Mapquest, and not a "physical" map). I'll need to place markers or

Re: options for plotting points on geographic map

2011-10-01 Thread CM
On Sep 29, 12:52 pm, Miki Tebeka wrote: > Probably the google maps routes will be faster (maybe using embedded webkit > window). However it requires internet connection. > > See alsohttp://www.scipy.org/Cookbook/Matplotlib/Maps Thanks. But I just needed a small radius, not the whole globe, and

Re: options for plotting points on geographic map

2011-10-01 Thread CM
> You could create the webpage and then render > it in your desktop app. I have seen plenty of apps like that. That's a good idea. I was able to get the basics of the pymaps approach going, so I may do just this. Thanks. -- http://mail.python.org/mailman/listinfo/python-list

best way to share an instance of a class among modules?

2013-02-05 Thread CM
I have recently moved all my SQLite3 database-related functions into a class, DatabaseAccess, that lives in a "utilities" module. When the application loads, the namespace of the instance of the class is populated with two different cursors for two different databases the whole application needs t

Re: best way to share an instance of a class among modules?

2013-02-06 Thread CM
On Feb 6, 12:04 am, Terry Reedy wrote: > On 2/5/2013 11:40 PM, CM wrote: > > > > > > > > > > > I have recently moved all my SQLite3 database-related functions into a > > class, DatabaseAccess, that lives in a "utilities" module.  When the >

Re: best way to share an instance of a class among modules?

2013-02-06 Thread CM
I was using self correctly, I think; but I should have said that the code in the importing module would be within a class, so self there refers to that class. But that's a side point. I agree that utilities.shared_cursor is visible within the importing module. But the problem below remains for m

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread CM
> The main issue is that python has dynamic typing.  The type of object > that is referenced by a particular name can vary, and there's no way > (in general) to know at compile time what the type of object "foo" is. > > That makes generating object code to manipulate "foo" very difficult. Could y

Re: pyqt4 & qt license

2013-03-09 Thread CM
On Mar 9, 9:08 pm, pitsa...@gmail.com wrote: > hello, > > i want to develop a GUI application that will be sold. > i want to use pyqt4. > can i download and use the GPL version during the development and then buy > the commercial verion beofore i distribute the application ? Arguably, yes. From

Time zone changing while Win app is running

2013-04-02 Thread CM
Although there is an answer to my concern posted on Stack Overflow[1], I thought I'd run this by the Python group to just get a read on it, since it strikes me as a concern. To summarize the issue: In an application, I have been using Python's datetime module to get the current time. But it seem

Re: Time zone changing while Win app is running

2013-04-03 Thread CM
> 2013-04-03 14:41:13.124000     < WRONG >                    ^ (That carrot is supposed to be pointing to the 4 in 14, which should be 18.) -- http://mail.python.org/mailman/listinfo/python-list

Re: Time zone changing while Win app is running

2013-04-03 Thread CM
On Apr 3, 7:37 am, Steven D'Aprano wrote: > On Tue, 02 Apr 2013 17:04:12 -0700, CM wrote: > > To summarize the issue:  In an application, I have been using Python's > > datetime module to get the current time.  But it seems that, at least > > with Windows (XP), what

Re: Time zone changing while Win app is running

2013-04-03 Thread CM
> >> I am not the maintainer of the datetime module, but based purely on what > >> you have said, I would consider that a bug. > > I don't. Do you really want every time function slowed by > re-initializing the timezone? It depends; do you know what re-initializing entails and how costly that wo

Re: IDE for GUI Designer

2013-04-04 Thread CM
On Apr 4, 11:41 am, Renato Barbosa Pim Pereira wrote: > Guys, is this, I wonder if there is an IDE with native support for the > development of GUI's such as Netbeans with Swing, Visual Basic, etc., The term you want to use is "GUI Builder". Because there can be IDEs without a GUI builder. You

Pythonic way to count sequences

2013-04-24 Thread CM
I have to count the number of various two-digit sequences in a list such as this: mylist = [(2,4), (2,4), (3,4), (4,5), (2,1)] # (Here the (2,4) sequence appears 2 times.) and tally up the results, assigning each to a variable. The inelegant first pass at this was something like... # Create na

Re: Pythonic way to count sequences

2013-04-25 Thread CM
Thank you, everyone, for the answers. Very helpful and knowledge- expanding. -- http://mail.python.org/mailman/listinfo/python-list

Re: wxFormBuilder

2008-03-22 Thread CM
On Mar 20, 9:41 am, sturlamolden <[EMAIL PROTECTED]> wrote: > I just discovered wxFormBuilder. After having tried several GUI > builders for wx (including DialogBlocks, wxGlade, XRCed,Boa > constructor), this is the first one I can actually use. Why can't you use Boa Constructor? I really enjoy u

Re: wxPython/wxWidgets ok for production use ?

2008-03-22 Thread CM
On Mar 10, 3:27 pm, Stef Mientki <[EMAIL PROTECTED]> wrote: > Stefan Behnel wrote: > > Malcolm Greene wrote: > > >>> My personal experience with wxPython has its ups and downs. Specifically > >>> when it comes to crashes, I wouldn't bet my life on it. > > >> I'm new to Python and getting ready to b

Re: Invoking CutePDF from within Python

2009-02-13 Thread cm
Hi John, All I need is to say "Print this to CUTEPDF and store as xyz.pdf". I can't answer you question but let me make a suggestion: Try PdfCreator. It lets you control all the process using an activex control. It has events to tell you when the jobs has finish, or report you of eventual erro

Re: wxpython for python 3.0 ?

2008-12-22 Thread CM
On Dec 21, 4:42 pm, dlemper wrote: > The wxpython web describes compatability with python 2.4 & 2.5 . > Does it work with 3.0 ?   If not, anyone have a clue as to when ? Not yet. I think it will be a while until then. -- http://mail.python.org/mailman/listinfo/python-list

Re: Determining from which web page a cgi script is invoked?

2009-03-10 Thread cm
davidgo...@davidgould.com escribió: Given a webpage test.html that has a form with a cgi script, how can you determine inside the cgi script the name of the webpage that invoked the script? I have many different html pages that use a common cgi script for form processing and want to determine th

Re: strange problem with Py2exe

2009-03-11 Thread CM
On Mar 11, 10:37 am, sf409...@gmail.com wrote: > Hello all, > in the past I've used Py2exe without any problem, but now I have this > strange difficulty. > In my computer I have  python 2.6,  py2exe for python 2.6 and the > distutils, but when I do: > > from distutils.core import setup > import py2

Re: How to add months to a date (datetime object)?

2009-03-15 Thread CM
On Mar 15, 1:28 pm, tinn...@isbd.co.uk wrote: > I have a date in the form of a datetime object and I want to add (for > example) three months to it.  At the moment I can't see any very > obvious way of doing this.  I need something like:- > >     myDate = datetime.date.today() >     inc = datetime.

Re: What is the best framework or module in Python for a small GUI based application development?

2009-04-24 Thread CM
On Apr 22, 9:11 am, srinivasan srinivas wrote: > Hi, > Could you suggest me some modules in Python which can be used to develop GUI > based applications? and tell me which could be the best(in terms of > efficiency) one for a small GUI based application development? > > Thanks, > Srini > >      

Re: wxPython having trouble with frame objects

2009-04-30 Thread CM
On Apr 30, 9:54 pm, Soumen banerjee wrote: > Hello, > I am using wxglade to design a gui which i am using in another script. > Here are the codes > > The main file: > import wx,gui,threading > class guithread(threading.Thread): >    def run(self): >        app = wx.PySimpleApp(0) >        wx.InitA

Re: Most Basic Question Ever - please help

2009-05-02 Thread CM
On May 2, 4:36 pm, seanm...@gmail.com wrote: > I am going to try posting here again with more detail to see if I can > finally get my first program to work. > > I am working on a MacBook Pro with OS X 10.4.11. I opened a new window > in IDLE to create a file. The file had only one line of code and

Re: When *don't* I use 'self' in classes?

2009-05-13 Thread CM
On May 13, 6:36 pm, "Adam Gaskins" wrote: > I am a bit confused as too when, if ever, it is not appropriate to prepend > 'self' to objects in a class. All of the examples of how to use 'self' that > I find seem to be short and very simple (as examples tent to be). I > appologize if I am asking an

Re: Learning Python for no reason

2008-05-12 Thread CM
On May 12, 1:27 pm, "John Salerno" <[EMAIL PROTECTED]> wrote: > Just something that crosses my mind every time I delve into "Learning > Python" each night. Does anyone see any value in learning Python when you > don't need to for school, work, or any other reason? I mean, sure, there's > value in l

Re: Needing python experts to help with a problem

2008-06-06 Thread CM
On Jun 7, 12:51 am, gms <[EMAIL PROTECTED]> wrote: > Hello, > I have the following list: > > [{'count': u'2', 'manu': }, {'count': u'4', > 'manu': }, {'count': u'2', 'manu': Manu3>}, {'count': u'2', 'manu': }] > > My current list currently contains four dictionaries. They are: > > {'count': u'2',

Re: How to close app after x seconds.

2008-06-08 Thread CM
On Jun 8, 8:51 pm, ralphz <[EMAIL PROTECTED]> wrote: > Hi > > I have small app that I want to close tself after x seconds. Basically > start show some message and close. > > I come up with something like this but it does not work. Can anyone help > me with it? > > #!/usr/bin/env python > > import w

Re: Write to file and see content on screen

2008-06-09 Thread CM
On Jun 9, 9:01 pm, [EMAIL PROTECTED] wrote: > Hello all, > > New user to python. I can write to a file, however, I would like to > do both...whatever I do on the screen, I'd like to write it to a file. > > any pointers on where I can find this info. > > thanks, There is probably some smart way t

Re: Python-by-example - new online guide to Python Standard Library

2008-04-02 Thread CM
On Apr 2, 2:50 pm, AK <[EMAIL PROTECTED]> wrote: > Terry Reedy wrote: > > "AK" <[EMAIL PROTECTED]> wrote in message > >news:[EMAIL PROTECTED] > > > || I'll be glad to hear comments/suggestions/etc: > > | > > |http://www.lightbird.net/py-by-example/ > > > Using - as the example/return delimiter does

Re: Learning curve for new database program with Python?

2008-04-06 Thread CM
On Apr 5, 11:50 am, Jetus <[EMAIL PROTECTED]> wrote: > I have a need for a database program. I downloaded the db2 from ibm, > and reviewed some of the documentation. > > My question is, what is the easiest program for me to try to learn. I > will be creating a database of about 25,000 records, it w

Re: Learning curve for new database program with Python?

2008-04-06 Thread CM
On Apr 5, 11:50 am, Jetus <[EMAIL PROTECTED]> wrote: > I have a need for a database program. I downloaded the db2 from ibm, > and reviewed some of the documentation. > > My question is, what is the easiest program for me to try to learn. I > will be creating a database of about 25,000 records, it w

Re: Learning curve for new database program with Python?

2008-04-07 Thread CM
On Apr 7, 1:19 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > On 7 avr, 07:34, CM <[EMAIL PROTECTED]> wrote: > > > > > On Apr 5, 11:50 am, Jetus <[EMAIL PROTECTED]> wrote: > > > > I have a need for a database program. I d

Re: Converting a tuple to a list

2008-04-08 Thread CM
On Apr 8, 6:46 pm, "Gabriel Ibanez" <[EMAIL PROTECTED]> wrote: > Gabriel Ibanez wrote: > > Hi all .. > > > I'm trying to using the map function to convert a tuple to a list, without > > success. > > > I would like to have a lonely line that performs the same as loop of the > > next script: > > > --

Re: How is GUI programming in Python?

2008-04-09 Thread CM
On Apr 9, 9:54 pm, Chris Stewart <[EMAIL PROTECTED]> wrote: > I've always had an interest in Python and would like to dabble in it > further. I've worked on a few very small command line programs but > nothing of any complexity. I'd like to build a really simple GUI app > that will work across Ma

Re: How is GUI programming in Python?

2008-04-11 Thread CM
On Apr 11, 3:29 pm, Rune Strand <[EMAIL PROTECTED]> wrote: > On Apr 11, 8:35 pm, Steve Holden <[EMAIL PROTECTED]> wrote: > > > wxDesigner. > > Yeah, but it's like Heron of Alexandria's Aeolipile compared to the > steam engine of James Watt. > > IMHO, GUI with Python is pain, pain and utter pain. Ev

Re: where do I begin with web programming in python?

2008-05-02 Thread CM
On May 2, 10:18 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > On May 2, 10:07 am, bvidinli <[EMAIL PROTECTED]> wrote: > > > > > i also asked same question in this list last week. > > i foundhttp://www.cherrypy.org/tobe most suitable for me. > > it is basic, easy, pure... > > it contains its

Re: Are rank noobs tolerated, here?

2008-05-04 Thread CM
On May 4, 7:45 pm, notbob <[EMAIL PROTECTED]> wrote: > I'm trying to learn how to program. I'm using: > > How to Think Like a Computer Scientist > > Learning with Python > 2nd Edition > > Am I likely to receive any help, here, or is there another irc, forum, etc, > that might better serve a comple

firefox add-on to grab python code handily?

2008-05-10 Thread CM
I encounter a fair number of small Python scripts online, and usually try them out by copying them to the clipboard, pasting into Notepad, saving them, and either running them directly or opening them in IDLE. And so I was wondering if anyone knew of an extension/add-on/script for Firefox which wo

Re: GUI for multiplatform multimedia project

2010-01-07 Thread CM
On Jan 6, 4:53 pm, wrote: > Hi everyone, > > I posted that question on a python-forum, but got answer, so I ask here. > > I'm working on an artistic project and I'm looking for the best > cross-platform GUI solution. The problem is that it's gonna be a tool that > will have to be double-click inst

Re: Simple distributed example for learning purposes?

2010-01-14 Thread CM
On Dec 26 2009, 3:46 pm, Shawn Milochik wrote: > The special features of the Shrek DVD showed how the rendering took so much > processing power that everyone's workstation was used overnight as a > rendering farm. Some kind of video rendering would make a great example. > However, it might be a

Re: Sikuli: the coolest Python project I have yet seen...

2010-01-26 Thread CM
On Jan 24, 10:18 pm, Ron wrote: > Sikuli is the coolest Python project I have ever seen in my ten year > hobbyist career. An MIT oepn source project, Sikuli uses Python to > automate GUI tasks (in any GUI or GUI baed app that runs the JVM) by > simply drag and dropping GUI elements into Python scr

Re: "Hello, world"?

2009-10-28 Thread CM
On Oct 28, 5:40 am, Gilles Ganault wrote: > Hello > > I'm reading O'Reily's "Python Programming on Win32", but couldn't find > a simple example on how to create a window with just a label and > pushbutton. > > If someone has such a basic example handy, I'm interested. > > Thank you. In wxPython (

Re: A beginner question about GUI use and development

2009-11-13 Thread CM
On Nov 13, 3:55 am, uap12 wrote: > Hi! > I have written som Python programs but no one with a GUI yet, > i have look around and found a lot of diffrent gui module. > > I will develop program that will use a small amout of GUI part > eg. program to show status about server etc. > > I have looked at

Re: python gui builders

2009-11-17 Thread CM
On Nov 16, 5:06 am, me wrote: > Good People > > I do not write stuff for humans, as it has been my job to remove > humans from the loop. But I have to make a front end to a > component database where everything was built in Python. > > I have looked at the Tk stuff that is built into Python -> not

Re: Background Zones in Pylab Plot

2010-02-03 Thread CM
On Feb 3, 10:49 am, Wanderer wrote: > I would like to add background zones in pylab plots. Colored sections > of the background that the curves pass through. Is this possible? My > google searches don't turn up anything but maybe my search terms > aren't the right ones. > > Thanks If you look at

Re: Your beloved python features

2010-02-05 Thread CM
> GvR got it right when he discarded the superfluous semicolons from the ends > of statements--and then he ADDS superfluous colons to the ends of control > statements? It will probably be as much of a shock to you as it was to me > when I learned after studying parsing that colons, semicolons, "th

Re: Upgrading Py2exe App

2010-02-18 Thread CM
On Feb 18, 7:19 pm, Ryan Kelly wrote: > On Thu, 2010-02-18 at 07:46 -0800, T wrote: > > I have a Python app which I converted to an EXE (all files separate; > > single EXE didn't work properly) via py2exe - I plan on distributing > > this and would like the ability to remotely upgrade the program

Re: The Disappearing Program?

2010-02-19 Thread CM
On Feb 19, 12:21 pm, "W. eWatson" wrote: > On 2/19/2010 7:16 AM, Mark Lawrence wrote:> Andre Engels wrote: > >> On Fri, Feb 19, 2010 at 3:19 PM, Mark Lawrence > >> wrote: > >>> Andre Engels wrote: > On Fri, Feb 19, 2010 at 12:20 PM, W. eWatson > > ... > tories, or even the whole hard drive,

Re: Upgrading Py2exe App

2010-02-19 Thread CM
On Feb 19, 4:28 pm, Ryan Kelly wrote: > On Thu, 2010-02-18 at 20:32 -0800, CM wrote: > > On Feb 18, 7:19 pm, Ryan Kelly wrote: > > > On Thu, 2010-02-18 at 07:46 -0800, T wrote: > > > > I have a Python app which I converted to an EXE (all files separate; > >

Re: The Disappearing Program?

2010-02-19 Thread CM
On Feb 19, 4:42 pm, "W. eWatson" wrote: > On 2/19/2010 10:56 AM, CM wrote: > > > On Feb 19, 12:21 pm, "W. eWatson"  wrote: > >> On 2/19/2010 7:16 AM, Mark Lawrence wrote:>  Andre Engels wrote: > >>>> On Fri, Feb 19, 2010 at 3:19 P

Re: What's the word on using """ to comment-out?

2010-02-24 Thread CM
> After all, from what I've seen since then, the practice of > triple-quote-commenting (or TQC, pardon the TCA) is in fact quite > common. > > Is TQC OK after all? > > If not, what's the case against it? I have no sense of how approved it is, and don't have a strong opinion on it, but I would thin

Re: Dictionary or Database—Please advise

2010-02-26 Thread CM
On Feb 26, 10:58 am, Jeremy wrote: > I have lots of data How much is "lots"? > that I currently store in dictionaries.  However, > the memory requirements are becoming a problem.  I am considering > using a database of some sorts instead, but I have never used them > before.  Would a databas

Re: Converting HTML to PDF using Python?

2010-03-08 Thread CM
On Mar 8, 10:36 am, Oltmans wrote: > Hi Python superstars, > > Guys, any ideas on how to convert HTML files to PDF files? Or as an > alternative, how to convert HTML files to an image file(jpeg/png/etc)? > Ideally, the converted PDF/Image file should like exactly like the way > HTML file looks in

Re: Need advice on starting a Python group

2010-03-12 Thread CM
On Mar 11, 9:57 am, gb345 wrote: > I'm hoping to get advice from anyone with prior experience setting > up a Python group. > > A friend of mine and I have been trying to start a > scientific-programming-oriented Python group in our school (of > medecine and bio research), with not much success. >

Re: python to exe

2010-03-14 Thread CM
On Mar 14, 4:04 pm, David Monaghan wrote: > On Sun, 14 Mar 2010 13:10:32 -0600, John Bokma wrote: > >David Monaghan writes: > > >> of Google. If they haven't used it, I don't really consider the gentle > >> reminder that LMGTFY gives too harsh. If you do, you're too much of a > >> gentle > >> s

Re: SQLite date fields

2010-11-25 Thread CM
> However, when it comes to writing-back data to the table, SQLite is very > forgiving and is quite happy to store '25/06/2003' in a date field, but > this is not ideal because a) I could be left with a mixture of date > formats in the same column,  b) SQLite's date functions only work with > ISO f

Re: Which non SQL Database ?

2010-12-04 Thread CM
On Dec 4, 6:43 pm, Jorge Biquez wrote: > At 05:02 p.m. 04/12/2010, you wrote: > > > > >Jorge Biquez writes: > > > > Hello all. > > > > Newbie question. Sorry. > > > > As part of my process to learn python I am working on two personal > > > applications. Both will do it fine with a simple structur

Re: Which non SQL Database ?

2010-12-06 Thread CM
On Dec 6, 2:17 am, Steve Holden wrote: > On 12/5/2010 12:59 AM, CM wrote: > > > SQlite itself is around 300 kilobytes.  That's negligible.  It is also > > already in Python, so you'd have to purposefully exclude it in > > creating your executable to save tho

Re: Which non SQL Database ?

2010-12-06 Thread CM
> You're also confusing MB/s (bytes) with Mb/s (bits). Yes I am. I think I will now recuse myself from the proceedings... -- http://mail.python.org/mailman/listinfo/python-list

Re: Tkinter: The good, the bad, and the ugly!

2011-01-01 Thread CM
Rantingrick, Find a closet in your home, go inside, turn off the lights, and shout into a thermos; that will likely have a similar result as these posts on the state of GUI libraries in Python. There is something admirable about the FOSS philosophy of "You want it? You make it". And I don't see

Re: Tkinter: The good, the bad, and the ugly!

2011-01-02 Thread CM
On Jan 1, 7:39 pm, rantingrick wrote: > On Jan 1, 5:39 pm, CM wrote: > > > And I don't see this as a problem anyway.  I wanted to do GUI > > programming in Python, so I read a bit, chose wxPython, downloaded it, > > and started learning it.  Done. > > I, I, I

Re: documentation / reference help

2011-01-23 Thread CM
On Jan 23, 2:38 pm, "Littlefield, Tyler" wrote: > The return value simply returns a value to the calling function, which > the function can handle, however it wants. so: for example > def add(a, b): >    return (a+b) > > That simply returns the value a+b, which you can use however you like, > like

A and B but not C in list

2011-01-23 Thread CM
In Python, is there a recommended way to write conditionals of the form: "if A and B but not C or D in my list, do something." ? I may also have variations on this, like "if A but not B, C, or D". Do I have to just write out all the if and elifs with all possible conditions, or is there a handi

Re: WxPython versus Tkinter.

2011-01-25 Thread CM
On Jan 25, 10:13 am, Nicholas Devenish wrote: Nicholas, > I think even more damaging to any python newcomers than choosing the > 'wrong' gui toolkit would be stumbling across this thread whilst looking > for a toolkit; and thinking some of the behaviour here was > representative of the python (o

Re: WxPython versus Tkinter.

2011-01-25 Thread CM
On Jan 25, 2:33 pm, geremy condra wrote: > On Tue, Jan 25, 2011 at 11:16 AM, CM wrote: > > Another interesting issue in this is mobile phone app development.  It > > is frustrating to devote a lot of time to learning a desktop widget > > toolkit and Python and while that is

Re: A and B but not C in list

2011-01-28 Thread CM
Thanks, everyone, for your suggestions. -Che -- http://mail.python.org/mailman/listinfo/python-list

Re: Updated License Term Agreement for VC Redistributable in VS 2008 SP1

2010-04-16 Thread CM
On Apr 16, 3:31 am, Tim Roberts wrote: > Andrej Mitrovic wrote: > > >I don't think this license agreement change involves the express > >editions, which are free. Correct me if I'm wrong here? > > The license agreement change fixes a problem that was accidentally > introduced by Visual Studio 200

Re: wxPython problem: Can't assign size of plot.PlotCanvas

2010-04-28 Thread CM
On Apr 28, 9:13 am, "Kaipo ch...@taiwan" wrote: > I wrought something like > client = plot.PlotCanvas(childFrame2, 2,pos=(300,400),size=(100,200), > name=text1) > But the plotcanvas kept filling all the childFrame. > Is there a way to Really adjust the size of ploscanvas? > Thanks in advance for y

Re: Teaching Programming

2010-05-03 Thread CM
> Nobody likes indentation at first, it is different.   For what it's worth, I didn't have a programming background, and I liked Python's indentation right from the start. I was used to thinking in terms of indentation from writing and word processing documents with subordinate sections, so I fo

Re: Human word reader

2010-05-16 Thread CM
> > I need help with getting the useful information how do I get the place > > if I don't now how long the string is? > >         And is it supposed to handle > >         for london give the weather to me >         for the london weather give me > > ... > >         Do a search on "natural language

Re: Human word reader

2010-05-16 Thread CM
On May 16, 2:57 pm, CM wrote: > > > I need help with getting the useful information how do I get the place > > > if I don't now how long the string is? > > >         And is it supposed to handle > > >         for london give the weather to me &

Re: help need to write a python spell checker

2010-05-19 Thread CM
I love how he just copied and pasted the assignment without any other remarks. -- http://mail.python.org/mailman/listinfo/python-list

validate string representation of a timedelta

2010-06-28 Thread CM
I'm looking for a good way to check whether a certain string is valid. It is a string representation of a Python timedelta object, like this: '0:00:03.695000' (But the first place, the hours, could also be double digits) In trying to figure out how to validate that, I saw this page which create

Re: validate string representation of a timedelta

2010-06-29 Thread CM
On Jun 29, 8:00 am, Thomas Jollans wrote: > On 06/29/2010 03:41 AM, CM wrote: > > > > > I'm looking for a good way to check whether a certain string is > > valid.  It is a string representation of a Python timedelta object, > > like this:  '0:00:03.69500

Re: git JSONRPC web service and matching pyjamas front-end

2010-06-29 Thread CM
On Jun 29, 6:54 pm, Luke Kenneth Casson Leighton wrote: > as more than just a proof-of-concept but to get pyjamas out of looking > like "a nice toy, doesn't do much, great demos, shame about real > life", i've created yet another git repository browser.  this one, > thanks to pyjamas, obviously ru

Re: git JSONRPC web service and matching pyjamas front-end

2010-06-30 Thread CM
On Jun 30, 4:27 am, "Martin P. Hellwig" wrote: > On 06/30/10 03:29, CM wrote:> On Jun 29, 6:54 pm, Luke Kenneth Casson > Leighton > > wrote: > >> as more than just a proof-of-concept but to get pyjamas out of looking > >> like "a nice toy, doesn&#x

Re: python app development

2010-07-04 Thread CM
On Jul 3, 1:48 pm, mo reina wrote: > an anyone recommend a resource (book,tutorial,etc.) that focuses on > application development in python? something similar to Practical > Django Projects, but for stand alone applications instead of web apps > (for now). > > i'm in a bit of a funny place, i hav

Re: Python 3 put-downs: What's the point?

2010-07-04 Thread CM
On Jul 4, 7:14 pm, Terry Reedy wrote: > I think there's a good point to Python 3 put-downs (if I take put-down to mean generally reasonable criticism, which is what I've read here recently, and not trolling). And that is simply to register dissent. Any online group is an opportunity to register

Re: Python 3 put-downs: What's the point?

2010-07-05 Thread CM
On Jul 5, 2:33 pm, Terry Reedy wrote: > On 7/4/2010 9:20 PM, CM wrote: > > > On Jul 4, 7:14 pm, Terry Reedy  wrote: > > > I think there's a good point to Python 3 put-downs (if I take put-down > > to mean generally reasonable criticism, which is what I've rea

Re: any issues with long running python apps?

2010-07-12 Thread CM
On Jul 12, 1:16 pm, John Nagle wrote: > On 7/12/2010 7:19 AM, Grant Edwards wrote: > > > On 2010-07-09, Les Schaffer  wrote: > > >> i have been asked to guarantee that a proposed Python application will > >> run continuously under MS Windows for two months time. And i am looking > >              

Re: any issues with long running python apps?

2010-07-12 Thread CM
> >      Yesterday, I was running a CNC plasma cutter that's controlled > > by Windows XP.  This is a machine that moves around a plasma torch that > > cuts thick steel plate.  A "New Java update is available" window > > popped up while I was working.  Not good. > > Hi, it looks like you're attem

exception handling with sqlite db errors

2010-08-01 Thread CM
I am using SQLite with Python 2.5 for an app and every now and then get an error when trying to write to the database. So far I haven't been careful about noting these down, but now I would like to address them. The two errors I've noticed are: 1) "database is locked" errors (probably due to wri

Re: Python Portability--Not very portable?

2010-08-06 Thread CM
On Aug 5, 9:50 pm, "W. eWatson" wrote: > In my on-again-off-again experience with Python for 18 months, > portability seems an issue. > > As an example, my inexperienced Python partner 30 miles away has gotten > out of step somehow. I think by installing a different version of numpy > than I use.

Re: Python Portability--Not very portable?

2010-08-06 Thread CM
> As an example, my inexperienced Python partner 30 miles away has gotten > out of step somehow. I think by installing a different version of numpy > than I use. I gave him a program we both use months ago, and he had no > trouble. (We both use IDLE on 2.5). I made a one character change to it > an

Re: Python "why" questions

2010-08-07 Thread CM
> Apparently, the Japanese used to (before they started adopting western > conventions). I.e. ages were given as "in his tenth year" (meaning nine > years old). Koreans still do this. The day a child is born it is "one". Even odder to me, the next birthday is not on the next anniversary of the

Re: GUI automation tool (windows)

2010-08-11 Thread CM
On Aug 9, 8:10 am, Alex Barna wrote: > I know that this question has been asked for several times, but it > surprises that there is no tool under very active development and the > community activities are very low (mailing list posts). > > All the tools listed in: > > http://pycheesecake.org/wiki/

Re: exception handling with sqlite db errors

2010-08-18 Thread CM
On Aug 12, 3:31 pm, a...@pythoncraft.com (Aahz) wrote: > In article > <2a47b306-45d1-474a-9f8e-5b71eba62...@p11g2000prf.googlegroups.com>, > > CM  wrote: > > >Maybe it's not much of an issue, but I think it would be a shame if > >occasional hangs/crashes cou

launch a .py file from a batch file

2009-06-22 Thread CM
I'd like to launch a number of programs, one of which is a Python GUI app, from a batch file launcher. I'd like to click the .bat file and have it open all the stuff and then not show the "DOS" console. I can launch an Excel and Word file fine using, e.g.: Start "" "path/mydocument.doc" But if I

Re: GUibuilder evaluation

2010-09-06 Thread CM
On Sep 6, 3:54 am, Niklasro wrote: > Hello > Making a GUI, could you recommend tkinter or any other proposal? > Thanks Your message referred to a GUI *builder*, whereas tkinter is a GUI *toolkit* (that is, a collection of widgets). A builder is an application that allows you to make GUI apps mor

Re: GUibuilder evaluation

2010-09-06 Thread CM
On Sep 6, 3:54 am, Niklasro wrote: > Hello > Making a GUI, could you recommend tkinter or any other proposal? > Thanks Your message referred to a GUI *builder*, whereas tkinter is a GUI *toolkit* (that is, a collection of widgets). A builder is an application that allows one to make GUI apps mor

Re: GUibuilder evaluation

2010-09-06 Thread CM
On Sep 6, 3:54 am, Niklasro wrote: > Hello > Making a GUI, could you recommend tkinter or any other proposal? > Thanks Your message referred to a GUI *builder*, whereas tkinter is a GUI *toolkit* (that is, a collection of widgets). A GUI builder is an application that allows one to make GUI apps

Re: are there pros or contras, keeping a connection to a (sqlite) database ?

2010-09-08 Thread CM
On Sep 8, 1:09 pm, Stef Mientki wrote: >  hello, > > I wrap my database in some class, and on creation of the instance, a > connection to the database is > created, > and will stay connected until the program exists, something like this: > >     self.conn = sqlite3.connect ( self.filename ) > > N

Re: are there pros or contras, keeping a connection to a (sqlite) database ?

2010-09-09 Thread CM
On Sep 9, 4:41 am, News123 wrote: > On 09/09/2010 12:29 AM, CM wrote: > > > On Sep 8, 1:09 pm, Stef Mientki wrote: > >>  hello, > > >> I wrap my database in some class, and on creation of the instance, a > >> connection to the database is > >&

Re: Distribute Non Library

2010-09-12 Thread CM
On Sep 11, 11:10 pm, narke wrote: > My simple tool writing in python get bigger and bigger and I think I'd > better split my code into several files.  But, unlike what in some other > languages, there is no way to compile these several files into a single > executable. Sure there is. py2exe, py2

Re: develop for Windows on GNU/Linux, using Python

2010-09-20 Thread CM
On Sep 20, 12:46 pm, Thomas Jollans wrote: > On Monday 20 September 2010, it occurred to Default User to exclaim: > > > > > On Sun, Sep 19, 2010 at 14:31, J.O. Aho wrote: > > > Kev Dwyer wrote: > > > > if you have C-extensions in > > > > your code you'll need to compile them over Windows.  If you

Re: Auto size wx.StaticText

2010-09-22 Thread CM
On Sep 22, 2:38 pm, Grant Edwards wrote: > On 2010-09-22, Dani Valverde wrote: > > > Is there a way to automatically set the size of a wx.StaticText to fit > > its content? > > According to the docs, it should do that by default: > >    http://xoomer.virgilio.it/infinity77/wxPython/Widgets/wx.Sta

Re: Question regarding python2.5 migration from windows xp to windows 7

2010-10-14 Thread CM
On Oct 14, 2:37 am, python_tsp wrote: > Hi, > > We have a Python based test framework which is being used in various > projects. > > Our current environment is > Python (ver 2.5.1) > wxPython (wxPython2.8-win32-ansi-2.8.6.0-py25) > pywin32-210.win32-py2.5 > vcredist_x86.exe > pyserial-2.2 > > Our

<    1   2