On May 19, 10:28 pm, Ben Finney wrote:
> Better is to use ‘shlex.split’ to split the string as a shell parser
> would do http://docs.python.org/library/shlex#shlex.split>.
Good point. I always forget about shlex.split because I'm usually
passing (relatively) constant strings with no funny quoti
On Wed, May 19, 2010 at 7:27 PM, Carbon wrote:
> I am new to Python and am trying to write a GUI wrapper script in python
> 2.5 to get username and passwords from Linux users to send as options to
> run an app on a 2X terminal server. I came across the easygui module and
> its multpasswordbox func
Patrick Maupin writes:
> On May 19, 9:27 pm, Carbon wrote:
> > subprocess.call(["/opt/2X/Client/bin/appserverclient", "-u
> > fieldValues [0]", "-p fieldValues[1]", "-s ts.mycompany.org:80", "-d
> > corp", "-S local", "-c 16", "-e 0xF", "-l 0x0409", "-a #1"])
As Patrick says, you need to give t
On May 19, 9:27 pm, Carbon wrote:
> I am new to Python and am trying to write a GUI wrapper script in python
> 2.5 to get username and passwords from Linux users to send as options to
> run an app on a 2X terminal server. I came across the easygui module and
> its multpasswordbox function, which m
I am new to Python and am trying to write a GUI wrapper script in python
2.5 to get username and passwords from Linux users to send as options to
run an app on a 2X terminal server. I came across the easygui module and
its multpasswordbox function, which made popping a dialog box and storing
th
on 08.11.2005 17:40 Brendan said the following:
[snip config/properties file needs]
>
> I've checked out ConfigParser, ConfigObj, Pickle, PyYaml and
> gnossis.xml.serialize, and none meet all the above criteria (though
> they're all neat).
>
> So I've decide to use ...drumroll please plistlib
Thanks for all the suggestions everyone.
After a bit of googling on the c.l.p. group, I see that building config
files is one of those 'Everyone has a favourite way of doing it' types
of problems, with lots of reimplementations. I should change the
thread topic to "Yet Another Config File Questio
> Also my config files have (a tiny bit of) nested
> structure, such as:
>
> Model1(
>numBumps = 1
>sizeOfBumps = 2
>transversePlanes = [
> Plane(type=3, z=4),
> Plane(type=5, z=6),
> Plane(type=3, z=8)
> ]
> )
>
> which I'm not sure the .ini format can eas
Brendan wrote:
> Thanks for your reply Steve. I like this suggestion because it
> separates my config data from the code, which could mean less headaches
> editing the values later. It also lets me keep my constants
> language-neutral, which is good because I haven't convinced my boss yet
> that
Brendan wrote:
>>How many is LOOONG? Ten? Twenty? One hundred?
>
>
> About 50 per Model
>
>
>>If it is closer to 100 than to 10, I would suggest
>>putting your constants into something like an INI file:
>>
>>[MODEL1] # or something more meaningful
>>numBumps: 1
>>sizeOfBumps: 99
>>
>>[MODEL2
"Brendan" <[EMAIL PROTECTED]> writes:
> seems risky. Also my config files have (a tiny bit of) nested
> structure, such as:
>
> Model1(
>numBumps = 1
>sizeOfBumps = 2
>transversePlanes = [
> Plane(type=3, z=4),
> Plane(type=5, z=6),
> Plane(type=3, z=8)
>
> How many is LOOONG? Ten? Twenty? One hundred?
About 50 per Model
> If it is closer to 100 than to 10, I would suggest
> putting your constants into something like an INI file:
>
> [MODEL1] # or something more meaningful
> numBumps: 1
> sizeOfBumps: 99
>
> [MODEL2]
> numBumps: 57
> sizeOfBumps
Brendan wrote:
> Hi all
>
> I'm new to Python (and programming in general), and I can't decide what
> is the most 'pythonic' way to approach a problem. Your advice would be
> appreciated.
>
> I have a bunch of 'scans', containing the data measured from one of
> several types of 'model'. Each 'm
Thanks for the vote FB. The reason I'm using that method for assigning
instance attributes is that the argument list for __init__ is LOOONG.
(There are many constants, I only gave two for the examples). I wanted
to avoid typing them out twice.
--
http://mail.python.org/mailman/listinfo/python-l
Il Sun, 06 Nov 2005 08:33:17 -0800, Brendan ha scritto:
> Hi all
>
> I'm new to Python (and programming in general), and I can't decide what
> is the most 'pythonic' way to approach a problem. Your advice would be
> appreciated.
>
> I have a bunch of 'scans', containing the data measured from o
Hi all
I'm new to Python (and programming in general), and I can't decide what
is the most 'pythonic' way to approach a problem. Your advice would be
appreciated.
I have a bunch of 'scans', containing the data measured from one of
several types of 'model'. Each 'model' has different values for a
Thorsten Kampe wrote:
> * El (2005-07-10 11:56 +0100)
>>Python 1.5.1 (final) and Python Win32 Extensions are installed on my 4 year
>
> If you don't use it: uninstall Python. If something else uses it: keep
> it as it is as your app might break with the new Python - even though
> 2.4 is backwards
* El (2005-07-10 11:56 +0100)
> Sorry to bother you folks with a real newbie question, but I am sure that
> this is the place for me to ask.
>
> Python 1.5.1 (final) and Python Win32 Extensions are installed on my 4 year
> old computer. My computer has always been upgraded to include the latest
Hi,
Sorry to bother you folks with a real newbie question, but I am sure that
this is the place for me to ask.
Python 1.5.1 (final) and Python Win32 Extensions are installed on my 4 year
old computer. My computer has always been upgraded to include the latest
programs and Windows updates.
Ho
Valone, Toren W. wrote:
Traceback (most recent call last):
File "C:/Python24/dialog1.py", line 29, in -toplevel-
d = MyDialog(root)
NameError: name 'MyDialog' is not defined
Suggestion: Read the place in your code where MyDialog is defined and compare it
with where it is used. Check case. Yo
Valone, Toren W. wrote:
Ok, new to Python and Tkinter.. Following along examples in book, got to
dialog windows example coded this
# dialog1.py
from Tkinter import *
class Mydialog:
[...]
d = MyDialog(root)
root.wait_window(d.top)
When I run it IDLE
Ok, new to Python and Tkinter.. Following along examples in book, got to
dialog windows example coded this
# dialog1.py
from Tkinter import *
class Mydialog:
def _int_(self,parent):
top = self.top = Toplevel(parent)
Label(top, text="Value").pack()
self.e = Entry(top
Jon wrote:
Obviously I don't need PeekNamedPipe here but I know the pipe has something
in it and wanted to try it out. The code all works fine if I comment out
PeekNamedPipe.
The pipes returned by the win32pipe.popen calls are standard file-like objects,
rather than win32 Named Pipes. The only way
Jean Montambeault wrote:
I am not only learning Python but programming itself ; reading your
posts makes me believe that nobody is that much of a beginner here. Is
there a newgroup or list for my type somewhere I can't find it ?
To illustrate my case this script :
# function to draw rings for a
> bou_asia=Button(fen1, text='Asia',\
>command=rings(size=41, offsetX=50,offsetY=22,
> coul='yellow'))
You're calling the rings function when you create the button.
What you really want is for "command" to be a callable object
that the button will invoke when it's clicked, e.
>
> > bou_europe=Button(fen1, text='Europe',\
> >command=rings(41, 100, -22, 'blue'))
Silly me. I misunderstood what you wanted first time around.
In Python functions are "first class objects" that are treated no
differently than anything else. When you setup your button
On Fri, 2004-12-03 at 06:38, Jean Montambeault wrote:
> I am not only learning Python but programming itself ; reading your
> posts makes me believe that nobody is that much of a beginner here. Is
> there a newgroup or list for my type somewhere I can't find it ?
>
> To illustrate my case this s
Jean Montambeault wrote:
I am not only learning Python but programming itself ; reading your
posts makes me believe that nobody is that much of a beginner here. Is
there a newgroup or list for my type somewhere I can't find it ?
To illustrate my case this script :
# function to draw rings for a
On Fri, 03 Dec 2004 06:38:54 -0500, Jean Montambeault
<[EMAIL PROTECTED]> wrote:
> I am not only learning Python but programming itself ; reading your
> posts makes me believe that nobody is that much of a beginner here. Is
> there a newgroup or list for my type somewhere I can't find it ?
The tut
I am not only learning Python but programming itself ; reading your
posts makes me believe that nobody is that much of a beginner here. Is
there a newgroup or list for my type somewhere I can't find it ?
To illustrate my case this script :
# function to draw rings for an Olympic flag
def rings(
30 matches
Mail list logo