help install on Win 7

2018-06-28 Thread Andrew von Bevern
I have tried to install python on my home laptop several times, using 3.6 or 3.7. Each time I get the following error - anyone know what I am doing wrong? [image: image.png] thanks in advance Andrew -- https://mail.python.org/mailman/listinfo/python-list

Re: New user's initial thoughts / criticisms of Python

2013-11-09 Thread John von Horn
On Sat, 09 Nov 2013 07:08:25 -0600, John von Horn wrote: Thanks so much for the replies. I'll get my head down and keep on going. Sometimes it's great to be wrong. I have a good feeling about this language. It's also nice that I can tap into this pool of knowledge that is c

New user's initial thoughts / criticisms of Python

2013-11-09 Thread John von Horn
Hi Everyone, I'm Mr. Noobie here, I've just started easing into Python (2.7.4) and am enjoying working along to some youtube tutorials. I've done a little programming in the past. I've just got a few thoughts I'd like to share and ask about: * Why not allow floater=float(int1/int2) - rather th

Re: io.BytesIO

2013-03-25 Thread Fabian von Romberg
use io.BufferedWriter instead. Just one question, what has better performance: BufferedWriter or BytesIO? Thanks and regards, Fabian On 03/25/2013 01:54 AM, Steven D'Aprano wrote: > On Mon, 25 Mar 2013 00:10:04 -0500, Fabian von Romberg wrote: > >> Hi Steven, >> >>

Re: io.BytesIO

2013-03-24 Thread Fabian von Romberg
attribute or method? Regards, Fabian On 03/24/2013 11:47 PM, Steven D'Aprano wrote: > On Sun, 24 Mar 2013 22:56:12 -0500, Fabian von Romberg wrote: > >> Hi, >> >> is there any way to get the allocated memory size from a io.BytesIO >> object? > > The same a

io.BytesIO

2013-03-24 Thread Fabian von Romberg
Hi, is there any way to get the allocated memory size from a io.BytesIO object? Thanks and regards, Fabian -- http://mail.python.org/mailman/listinfo/python-list

Re: import in Python3.3

2013-03-24 Thread Fabian von Romberg
Hi Steven, thanks a lot for the explanation. I will keep in mind not to use names for my modules that can shadow the standard library. Regards, Fabian On 03/24/2013 07:27 PM, Steven D'Aprano wrote: > On Sun, 24 Mar 2013 18:12:49 -0500, Fabian von Romberg wrote: > >> H

import in Python3.3

2013-03-24 Thread Fabian von Romberg
Hi, I have a package name collections and inside of my package I want to import the collections package from the standard library, but there is name conflicts. How do I import explicitly from the standard library? Im working on Python3.3 Thanks in advance and regards, Fabian -- http://mail.p

addressof object with id()

2013-03-23 Thread Fabian von Romberg
Hi, I have a single questions regarding id() built-in function. example 1: var1 = "some string" var2 = "some string" if use the id() function on both, it returns exactly the same address. example 2: data = "some string" var1 = data var2 = data if use the id() function on var1 and var2, it r

Re: asyncore.poll() question

2010-10-17 Thread Von
The urlparse module is load only when this module run as main entry. Its for test purpose of modules. 2010/10/17, chad : > On Oct 16, 11:02 am, Felipe Bastos Nunes > wrote: >> You edited the source of asyncore.py puttin the print statments and >> nothing happend? It should work as the method is

Re: I don't get why sys.exit(1) doesn't exit the while loop in the follow case

2010-10-04 Thread Von
Try to use sys.exit(0) Maybe you should print out the error in your except block. 2010/10/5, chad : > Given the following.. > > #!/usr/bin/python > > import urllib2 > import sys > import time > > while 1: > try: > con = urllib2.urlopen("http://www.google.com";) > data = con.re

Re: python call a procedure at the specified time

