On Wed, 11 Feb 2009 18:52:40 +1100, Joel Ross wrote:
> Thanks for the quick response guys. Help me out a alot. I'm a newbie to
> python and your replies help me understand a bit more about python!!
Joel, unless you have Guido's time machine and are actually posting from
the future, the clock, or
En Tue, 10 Feb 2009 03:26:20 -0200, Michele Simionato
escribió:
On Feb 10, 4:29 am, "Gabriel Genellina"
> Honestly, I don't understand how this thing got so much out of
> control. If anyone starts an intelligent question or remark about
> super, this essay is thrown in no matter what. Anyone
Once I have seen Haskell code, that ran fibonacci on a 4 core system.
The algorithm itself basically used an extra granularity paramet until
which new threads will be sparked. e.g. fib(40, 36) means, calculate
fib(40) and spark threads until n=36.
1. divide: fib(n-1), fib(n-2)
2. divide: fib(n
"rantingrick" wrote
8< - dreams, goals and tentative spec -
Have you looked at Pycad ? - it started off with a similar rush
some time ago.
Maybe there is something there that you can use and/or salvage.
- Hendrik
--
http://mail.python.org/mailman/listinfo/pyth
"cptn.spoon" wrote:
On Feb 9, 6:48 pm, "Hendrik van Rooyen" wrote:
>> No.
>> At this level, just use a list of instances of your Stock class.
>>
>> - Hendrik
>
>How do I get a list of instances of a particular class? Is there a way
>to do this dynamically?
Yes there is. First make an empty list
"Spacebar265" wrote:
>Thanks. How would I do separate lines into words without scanning one
>character at a time?
Type the following at the interactive prompt and see what happens:
s = "This is a string composed of a few words and a newline\n"
help(s.split)
help(s.rstrip)
help(s.strip)
dir(s)
when I call "import wx" from the interactive console, it works (i.e.
it doesn't complain).
But when I call the same from a script, it complains that it can not
find the wx module.
works for interactive
Python 2.6.1 (r261:67517, Dec 4 2008, 16:51:00) [MSC v.
On Tue, 10 Feb 2009 18:18:23 +1000, Gerhard Weis wrote:
> Once I have seen Haskell code, that ran fibonacci on a 4 core system.
>
> The algorithm itself basically used an extra granularity paramet until
> which new threads will be sparked. e.g. fib(40, 36) means, calculate
> fib(40) and spark thr
Nicholas Feinberg wrote:
>Code that caused the problem (unlikely to be helpful, but no reason not to
include it):
>self.canvas.scale(self.body,self.radius/(self.radius-.5),self.radius/(self.radi
us-.05),0,0)#radius is greater than .5
scale's arguments are:
scale(TagOrID,xorigen,yorigen,xscale,
jefm wrote:
when I call "import wx" from the interactive console, it works (i.e.
it doesn't complain).
But when I call the same from a script, it complains that it can not
find the wx module.
works for interactive
Python 2.6.1 (r261:67517, Dec 4 2008, 16:
Is there a simple way to set a date/time and convert it to a unix
timestamp? After some googling I found the following:
t = datetime.time(7,0,0)
starttime = time.mktime(t.timetuple())+1e-6*t.microsecond
That seems like very long-winded. Is there an easier way? I've read
the docs on the datetime a
En Tue, 10 Feb 2009 06:45:37 -0200, Steven D'Aprano
escribió:
On Tue, 10 Feb 2009 18:18:23 +1000, Gerhard Weis wrote:
We tried this code on a 4 core machine using only 1 core and all 4
cores. 1 core wallclock: ~10s
4 core wallclock: ~3s
Three seconds to calculate fib(40) is terrible. Well,
On Tue, Feb 10, 2009 at 12:45 AM, Steven D'Aprano
wrote:
> On Tue, 10 Feb 2009 18:18:23 +1000, Gerhard Weis wrote:
>
>> Once I have seen Haskell code, that ran fibonacci on a 4 core system.
>>
>> The algorithm itself basically used an extra granularity paramet until
>> which new threads will be sp
On Tue, 10 Feb 2009 02:02:43 +, Benjamin Peterson wrote:
> Jean-Paul Calderone divmod.com> writes:
>> Consider whether you really need to use super().
>>
>> http://fuhm.net/super-harmful/
>
> This article chiefly deals with super()'s harm in multiple inteheritance
> situations. For the simp
psaff...@googlemail.com wrote:
> On 9 Feb, 12:24, Gerhard Häring wrote:
>> http://objectmix.com/python/631346-parallel-python.html
>>
>
> Hmm. In fact, this doesn't seem to work for pp. When I run the code
> below, it says everything is running on the one core.
>
> import pp
> import random
> im
I am trying to make a small python application to change DNS servers
in a small LAN.
I am trying this code but I don't manage it to work, I only get the
values removed.
My code is this:
import win32com.client
objWMIService = win32com.client.GetObject("winmgmts:
{impersonationLevel=impersonate}!
On 10 Feb, 09:45, Steven D'Aprano
wrote:
> On Tue, 10 Feb 2009 18:18:23 +1000, Gerhard Weis wrote:
> > Once I have seen Haskell code, that ran fibonacci on a 4 core system.
>
> > The algorithm itself basically used an extra granularity paramet until
> > which new threads will be sparked. e.g. fib(
On Feb 10, 10:42 am, Marc 'BlackJack' Rintsch wrote:
> On Tue, 10 Feb 2009 02:02:43 +, Benjamin Peterson wrote:
> > Jean-Paul Calderone divmod.com> writes:
> >> Consider whether you really need to use super().
>
> >>http://fuhm.net/super-harmful/
>
> > This article chiefly deals with super()'
Mark Hammond wrote:
What problems specifically? The only practical problems you should see
will arise if you try and pass a "FILE *", or allocate memory you then
ask python to free (or vice-versa) - both should be avoidable though...
It concerns a Ruby plugin for Sketchup that embeds a Pytho
A script that I'm writing pulls the system time off of an iPod
connected to the computer. The iPod's time is represented as a Unix
timestamp (seconds since the epoch), but this timestamp does not
represent UTC time, but rather the local timezone of the owner. I need
to convert this local time times
Steven D'Aprano wrote:
> On Mon, 09 Feb 2009 19:10:28 -0800, Spacebar265 wrote:
>
>> How would I do separate lines into words without scanning one character
>> at a time?
>
> Scan a line at a time, then split each line into words.
>
>
> for line in open('myfile.txt'):
> words = line.split
On Feb 10, 7:37 am, Tim Roberts wrote:
> PJ wrote:
>
> >I have a simple web server using BaseHTTPServer, and the def do_POST
> >(self) function works fine for regular forms that are submitted to it,
> >but when I send anAJAXPOST to it it does nothing (I've tried to just
> >get it to print to che
Paul Rubin:
> Gideon Smeding of the University of
> Utrecht has written a masters' thesis titled "An executable
> operational semantics for Python".
A significant part of Computer Science is a waste of time and money.
Bye,
bearophile
--
http://mail.python.org/mailman/listinfo/python-list
steven probably knows this, but to flag the issue for people who are
looking at generators/coroutines for the first time: there's a little
"gotcha" about exactly how the two sides of the conversation are
synchronized. in simple terms: send also receives.
unfortunately the example steven gave doe
Steven D'Aprano wrote:
On Wed, 11 Feb 2009 18:52:40 +1100, Joel Ross wrote:
Thanks for the quick response guys. Help me out a alot. I'm a newbie to
python and your replies help me understand a bit more about python!!
Joel, unless you have Guido's time machine and are actually posting from
th
Joel Ross wrote:
Hi all,
I have this piece of code:
#
wordList = "/tmp/Wordlist"
file = open(wordList, 'r+b')
def readLines():
for line in file.read():
if not line: break
print line + '.co
On Tue, 10 Feb 2009 14:28:15 +0800, oyster wrote:
> I mean this
> [code]
> def fib(n):
> if n<=1:
> return 1
> return fib(n-1)+fib(n-2)
>
> useCore(1)
> timeit(fib(500)) #this show 20 seconds
>
> useCore(2)
> timeit(fib(500)) #this show 10 seconds [/code]
>
> Is it possible?
>
def fib(n, a=1, b=1):
if n==0:
return a
elif n==1:
return b
return fib(n-1, b, a+b)
And for the record:
fib(500)
225591516161936330872512695036072072046011324913758190588638866418474627738686883405015987052796968498626L
timeit.Timer('fib(500)',
'from __main__ i
Phillip B Oldham schrieb:
Is there a simple way to set a date/time and convert it to a unix
timestamp? After some googling I found the following:
t = datetime.time(7,0,0)
starttime = time.mktime(t.timetuple())+1e-6*t.microsecond
That seems like very long-winded. Is there an easier way? I've rea
the python routines are a bit basic - you really have to think quite hard
about what you are doing to get the right answer.
in your case, you need to be clear what the timezone is for the datetime
you are using. timezone info is optional (see the datetime documentation,
where it talks about "nai
On Tue, 03 Feb 2009 20:08:34 -0800, Stephen Hansen wrote:
> There is no need to try to make sure something is
> executed/compiled only once in Python like you may want to do in C.
> Every module is only ever compiled once: if you import it ten times in
> ten different places only the first will co
Anyone out there any experience of using python ssh modules to connect
to the Tetia SSH server from SSH (ssh.com)?
--
http://mail.python.org/mailman/listinfo/python-list
Greetings to list members,
I am trying to use an Acrobat COM object in a class that is subclassed from
threading.Thread.
Since threading.Thread is subclassed, the __init__ method of the inheriting
class must explicitly call the threading.Thread.__init__ method of the
parent. I guess I'm missing so
On 2009-02-10 10:26, Phillip B Oldham wrote:
> Is there a simple way to set a date/time and convert it to a unix
> timestamp? After some googling I found the following:
>
> t = datetime.time(7,0,0)
> starttime = time.mktime(t.timetuple())+1e-6*t.microsecond
>
> That seems like very long-winded. I
loial wrote:
Anyone out there any experience of using python ssh modules to connect
to the Tetia SSH server from SSH (ssh.com)?
Did you call their support? Personally I see no reason why
paramiko http://www.lag.net/paramiko/ should not work, given
that openssh ssh client also worked in the past
Hello,
I am using poplib and I noticed that calls to top() don't return the msg
info (2nd index in the returned list, e.g. email.top(1,0)[1]) in the
same order, by that I mean the date could be email.top(1,0)[1][2] or
email.top(1,0)[1][5], etc. Is there a reason for that other than that
may b
Hey guys,
The Southern California Linux Expo, a community run conference taking
place in Los Angeles on February 20th to 22nd, is offering a 50% discount
to the Python community. When you go to register[1], just enter the promo
code: PYTHN. If you have any questions, please let me know.
Thanks!
J
Hi!
I wanna ask that have anyone some experience with email.msg and smtplib?
The email message and smtp.send already have "sender/from" and
"recip/addr to".
Possible the smtp components does not uses the email tags if I not
define them only in the message?
Can I do same thing as in GMAIL tha
Thanks guys, Really appreciate your help. I am trying to solve the
problem and will keep you posted when I found a solution.
Farsheed Ashouri,
Tehran, Iran
--
http://mail.python.org/mailman/listinfo/python-list
codecs.open defaults to line buffering. But open defaults to using
the system buffer size. Why the discrepancy? Is it different for a
reason?
How do these choices affect performance? (Particularly under Linux).
Thanks
--
http://mail.python.org/mailman/listinfo/python-list
> I have made the same analysis to some commercial source code, the
> dup60 rate is quite often significantly larger than 15%.
commercial code sucks often .. that's why they hide it :)
--
дамјан ( http://softver.org.mk/damjan/ )
Scarlett Johansson: You always see the glass half-empty.
Woody Al
Hi!
Ok, I forget to set encodings.
from Cheetah.Template import Template
d = {'a' : 'almás'}
tp = Template("# encoding: iso-8859-2\nhello world éááá ${d['a']}!",
searchList = {'d': d})
print tp
sys.exit()
This code is working for me in Windows.
dd
2009.02.05. 16:21 keltezéssel, durumdara í
Ferdinand Sousa wrote:
Greetings to list members,
I am trying to use an Acrobat COM object in a class that is subclassed from
threading.Thread.
Since threading.Thread is subclassed, the __init__ method of the inheriting
class must explicitly call the threading.Thread.__init__ method of the
paren
I want to connect via ssh from a python script on windows to an AIX
server running openSSH using rsa keys rather than a password.
Can anyone provide me with /point me at a simple tutuorial on the
steps I need to go though in terms of geneerating the key, installing
on the server and connecting in
OpenERP 5.0 is out !
Why do I talk about OpenERP on this mailing list ? Because OpenERP is fully
developed with Python
That major enhancement of Open ERP can now answer to all the needs of a business. Open ERP V5 not only provides management functions, but also all function
On Feb 9, 2009, at 10:26 PM, kpp9c wrote:
okay... for the life of me i do not see any Python Launcher.app and i
just installed OS X 10.5 (running 10.5.6 on intel) and i also
installed the dev kit.
Where the heck is this application?
Hi kp,
I don't seem to have any such beast on my syste
loial wrote:
I want to connect via ssh from a python script on windows to an AIX
server running openSSH using rsa keys rather than a password.
Can anyone provide me with /point me at a simple tutuorial on the
steps I need to go though in terms of geneerating the key, installing
on the server an
On Feb 10, 2009, at 7:29 AM, durumdara wrote:
Hi!
I wanna ask that have anyone some experience with email.msg and
smtplib?
The email message and smtp.send already have "sender/from" and
"recip/addr to".
Possible the smtp components does not uses the email tags if I not
define them only
On Feb 9, 2009, at 3:59 PM, Christian Heimes wrote:
Philip Semanchuk wrote:
Yes, that's accurate except for the word "forgot". To forget
something
one must first know it. =) I found the threading API documentation
difficult to follow, but I suppose that what I'm doing is a little
unusual so
I use this code to upload using cherrypy:
#Code Start==
class NoteServer(object):
_cp_config = { 'tools.sessions.on': True }
def index(self):
return """
filename:
Pars Studios, 200
durumdara schreef:
> Hi!
>
> I wanna ask that have anyone some experience with email.msg and smtplib?
>
> The email message and smtp.send already have "sender/from" and
> "recip/addr to".
> Possible the smtp components does not uses the email tags if I not
> define them only in the message?
sm
On Tue, 10 Feb 2009 02:11:10 -0800, Michele Simionato wrote:
> Unfortunately there is no good solution. If you have a single
> inheritance hierarchy and you do not use super, you make it impossible
> for users of your hierarchy to subclass it by using multiple
> inheritance in a cooperative way (t
Can anyone be a little more helpful than Tino?
I have generated the key file as follows on windows and ftp'd the
id_rsa.pub file to the .ssh directory on the server and renamed to
authorized_keys
import paramiko
key = paramiko.RSAKey.generate(2048)
key.write_private_key_file('Z:/id_rsa')
file
Hi,
2009/2/10 Atishay :
> Now the point is, how do I avoid setting LD_LIBRARY_PATH everytime for
> python? I know I can write a bash script, but I am sure python would
> have some feature that I can tweak to make it work.
On debian you can modify
* /etc/ld.so.conf and/or
* /etc/ld.so.conf.d/..
We just upgraded Python to 2.6 on some of our servers and a number of
our CGI scripts broke because the cgi module has changed the way it
handles POST requests. When the 'action' attribute was not present in
the form element on an HTML page the module behaved as if the value of
the attribute was t
Lie Ryan wrote:
> On Tue, 03 Feb 2009 20:08:34 -0800, Stephen Hansen wrote:
>
> > There is no need to try to make sure something is
> > executed/compiled only once in Python like you may want to do in C.
> > Every module is only ever compiled once: if you import it ten times in
> > ten different
> I don't think so. But there are several other options:
I was afraid of that.
Thanks anyway!
Mike
--
http://mail.python.org/mailman/listinfo/python-list
I ran the script from a command line, so it is not a file association
thing.
I do have multiple versions of Python installed on that machine. I
will uninstall them all and install a single version from clean.
Thanks for the suggestion
--
http://mail.python.org/mailman/listinfo/python-list
jefm wrote:
I ran the script from a command line, so it is not a file association
thing.
Ummm... if you ran it by just typing the script name --
c:\test\whatever.py rather than c:\pythonxx\python c:\test\whatever.py --
then it certainly could be a file association issue.
I do have multiple ve
let's assume I (almost) have and extension available as a C file and
the setup.py and I want to generate from this single c file 2 .so
files using
cc -DOPTION1 x.c to produce x_1.so
cc -DOPTION2 x.c to produce x_2.so
and at runtime depending of my OS version either load x_1 or x_2
any (easy) way
On Tue, Feb 10, 2009 at 10:06 AM, Philip Semanchuk wrote:
>
> On Feb 9, 2009, at 10:26 PM, kpp9c wrote:
>
> okay... for the life of me i do not see any Python Launcher.app and i
>> just installed OS X 10.5 (running 10.5.6 on intel) and i also
>> installed the dev kit.
>>
>> Where the heck is
Hi All,
i am writing unit tests and have got a problem:
I want to test some code sequence like:
self.assertEquals(testMethod1(), expected_value1);
self.assertEquals(testMethod2(), expected_value2);
However, if the first test item is failed, no more tests will be executed.
Can I tell Python,
1
On Feb 10, 2009, at 11:49 AM, Benjamin Kaplan wrote:
On Tue, Feb 10, 2009 at 10:06 AM, Philip Semanchuk >wrote:
On Feb 9, 2009, at 10:26 PM, kpp9c wrote:
okay... for the life of me i do not see any Python Launcher.app and i
just installed OS X 10.5 (running 10.5.6 on intel) and i also
loial wrote:
Can anyone be a little more helpful than Tino?
I'll do some freebie hints :-)
What I would do is try first whether key authentication works at all,
for example following a tutorial like
http://the.earth.li/~sgtatham/putty/0.53b/htmldoc/Chapter8.html
And if that works translate
In article ,
wrote:
>Quoth a...@pythoncraft.com (Aahz):
>> In article ,
>> Thorsten Kampe wrote:
>>>* Aahz (2 Feb 2009 09:29:43 -0800)
Polarized sunglasses don't work too well with LCD monitors
>>>
>>>Well, the answer to your issue with syntax highlighting is to use a
>>>/decent/ hi
Hello All,
I have an application where logging may need to be configured in
multiple places. I've used the Python Logging Framework for sometime,
but I'm still not sure how to test if logging has configured. For
example, I have modules A, B, and C.
Below is some pseudo code...
moduleA
class A(
Hi Folks,
urllib bridges up a client to a server, it works fine. I wonder: is
there a method that can check the existence of a file in the server
side? We can check such an existence on local filesystem by using
os.path.exists(), can I do such a check on server? For example,
http://somedomain.com/
rantingrick wrote:
...
It has long been my dream to create an open source 3D CAD program and
i am starting to crawl my way into the first steps. I now believe i am
ready to start this endeavor and i am currently looking for fellow
Python programmers (no matter what skill level) to get started
bra
Muddy Coder wrote:
> urllib bridges up a client to a server, it works fine. I wonder: is
> there a method that can check the existence of a file in the server
> side? We can check such an existence on local filesystem by using
> os.path.exists(), can I do such a check on server? For example,
> htt
a...@pythoncraft.com (Aahz) wrote:
> In article ,
> wrote:
> >Quoth a...@pythoncraft.com (Aahz):
> >> Then I have the problem of copying around the syntax highlighting
> >> configuration to every computer I use.
> >
> >Well, _that's_ easy to fix. I have a little bash script called
> >'synchome'
Can someone recommend a good tutorial for Python 3, ideally that has tasks or
assignments at the end of each chapter.
Please,
--
http://mail.python.org/mailman/listinfo/python-list
On Feb 10, 6:30 am, "andrew cooke" wrote:
> steven probably knows this, but to flag the issue for people who are
> looking at generators/coroutines for the first time: there's a little
> "gotcha" about exactly how the two sides of the conversation are
> synchronized. in simple terms: send also re
On 10 Feb, 17:08, "Martin P. Hellwig"
wrote:
> loial wrote:
> > Can anyone be a little more helpful than Tino?
>
>
> I'll do some freebie hints :-)
> What I would do is try first whether key authentication works at all,
> for example following a tutorial
> likehttp://the.earth.li/~sgtatham/putty
On Tue, Feb 10, 2009 at 11:48 AM, Qian Xu wrote:
> self.assertEquals(testMethod1(), expected_value1);
> self.assertEquals(testMethod2(), expected_value2);
>
> However, if the first test item is failed, no more tests will be executed.
> Can I tell Python,
> 1. go ahead, if a failure is occurred.
Hi List,
I am getting an index out of range error when trying to parse with getopt.
Probably something simple. Any suggestions are appreciated
optlist, args = getopt.getopt(sys.argv[1:], 'h', ['connectPassword=',
'adminServerURL=', 'action=', 'targets=', 'appDir='])
#Assign Opts
connectPassword
In article <49899185$0$2861$ba620...@news.skynet.be>,
Helmut Jarausch wrote:
>
>These pipes are exposed as file-like objects which can be accessed via
>the stdin, stdout or stderr (resp.) attributes of an object of class
>subprocess.Popen .
Please file a doc request at bugs.python.org
--
Aahz (
quite simply...what???
In [108]: bool([ x for x in range(10) if False ])
Out[108]: False
In [109]: bool( x for x in range(10) if False )
Out[109]: True
Why do these two evaluate differently? I was expecting that they would
evaluate the same but the generator would return true *as soon as the
fir
Hi,
Is it possible to write DLL's in Python for applications that only
provide C++ interfaces? Example: NotePad++ is extendible by writing C++
DLL's which can call the NotePad++ interfaces.
I wonder if those DLL's also can be written in Python, which in the end
calls the C++ interfaces of N
Qian Xu wrote:
i am writing unit tests and have got a problem:
I want to test some code sequence like:
self.assertEquals(testMethod1(), expected_value1);
self.assertEquals(testMethod2(), expected_value2);
However, if the first test item is failed, no more tests will be executed.
Can I tell Py
Hi all. I'm experimenting with making a UI for a little (well, not
quite) script that basically draws up a tech tree to some skills from
my favorite game. What I'm aiming for looks a little like this site
here:(apologies if I'm not supposed to direct link)
http://www.anderkoo.com/uploads/271/605/Ne
Holden Web is pleased to announce its next public introductory Python
class in the Washington, DC area on March 3-5. To enroll, or to learn
more about the class please visit:
http://holdenweb.com/py/training/
If you have multiple students requiring training you may be interested
to know that th
On Tue, Feb 10, 2009 at 11:15 AM, Josh Dukes wrote:
> quite simply...what???
>
> In [108]: bool([ x for x in range(10) if False ])
> Out[108]: False
This evaluates the list comprehension and creates an empty list, which
is considered boolean False by Python.
> In [109]: bool( x for x in range(10
On Tue, 2009-02-10 at 11:15 -0800, Josh Dukes wrote:
> quite simply...what???
>
> In [108]: bool([ x for x in range(10) if False ])
> Out[108]: False
>
> In [109]: bool( x for x in range(10) if False )
> Out[109]: True
>
> Why do these two evaluate differently? I was expecting that they would
>
The Python 2.6 Quick Reference is available in HTML and PDF formats at
http://rgruet.free.fr/#QuickRef.
This time I was helped by Josh Stone for the update.
As usual, your feedback is welcome (pqr at rgruet.net).
Cheers,
Richard Gruet
--
http://mail.python.org/mailman/listinfo/python-list
Marc 'BlackJack' Rintsch gmx.net> writes:
>
> On Tue, 10 Feb 2009 02:02:43 +, Benjamin Peterson wrote:
>
> > Jean-Paul Calderone divmod.com> writes:
> >> Consider whether you really need to use super().
> >>
> >> http://fuhm.net/super-harmful/
> >
> > This article chiefly deals with supe
On Tue, 10 Feb 2009 19:40:56 + (UTC), Benjamin Peterson
wrote:
Marc 'BlackJack' Rintsch gmx.net> writes:
On Tue, 10 Feb 2009 02:02:43 +, Benjamin Peterson wrote:
> Jean-Paul Calderone divmod.com> writes:
>> Consider whether you really need to use super().
>>
>> http://fuhm.net/sup
On Tue, Feb 10, 2009 at 8:42 AM, wrote:
> let's assume I (almost) have and extension available as a C file and
> the setup.py and I want to generate from this single c file 2 .so
> files using
>
> cc -DOPTION1 x.c to produce x_1.so
> cc -DOPTION2 x.c to produce x_2.so
>
> and at runtime depending
Hey,
I'm currently working with propositional boolean formulae of the type
'A & (b -> c)' (for example). I was wondering if anybody knows of a
Python library to create parse trees and convert such formulae to
conjunctive, disjunctive and Tseitin normal forms?
Cheers,
nnp
--
http://www.unprotect
On Feb 10, 1:27 pm, Kalibr wrote:
[snip]
> Now I know all I have to do is set the SkillInfos parent to a canvas,
> but how would I arrange and draw the lines? Thanks all :)
You should really check out wxPython, there is support for just this
type of thing. of course you could do this with Tkinter
On 2/9/09, Gabriel Genellina wrote:
> En Mon, 09 Feb 2009 23:34:05 -0200, Daniel Fetchinson
> escribió:
>
>> Hello. I've been scouring the web looking for something to clear up a
>> little confusion about the use of "super()" but haven't found
>> anything
>> that really helps. Her
> Consider whether you really need to use super().
>
> http://fuhm.net/super-harmful/
Did you actually read that article, understood it, went through the
tons of responses from python-dev team members, including Guido
>
> "Tons" of responses?
This was mentioned already, bu
On 2009-02-10 11:50, aha wrote:
Hello All,
I have an application where logging may need to be configured in
multiple places. I've used the Python Logging Framework for sometime,
but I'm still not sure how to test if logging has configured. For
example, I have modules A, B, and C.
Below is som
> Is it possible to write DLL's in Python for applications that only
> provide C++ interfaces? Example: NotePad++ is extendible by writing C++
> DLL's which can call the NotePad++ interfaces.
Not directly, no. You have to write a C++ DLL which then can delegate
all calls to it to some Python func
Hi Folks,
I want to use a Button to trigger askopenfilename() dialog, then I can
select a file. My short code is below:
def select_file():
filenam = askopenfilename(title='Get the file:')
return filenam
root = Tk()
Button(root, text='Select a file', command=select_file).pack()
ro
On Feb 10, 5:50 pm, aha wrote:
> Hello All,
>
> I have an application whereloggingmay need to be configured in
> multiple places. I've used the PythonLoggingFramework for sometime,
> but I'm still not sure how to test iflogginghas configured. For
> example, I have modules A, B, and C.
>
> Below
I remember being forced to do a bit of functional programming in ML back
at Uni in the mid 90, the lecturers were all in a froth about it and I
must admit the code was elegant to look at. The problem was the dog slow
performance for anything half practical, especially with recursion being
the techn
On Tue, Feb 10, 2009 at 12:21 PM, Muddy Coder wrote:
> Hi Folks,
>
> I want to use a Button to trigger askopenfilename() dialog, then I can
> select a file. My short code is below:
>
>
> def select_file():
>filenam = askopenfilename(title='Get the file:')
> return filenam
>
> root =
[Didn't realize the mirror didn't work both ways]
We just upgraded Python to 2.6 on some of our servers and a number of our CGI
scripts broke because the cgi module has changed the way it handles POST
requests. When the 'action' attribute was not present in the form element on
an HTML page th
> The first example is a list. A list of length 0 evaluates to False.
>
> The second example returns a generator object. A generator object
> apparently evaluates to true. Your example is not iterating of their
> values of the generator, but evaluating bool(generator_object) itself.
> My feelin
r0g wrote:
> def ip2inet(a):
> li = a.split('.')
> assert len(li) == 4 or len(li) == 6
> return reduce(add,[int(li[e])*(256**((len(li)-1)-e)) for e in
> xrange(0,len(li))])
what a mess.
i don't use this extreme a functional style in python (it's not really how
the language is intended to be
1 - 100 of 193 matches
Mail list logo