I don't get it (the Elliot solution)... How is it that the first value
is repeated once times, and the remaining values are repeated twice
times?
--
http://mail.python.org/mailman/listinfo/python-list
Instead of self.Close(), try parent.Close()
The self.Close() is closing self, which is a panel. The panel's parent
is the frame. This will let you keep the button on the frame, which
eliminates the spacing problem.
I'm not gonna test it, cuz the darn lines wrap and make it difficult to
copy you
Oh! I see what I missed. I didn't supply the namespace into which the
new class was going to be added (correct that statement, please, if it
is incorrect).
So by using this slight modification, thinks seemed to work:
exec testModule.TheTestCode %(testModule.TheTestName,
testModule.TheTestName )
Hi Michael... It didn't seem to take. Here is some of the actual code:
[[ from the runner ]
print "+++"
print "::Dir before exec:",dir(testModule)
import CodeGenBase
I'm trying to add a class to a module at runtime. I've seen examples
of adding a method to a class, but I haven't been able to suit it to my
needs.
As part of a testsuite, I have a main process X that searches
recursively for python test files. Those files typically have a global
"isSupported" m
I have a server that right now runs infinitely. I'd like to make it
die after some amount of time. I was thinking of having a timebomb
thread that starts when the server starts. The timebomb sits, and
sleeps for the specified timeout period (e.g., 5 hours), then does
something to make the main t
You could also set your "python" environment variable on the system...
set it to be "/path/to/python2.4". Then use the "#!/usr/bin/env
python" trick. Just make sure that env is working for you, first.
--
http://mail.python.org/mailman/listinfo/python-list
oops... I missed the "too specific comment." Sorry =)
--
http://mail.python.org/mailman/listinfo/python-list
On your system, do:
which python2.4
That will give you the full path to the python2.4 binary (let's call it
"path/to/py24").
Then add:
#!/path/to/py24
...to the top of your script.
And make sure the file is chmod'd +x
--
http://mail.python.org/mailman/listinfo/python-list
I'm having a tough time figuring this one out:
class MyKBInterrupt( . ):
print "Are you sure you want to do that?"
if __name__ == "__main__":
while 1:
print "Still here..."
So this thing keeps printing "Still here..." until the user hits ctl-c,
at which time the except
I know... I'm expecting pain, and when that pain doesn't arrive I
assume that I did something wrong.
Actually, I was using the odbc/dbi stuff that ships with the win32
distribution for my windows work, and using MySQLdb for my linux work.
Most of the code is the same. But I suppose the big benefi
All,
This info was very helpful, and I'm up and running with MySQLdb on
linux, and the native ODBC support on Windows.
One last question I have: In vbs (specifically with .asp) I can make a
connection to an ODBC provide _without_ the need to specify a system
DSN in the Control Panel. It's easy
Can you tell me what I have to use in order to utilize the MySQL native
API? There's some gap (chasm, really) in my knowledge that is keeping
me from following that route. If you could provide a small example or
a couple names, that would be extremely helpful.
Thanks again for your time.
Larry
I'm getting my feet wet with making Python talk to MySQL via ODBC. I
started on Windows, and it went smoothly enough due to the ODBC stuff
that apparently is native to Python at least on windows (I've been
following ch. 13 of Mark Hammond's py on win32 book).
But now I'm trying to do equivalent s
14 matches
Mail list logo