2010-09-15 Thread Von
time, you can schedule it for the > same > > if you need any help, ping on gtalk, can help you out > > Thanks, > Nitin > > On Wed, Sep 15, 2010 at 1:05 PM, Von wrote: > >> I have read the cron man page just now,It says that cron wakes up every >> minute to

python cxfreeze package pyqt app lost icon and tray icon

2010-09-15 Thread Von
Hi, Here is my command: cxfreeze --target-dir=AutoOrder gui.py --base-name=D:\Python31\Lib\site-packages\cx_Freeze\bases\Win32GUI.exe --include-path=. -z icon.jpg Both app icon and tray icon used icon.jpg Regards, -- http://mail.python.org/mailman/listinfo/python-list

Re: python call a procedure at the specified time

2010-09-15 Thread Von
I have read the cron man page just now,It says that cron wakes up every minute to check task. I will try install/uninstall with cron. Cheers, On Wed, Sep 15, 2010 at 3:25 PM, Von wrote: > Thanks Nitin,I wonder how cron works,does it create a timer thread for each > task? > > >

Re: python call a procedure at the specified time

2010-09-15 Thread Von
a day or say timely manner daemon will > be a costly affair for system resources > > To schedule crons for python, this might be useful (using yaml) > > http://code.google.com/appengine/docs/python/config/cron.html#About_cron_yaml > > Thanks, > Nitin > > > On

Re: python call a procedure at the specified time

2010-09-14 Thread Von
Hi Nitin,I need a python solution for that. On Wed, Sep 15, 2010 at 2:15 PM, Nitin Pawar wrote: > are you looking for something like cron? > > On Wed, Sep 15, 2010 at 11:43 AM, Von wrote: > >> Hi, >> I have a python script running behind the scene,and I need it to call

python call a procedure at the specified time

2010-09-14 Thread Von
Hi, I have a python script running behind the scene,and I need it to call a method on sunday 9 o'clock. I get an idea,that I get the current time,and calculate the seconds to sunday 9 o'clock, then sleep these seconds and call my method,I think there could be an elegant way to resolve this. Regard

python tkinter Listbox

2010-09-14 Thread Von
Hi all, I am building a simple tool using tkinter,and need multiselection checklist.I find that Listbox with option selectmode=tkinter.MULTIPLE could do this for me. But when I have two Listboxs,I do some selection with one,then do selection with another one,the previous listbox get cleared.I wo

Re: python datetime

2010-09-14 Thread Von
= next - now > > #delta is datetime.timedelta type. > #(You can extract days diff) > > # Determine date in 7 days > import datetime > now = datetime.date(2010, 9, 28) > delta = datetime.timedelta(days=7) > next = now + delta > > > > > > > > > &

python datetime

2010-09-14 Thread Von
Hi, How to determine a date is just the 7th day after today ie: today is 14 Sep the 7th day is 14+7 = 21,but assume today is 28 Sep the 7th day is 5 Oct,is there simple way to do this work? I wish I explained clear Bests, -- http://mail.python.org/mailman/listinfo/python-list

Help with suds: HTTP Error 401

2010-06-11 Thread Eric von Horst
Hi, I am trying to do a very simple thing with SUDS but I think I am missing the obvious (first time I use suds) I have small program that tries to open a wsdl. When I execute the program I am getting 'suds.transport.TransportError: HTTP Error 401: Unauthorized' Seems obvious but I specify userna

Looking for documentation tools

2009-10-01 Thread Esben von Buchwald
Hello. For documening my thesis project, i'm, looking for 2 things: A GUI tool that allows me to enter descriptions, arguments, return values etc, for each function, class, etc. in some forms and then generates and inserts the correct comment syntax, so pydoc can generate the documentation H

Re: Collection console output

2009-09-17 Thread Esben von Buchwald
MRAB wrote: Esben von Buchwald wrote: Hello Are there any simple ways to collect the data, python prints to the console when running an app? I'm doing som apps for S60 mobile phones and can't see the console, when the UI is running, but i'd like to collect the output, to loo

Collection console output

2009-09-16 Thread Esben von Buchwald
Hello Are there any simple ways to collect the data, python prints to the console when running an app? I'm doing som apps for S60 mobile phones and can't see the console, when the UI is running, but i'd like to collect the output, to look for eventual exceptions etc. Cant it be redirected

Re: Protecting against callbacks queuing up?

2009-08-28 Thread Esben von Buchwald
It seems to solve the problem. What I did: def contextDataHandler(self): self.contextdata.process_busy=True self.services.findServices() self.drawDisplay() self.contextdata.process_busy=False def doCallback(self): self.at.cancel() if self.

Re: Protecting against callbacks queuing up?

2009-08-27 Thread Esben von Buchwald
Hendrik van Rooyen wrote: Hmm - now I am really starting to fly by the seat of my pants - but it looks as if your problem is that your routine is basically being called faster than what it can do the processing. So what I would try is to define a global (you should really acquire a lock, bu

Re: Protecting against callbacks queuing up?

2009-08-27 Thread Esben von Buchwald
Dennis Lee Bieber wrote: The only other thing I could suggest is exactly what is done on: http://pys60.garage.maemo.org/doc/s60/node59.html Initialize a counter value to 0, then increment it in the callback, only doing REAL work every n calls. def doCallback(self):

Re: Protecting against callbacks queuing up?

2009-08-26 Thread Esben von Buchwald
Dennis Lee Bieber wrote: On Tue, 25 Aug 2009 15:21:16 +0200, Esben von Buchwald declaimed the following in gmane.comp.python.general: This is how the accelerometer is accessed http://pys60.garage.maemo.org/doc/s60/node59.html I found this called "after"... http://pys60.garage.mae

Re: Protecting against callbacks queuing up?

2009-08-26 Thread Esben von Buchwald
Hendrik van Rooyen wrote: would that be usable? Probably If so, how? This is a guess, for your device, but I suspect something along these lines: t = Ao_timer() cb = t.after(100,thing_that_does_the_work(with_its_arguments)) Lots of assumptions here - the 100 should give you a tenth of a s

Re: Protecting against callbacks queuing up?

2009-08-25 Thread Esben von Buchwald
Dennis Lee Bieber wrote: On Mon, 24 Aug 2009 17:32:23 +0200, Esben von Buchwald declaimed the following in gmane.comp.python.general: I'm new to python, what is an after function and an after call? Couldn't find excact answer on google...? Do you have a link to some docs?

Re: Protecting against callbacks queuing up?

2009-08-24 Thread Esben von Buchwald
Hendrik van Rooyen wrote: see if there is an "after" method somewhere. What you have to do is to "break the link" between the callback and the processing. Your code above is all in the callback "thread", despite the fact that you call another function to do the processing. So if you replace

Protecting against callbacks queuing up?

2009-08-23 Thread Esben von Buchwald
Hello I'm using Python for S60 1.9.7 on my Nokia phone. I've made a program that gets input from an accelerometer sensor, and then calculates some stuff and displays the result. The sensor framework API does a callback to a function defined by me, every time new data is available. The prob

Re: Status of Python threading support (GIL removal)?

2009-06-19 Thread Martin von Loewis
Digging through my problem, I discovered Python isn't exactly thread safe and to solve the issue, there's this Global Interpreter Lock (GIL) in place. It's the opposite: Python is exactly thread safe precisely because it has the GIL in place. Is there any other way to work around the issue asi

Re: Status of Python threading support (GIL removal)?

2009-06-19 Thread Martin von Loewis
Digging through my problem, I discovered Python isn't exactly thread safe and to solve the issue, there's this Global Interpreter Lock (GIL) in place. It's the opposite: Python is exactly thread safe precisely because it has the GIL in place. Is there any other way to work around the issue asi

Re: HELP!...Google SketchUp needs a Python API

2008-11-28 Thread Giudo von Rossom
On Fri, 28 Nov 2008 15:22:58 -0800, r wrote: > You know I said before that I hoped Guido never see's this thread...but > i wonder if maybe he should see it...To see how far the "great > advocates" have fallen. I am disappointed to say the least. I would not > want to be in his shoes and see this!

Python and 3D

2008-03-15 Thread Eric von Horst
Hi, I am looking for Python modules that allow you to manipulate 3D objects, more specifically Alias Wavefront .OBJ objects. Also, a module that would allow you to vizualize these models and rotate them etc.. The goal is not to build a new renderer or something; just a small program that I need t

python-list@python.org

2008-03-10 Thread Eric von Horst
Hi, I need some advice on Drag&Drop. What I want to achieve is the following: - I have a window that is divided in two : on the left hand I have a wx.TreeCtlr and on the other hand a wx.StaticBitmap I want to be able to drag an item from the tree onto the static bitmap. I know how to d

Re: first time use of swig, python and c++ .. it's a mess ... please advice

2008-02-28 Thread Eric von Horst
ll > (hopefully) compile. > > I'd focus on doing it manually, then getting distutils to work properly. > > -Original Message- > From: Hyuga [mailto:[EMAIL PROTECTED] > Sent: Wednesday, February 27, 2008 10:01 AM > To: [EMAIL PROTECTED] > Subject: Re: first time use

first time use of swig, python and c++ .. it's a mess ... please advice

2008-02-26 Thread Eric von Horst
Hi, we have a third-party product that has a C++ api on HP-UX. I would like be able to use the API in Python (as I remember Python is good at doing this). I have no experience with this so I Googled and tried to find some info on what I had to do. So, I installed Python 2.4.4 and Swig 1.3.33 T

Looking for a event-message-qeue framework

2007-11-18 Thread Eric von Horst
Hi, I am looking for a kind of framework that let's me send events between systems. What I had in mind is common event bus that can be spread over multiple systems. On each system, there should be sort of an 'agent' that listens to the events on the bus and acts upon them if they are destined for

wxPython, Syntax highlighting

2007-03-27 Thread Eric von Horst
Hi, I am looking for wx widget that has the ability to show text, edit the text (like a TextCtrl) but also does syntax highlighting (if the text is e.g. XML or HTML). I have been looking in the latest wxPython version but I could not really find anything. Any suggestions? (I need this because my

Re: os.lisdir, gets unicode, returns unicode... USUALLY?!?!?

2006-11-17 Thread Johan von Boisman
Laurent Pointal wrote: > gabor a écrit : >> hi, >> >> from the documentation (http://docs.python.org/lib/os-file-dir.html) for >> os.listdir: >> >> "On Windows NT/2k/XP and Unix, if path is a Unicode object, the result >> will be a list of Unicode objects." > > Maybe, for each filename, you can te

Re: A question on Encoding and Decoding.

2006-11-17 Thread Johan von Boisman
[EMAIL PROTECTED] wrote: > Hello, > I think this remark is more to the point. In my experience, the general > problem is that python operates with the default encoding "ascii" as in > sys.getdefaultencoding(). It is possible to set the defaultencoding in > sitecustomize.py, with sys.setdefaultencod

Extending an embeded Python

2005-04-12 Thread Mikin von Flap
I'm trying to embed Python in a Windows exe, and extend it with some functions in the same program. So far I only add one function: static PyObject* py_print( PyObject* self, PyObject* args ) { const char* msg; if( !PyArg_ParseTuple( args, "s", &msg ) ) return 0; EventLog::log( msg ); Py_INCREF(

Re: how to comment out a block of code

2005-01-26 Thread Christian von Essen
A bit of a hack of course, but you can enclose the code that should be commented out with ''' and ''' or """ and """ (not sure about the name of this tripple-quoting) OTOH, some (or even most if not all) Python editors support blockquoting by pushing a button or using shortcuts. SPE and IDLE for ex