Hi - I'd really like to have access to Python 2.6 to try something
out. It needs to be on Linux/Unix machine. I don't mind paying but
whichever way I turn I find Python 2.4 is the standard installation.
Anyone know of anyone who offers this out of the box ? Or got any
smart way of achieving it ?
Jannik Sundø wrote:
> Dear all, I am quite confused about the Python logging. I have read
> and re-read the Python documentation for the Python logging module and
> googled, but to no avail. I simply want one logger to log to a file
> and another logger to log to the console. Neither should log th
hello there, I'm using Learning Python 3rd edition as my core
reference, the book is great.
here's some snippet for demonstrating echo-server program, but I can't
interpret it in both windows / Gnu linux ...
#!/usr/bin/env python
from socket import *
myHost = ''
myPort = 50007
sockobj = socket(AF_
On Thu, 30 Jul 2009 18:06:31 -0500, Robert Kern wrote:
> On 2009-07-30 16:44, r wrote:
>> On Jul 30, 4:29 pm, Emmanuel Surleau wrote:
1.) No need to use "()" to call a function with no arguments. Python
--> "obj.m2().m3()" --ugly
Ruby --> "obj.m1.m2.m3" -- sweeet!
Man, i
Hi,
I have a problem with my XML parser (created with libraries from
xml.sax package). When parser finds a invalid character (in CDATA
section) for example �, throws an exception SAXParseException.
Is there any way to just ignore this kind of problem. Maybe there is a
way to set up parser in less
Whoops, posted to the wrong address yet again.
I deserve some punishment.
On Fri, Jul 31, 2009 at 5:33 PM, Xavier Ho wrote:
> On Fri, Jul 31, 2009 at 5:25 PM, MalC0de wrote:
>
>>
>> while true :
>>
>> where's the problem,
>
>
> There. =]
>
(Btw, it's True, not true.)
--
http://mail.python
"steve" wrote:
Is there a good way to check if a script is running inside Pythonwin?
Perhaps a property or method that is exposed by that environment?
I don't know how foolproof it is, but this works:
'pywin' in sys.modules
--
http://mail.python.org/mailman/listinfo/python-list
On 30 Jul 2009, at 23:52 , Jan Kaliszewski wrote:
Dnia 30-07-2009 o 22:41:57 Masklinn
napisał(a):
On 30 Jul 2009, at 22:23 , Jan Kaliszewski wrote:
30-07-2009 o 13:36:49 Masklinn wrote:
On 30 Jul 2009, at 06:04 , alex23 wrote:
On Jul 30, 1:06 pm, r wrote:
2.) the .each method
container.e
> Jonathan Gardner (JG) wrote:
>JG> On Jul 30, 5:24 pm, Dhanesh wrote:
>>>
>>> how can I we have a non blocking read ?
>JG> See http://docs.python.org/library/popen2.html#flow-control-issues
>JG> Note well: In the non-blocking world, you have to use select() or poll
>JG> () to get your jo
problem with this code solved in win32, but I didn't test it after
solved problem on gnu/linux .
--
http://mail.python.org/mailman/listinfo/python-list
On Jul 30, 10:16 pm, "Jan Kaliszewski" wrote:
> 30-07-2009 o 12:29:24 Francesco Bochicchio wrote:
>
> > On Jul 30, 5:52 am, NighterNet wrote:
> >> I am trying to figure out how to send text or byte in python 3.1. I am
> >> trying to send data to flash socket to get there. I am not sure how to
>
now I've been encountered to some errors with this snippet :
import sys
from socket import *
serverHost = 'localhost'
serverPort = 50007
message = ['Hello network world']
if len(sys.argv) > 1:
serverHost = sys.argv[1]
if len(sys.argv) > 2:
message = sys.argv[2:]
sockobj = socket(AF
Hi all,
I'm having trouble with multiprocessing I'm using it to speed up some
simulations, I find for large queues when the process reaches the
poison pill it does not exit whereas for smaller queues it works
without any problems. Has anyone else had this trouble? Can anyone
tell me a way around i
On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote:
> now I've been encountered to some errors with this snippet :
And these errors are? Provide error messages and full tracebacks.
Cheers,
Chris
--
http://blog.rebertia.com
--
http://mail.python.org/mailman/listinfo/python-list
On 30 Jul 2009, at 23:57 , Luis Zarrabeitia wrote:
I'd like to ask, what "container.each" is, exactly? It looks like a
function
call (as I've learned a few posts ago), but, what are its arguments?
How the
looping "works"? Does it receive a "code" object that it has to
execute?
Is .each some
On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
> That and the fact that I couldn't stop laughing for long enough to learn
> any more when I read in the Pragmatic Programmer's Guide that "Ruby,
> unlike less flexible languages, lets you alter the value of a constant."
> Yep, as they say "Bug"
On Thursday 30 July 2009 03:09:14 greg wrote:
> Hendrik van Rooyen wrote:
> > And if code is data, where is Pythons ALTER statement?
>
> class Duck:
>
>def quack(self):
> print "Quack!"
>
> def moo():
>print "Moo!"
>
> def ALTER(obj, name, TO_PROCEED_TO):
>setattr(obj, name, TO_PRO
On Fri, Jul 31, 2009 at 6:08 PM, Masklinn wrote:
> ... but since Python doesn't have anonymous functions that usage
> tends to be a bit too verbose ...
>
Sorry to interrupt, but wouldn't lambda in Python be considered as
'anonymous functions'?
--
http://mail.python.org/mailman/listinfo/python-
On Fri, Jul 31, 2009 at 1:21 AM, Xavier Ho wrote:
> On Fri, Jul 31, 2009 at 6:08 PM, Masklinn wrote:
>>
>> ... but since Python doesn't have anonymous functions that usage
>> tends to be a bit too verbose ...
>
> Sorry to interrupt, but wouldn't lambda in Python be considered as
> 'anonymous func
Hello,
According to my experience and from what I've read in other threads,
subprocess isn't easy to use for interactive tasks. I don't really
know, but maybe it wasn't even designed for that at all.
On the other hand, pexpect seems to work fine for interactive use and
even provides a method for
On Fri, Jul 31, 2009 at 6:25 PM, Chris Rebert wrote:
> I believe "full" anonymous functions was intended by the author.
> lambdas are limited to a single expression. "Full" anonymous functions
> would be allowed to contain multiple statements.
>
> Cheers, but what about this:
def goBig(x):
On Fri, Jul 31, 2009 at 1:31 AM, Xavier Ho wrote:
> On Fri, Jul 31, 2009 at 6:25 PM, Chris Rebert wrote:
>>
>> I believe "full" anonymous functions was intended by the author.
>> lambdas are limited to a single expression. "Full" anonymous functions
>> would be allowed to contain multiple statemen
On Jul 31, 12:07 pm, Chris Rebert wrote:
> On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote:
> > now I've been encountered to some errors with this snippet :
>
> And these errors are? Provide error messages and full tracebacks.
>
> Cheers,
> Chris
> --http://blog.rebertia.com
these are errors :
Tr
On Fri, Jul 31, 2009 at 6:38 PM, Chris Rebert wrote:
> No, because it has a name, namely "goBig"; this obviously prevents it
> from being "anonymous".
>
> For comparison, note how the function in the following example is
> never given a name, and is thus anonymous:
> >>> (lambda x: x+5)(6)
> 11
>
On Thursday 30 July 2009 15:20:45 Dave Angel wrote:
> As far as I know, nobody has yet built a microcode implementation of a
> Python VM (Virtual Machine). Nor have I seen one for the Java VM.
Atmel has made an ARM that has support for Java Bytecode.
AT91SAM9X512 and friends (smaller versions)
Hendrik van Rooyen wrote:
The COBOL source was
more obscure, as any jump could have been altered,
and you could not see that until you have read further
on in the program, where the ALTER statement was.
Well, in Python you can pretty much replace any
function with any other function, so you can
> -Original Message-
> From: Dave Angel [mailto:[email protected]]
> Sent: Thursday, July 30, 2009 16:03
> To: Barak, Ron
> Cc: 'Dave Angel'; '[email protected]'
> Subject: RE: Run pyc file without specifying python path ?
>
> Barak, Ron wrote:
> >> -Original Message
Winner, winner, chicken dinner... resolved.
http://wwwsearch.sourceforge.net/mechanize/doc.html
import mechanize
cj = mechanize.MSIECookieJar(delayload=True)
cj.load_from_registry() # finds cookie index file from registry
Thanks Mr Lee!
--
http://mail.python.org/mailman/listinfo/python-list
Sorry
###fortran
call###
is meant to be
###fortran call###
Matt
--
http://mail.python.org/mailman/listinfo/python-list
Robert, Paul, thanks. That was just what I was looking for.
kynn
--
http://mail.python.org/mailman/listinfo/python-list
r wrote:
The purpose of his thread was to get feedback on how Python
and Ruby ideas could be cumulated into the best high level language.
And being that i am the BDFL of the "Confessions of a Python Fanboy"
thread, you have my personal permission to continue on with this
subject matter...,
Ch
On 31 Lip, 09:28, Łukasz wrote:
> Hi,
> I have a problem with my XML parser (created with libraries from
> xml.sax package). When parser finds a invalid character (in CDATA
> section) for example ,
After sending this message I noticed that example invalid characters
are not displaying on some pla
Hi all,
I want to compare two text files line by line and eliminate the
matching/repeated line and store the unmatched/leftout lines into a third
file or overwrite into one of them.
regards
--
http://mail.python.org/mailman/listinfo/python-list
On Fri, Jul 31, 2009 at 7:25 PM, learner learner wrote:
> Hi all,
>
> I want to compare two text files line by line and eliminate the
> matching/repeated line and store the unmatched/leftout lines into a third
> file or overwrite into one of them.
>
Sounds like homework to me. Why not look into:
Ignore this question. Managed to get Amazon Web Services going and
have installed Python 2.6 on there. Thanks for your eyeballs time.
On Jul 31, 7:09 pm, northof40 wrote:
> Hi - I'd really like to have access to Python 2.6 to try something
> out. It needs to be on Linux/Unix machine. I don't mind
learner learner wrote:
> Hi all,
>
> I want to compare two text files line by line and eliminate the
> matching/repeated line and store the unmatched/leftout lines into a
> third file or overwrite into one of them.
gl & hf!
--
http://mail.python.org/mailman/listinfo/python-list
On Fri, Jul 31, 2009 at 2:25 AM, learner learner wrote:
> Hi all,
>
> I want to compare two text files line by line and eliminate the
> matching/repeated line and store the unmatched/leftout lines into a third
> file or overwrite into one of them.
See the `difflib` module:
http://docs.python.org/l
Lucas P Melo wrote:
> Hello, I'm a total noob about the C API. Is there any way to create a
> generator function using the C API? I couldn't find anything like the
> 'yield' keyword in it.
>
> Thanks in advance.
You define a new type with tp_flags including Py_TPFLAGS_HAVE_ITER.
Anything tha
On 31 Jul 2009, at 10:25 , Chris Rebert wrote:
On Fri, Jul 31, 2009 at 1:21 AM, Xavier Ho
wrote:
On Fri, Jul 31, 2009 at 6:08 PM, Masklinn
wrote:
... but since Python doesn't have anonymous functions that
usage
tends to be a bit too verbose ...
Sorry to interrupt, but wouldn't lambda
On Jul 31, 8:28 am, Steven D'Aprano wrote:
> On Thu, 30 Jul 2009 18:06:31 -0500, Robert Kern wrote:
> > On 2009-07-30 16:44, r wrote:
> >> On Jul 30, 4:29 pm, Emmanuel Surleau wrote:
> 1.) No need to use "()" to call a function with no arguments. Python
> --> "obj.m2().m3()" --ugly
> >>
> MalC0de (M) wrote:
>M> On Jul 31, 12:07 pm, Chris Rebert wrote:
>>> On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote:
>>> > now I've been encountered to some errors with this snippet :
>>>
>>> And these errors are? Provide error messages and full tracebacks.
>>>
>>> Cheers,
>>> Chris
>>> -
> ma3mju (m) wrote:
>m> Hi all,
>m> I'm having trouble with multiprocessing I'm using it to speed up some
>m> simulations, I find for large queues when the process reaches the
>m> poison pill it does not exit whereas for smaller queues it works
>m> without any problems. Has anyone else had th
On 31 Jul 2009, at 11:54 , Iain King wrote:
On Jul 31, 8:28 am, Steven D'Aprano wrote:
On Thu, 30 Jul 2009 18:06:31 -0500, Robert Kern wrote:
On 2009-07-30 16:44, r wrote:
On Jul 30, 4:29 pm, Emmanuel Surleau
wrote:
1.) No need to use "()" to call a function with no arguments.
Python
-->
ma3mju wrote:
Hi all,
I'm having trouble with multiprocessing I'm using it to speed up some
simulations, I find for large queues when the process reaches the
poison pill it does not exit whereas for smaller queues it works
without any problems. Has anyone else had this trouble? Can anyone
tell m
On Friday 31 July 2009 11:25:17 learner learner wrote:
> Hi all,
>
> I want to compare two text files line by line and eliminate the
> matching/repeated line and store the unmatched/leftout lines into a third
> file or overwrite into one of them.
This is not as simple as it seems.
You will probab
MalC0de schrieb:
On Jul 31, 12:07 pm, Chris Rebert wrote:
On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote:
now I've been encountered to some errors with this snippet :
And these errors are? Provide error messages and full tracebacks.
Cheers,
Chris
--http://blog.rebertia.com
these are errors
MalC0de schrieb:
On Jul 31, 12:07 pm, Chris Rebert wrote:
On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote:
now I've been encountered to some errors with this snippet :
And these errors are? Provide error messages and full tracebacks.
Cheers,
Chris
--http://blog.rebertia.com
these are errors
Steven D'Aprano a écrit :
On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
That and the fact that I couldn't stop laughing for long enough to learn
any more when I read in the Pragmatic Programmer's Guide that "Ruby,
unlike less flexible languages, lets you alter the value of a constant."
Ye
Hi all. I think I fixed this problem by setting fileLogger.propagate =
0. Otherwise it will propagate up to the root logger, which outputs to
stdout, as far as I can understand.
On 31 Jul 2009, at 01:17, Jannik Sundø wrote:
Dear all, I am quite confused about the Python logging. I have read
you want to say shall i disable the firewall, there's no specific
firewall or IPS/IDS system out there, this is just windows xp firewall
--
http://mail.python.org/mailman/listinfo/python-list
MalC0de schrieb:
you want to say shall i disable the firewall, there's no specific
firewall or IPS/IDS system out there, this is just windows xp firewall
Which is a firewall, don't you agree? So it could well be the reason for
the problems you see.
Diez
--
http://mail.python.org/mailman/lis
On 31 Jul 2009, at 13:38 , Bruno Desthuilliers wrote:
Steven D'Aprano a écrit :
On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
That and the fact that I couldn't stop laughing for long enough to
learn
any more when I read in the Pragmatic Programmer's Guide that "Ruby,
unlike less flexibl
On Jul 31, 12:41 pm, Jannik Sundø wrote:
> Hi all. I think I fixed this problem by setting fileLogger.propagate =
> 0. Otherwise it will propagate up to the root logger, which outputs to
> stdout, as far as I can understand.
>
Only if you specifically configure it to do so - for example, call
no, I disabled my firewall, no problem with even enabled firewall ...
no one can help !?
--
http://mail.python.org/mailman/listinfo/python-list
Hendrik van Rooyen wrote:
On Friday 31 July 2009 11:25:17 learner learner wrote:
Hi all,
I want to compare two text files line by line and eliminate the
matching/repeated line and store the unmatched/leftout lines into a third
file or overwrite into one of them.
This is not as simple
Jannik Sundø wrote:
Hi all. I think I fixed this problem by setting fileLogger.propagate =
0. Otherwise it will propagate up to the root logger, which outputs to
stdout, as far as I can understand.
On 31 Jul 2009, at 01:17, Jannik Sundø wrote:
Dear all, I am quite confused about the Python l
MalC0de wrote:
no, I disabled my firewall, no problem with even enabled firewall ...
no one can help !?
I hope you disconnected your computer from the internet before disabling
the firewall...
--
http://mail.python.org/mailman/listinfo/python-list
Masklinn a écrit :
On 31 Jul 2009, at 13:38 , Bruno Desthuilliers wrote:
Steven D'Aprano a écrit :
On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
That and the fact that I couldn't stop laughing for long enough to
learn
any more when I read in the Pragmatic Programmer's Guide that "Ruby,
On Jul 31, 2:37 pm, MalC0de wrote:
> no, I disabled my firewall, no problem with even enabled firewall ...
> no one can help !?
Connection refused... connection was refused by the listening socket,
it could also be due to the settings of your service, if it accepts
only from localhost to localhos
On Jul 30, 4:47 pm, "Barak, Ron" wrote:
> > -Original Message-
> > From: Dave Angel [mailto:[email protected]]
> > Sent: Thursday, July 30, 2009 16:03
> > To: Barak, Ron
> > Cc: 'Dave Angel'; '[email protected]'
> > Subject: RE: Run pyc file without specifying python path ?
>
>
On 31 Jul 2009, at 15:12 , Bruno Desthuilliers wrote:
Masklinn a écrit :
On 31 Jul 2009, at 13:38 , Bruno Desthuilliers wrote:
Steven D'Aprano a écrit :
On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
That and the fact that I couldn't stop laughing for long enough
to learn
any more when
gregorth wrote:
for a scientific application I need to save a video stream to disc for
further post processing. My cam can deliver 8bit grayscale images with
resolution 640x480 with a framerate up to 100Hz, this is a data rate
of 30MB/s. Writing the data uncompressed to disc hits the data
transfe
none of you can't interpret it ? do you have errors like me !?
--
http://mail.python.org/mailman/listinfo/python-list
Does Python have a formal policy on the support lifetime (bug fixes,
security fixes, etc.) for major and minor versions? I did a bit of
searching on the Python web site and this group, but didn't find
anything. If there is a policy posted somewhere (and I just didn't
dig deep enough), would someo
On Jul 31, 2:09 am, "steve" wrote:
> Is there a good way to check if a script is running inside Pythonwin?
> Perhaps a property or method that is exposed by that environment?
I've used
if sys.stdin.fileno() < 0:
This is not precisely a test for pythonwin, but indicates whether
standard streams
Steven D'Aprano wrote:
On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
That and the fact that I couldn't stop laughing for long enough to learn
any more when I read in the Pragmatic Programmer's Guide that "Ruby,
unlike less flexible languages, lets you alter the value of a constant."
Yep,
MRAB wrote:
Ethan Furman wrote:
Marcus Wanner wrote:
Wow, I really need to learn more about regexp...
Any tutorials you guys can recommend?
Marcus
Mastering Regular Expressions
Powerful Techniques for Perl and Other Tools
By Jeffrey E. F. Friedl
Great book!
+1
I have the first edition,
On Jul 31, 4:08 pm, Ethan Furman wrote:
> Steven D'Aprano wrote:
> > On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
>
> >>That and the fact that I couldn't stop laughing for long enough to learn
> >>any more when I read in the Pragmatic Programmer's Guide that "Ruby,
> >>unlike less flexible
On Fri, Jul 31, 2009 at 11:35 AM, Iain King wrote:
> On Jul 31, 4:08 pm, Ethan Furman wrote:
>> Steven D'Aprano wrote:
>> > On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
>>
>> >>That and the fact that I couldn't stop laughing for long enough to learn
>> >>any more when I read in the Pragmati
On Fri, 31 Jul 2009 13:38:56 +0200, Bruno Desthuilliers wrote:
>> On the other hand, we don't have to prefix names with @ and @@,
>
> Nope, we have to prefix them with 'self' or 'cls' (or even
> 'self.__class__').
Incorrect.
>>> class K:
... class_attribute = 'No @@ required.'
...
>>> K().c
On 31 Jul 2009, at 17:55 , Steven D'Aprano wrote:
But seriously, while I admit that I have very little Ruby
experience, and
so aren't in a great position to judge, it seems to me that Ruby
doesn't
have anything like Python's over-riding design principles (the Zen).
If
there is a design prin
Masklinn wrote:
#each is simply a method that takes a function (called blocks in ruby).
One could call it a higher-order method I guess.
It's an implementation of the concept of internal iteration: instead of
collections yielding iterator objects, and programmers using those
through speciall
On Jul 30, 4:41 pm, Loïc Domaigné
wrote:
> Hi,
>
> > Hello. I have written a Python 3.1 script running on Windows that uses
> > os.path.exists() to connect to network shares. If the various network
> > shares require different user account and password combos than the
> > account the script is run
Gary Wilson wrote:
Does Python have a formal policy on the support lifetime (bug fixes,
security fixes, etc.) for major and minor versions? I did a bit of
searching on the Python web site and this group, but didn't find
anything. If there is a policy posted somewhere (and I just didn't
dig deep
I been trying to find a way to check the socket is open or not. The
thread are in a group and loop if the sockets are open. If they are
not open delete the thread and remove the group. I need on this.
--
http://mail.python.org/mailman/listinfo/python-list
gregorth writes:
> I am a novice with video encoding. I found that few codecs support
> gray scale images. Any hints to take advantage of the fact that I only
> have gray scale images?
I don't know that there's any good way around the fact that video
encoding is simply one of the heavier CPU-bou
2009/7/31 Steven D'Aprano :
> On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
>
>> That and the fact that I couldn't stop laughing for long enough to learn
>> any more when I read in the Pragmatic Programmer's Guide that "Ruby,
>> unlike less flexible languages, lets you alter the value of a co
On Jul 31, 3:49 am, Masklinn wrote:
> On 31 Jul 2009, at 10:25 , Chris Rebert wrote:> On Fri, Jul 31, 2009 at 1:21
> AM, Xavier Ho
> > wrote:
> >> On Fri, Jul 31, 2009 at 6:08 PM, Masklinn
> >> wrote:
>
> >>> ... but since Python doesn't have anonymous functions that
> >>> usage
> >>> tend
On Jul 22, 7:55 am, Duncan Booth wrote:
> I find it interesting that the heapq functions tell you in the
> documentation that they aren't suitable for use where n==1 or where n is
> near the total size of the sequence whereas random.sample() chooses what it
> thinks is the best algorithm based on
En Fri, 31 Jul 2009 13:35:10 -0300, NighterNet
escribió:
I been trying to find a way to check the socket is open or not. The
thread are in a group and loop if the sockets are open. If they are
not open delete the thread and remove the group. I need on this.
What means an "open socket"? Do y
On 7/31/2009 12:35 PM, NighterNet wrote:
I been trying to find a way to check the socket is open or not. The
thread are in a group and loop if the sockets are open. If they are
not open delete the thread and remove the group. I need on this.
Being a bit more specific would help.
Are you using t
En Fri, 31 Jul 2009 06:25:17 -0300, learner learner
escribió:
I want to compare two text files line by line and eliminate the
matching/repeated line and store the unmatched/leftout lines into a third
file or overwrite into one of them.
Look at the difflib module: http://docs.python.org/libr
On Jul 22, 4:55 am, Duncan Booth wrote:
> Steven D'Aprano wrote:
> > But that's the wrong solution to the problem. The OP wants the largest
> > (or smallest) item, which he expects to get by sorting, then grabbing
> > the first element:
>
> > sorted(alist)[0]
>
> > That requires sorting the entir
On Jul 31, 10:23 am, "Gabriel Genellina"
wrote:
> En Fri, 31 Jul 2009 13:35:10 -0300, NighterNet
> escribió:
>
> > I been trying to find a way to check the socket is open or not. The
> > thread are in a group and loop if the sockets are open. If they are
> > not open delete the thread and remov
According to http://docs.python.org/library/heapq.html, Python 2.5
added an optional "key" argument to heapq.nsmallest and
heapq.nlargest. I could never understand why they didn't also add a
"key" argument to the other relevant functions (heapify, heappush,
etc). Say I want to maintain a heap of (x
On Jul 20, 9:27 am, Phillip B Oldham wrote:
> Specifically the "differences" between lists and tuples have us
> confused and have caused many "discussions" in the office. We
> understand that lists are mutable and tuples are not, but we're a
> little lost as to why the two were kept separate from
On Jul 31, 10:44 am, Joshua Bronson wrote:
> Say I want to maintain a heap of (x, y) pairs sorted only by
> first coordinate. Without being able to pass key=itemgetter(0), won't
> heapifying a list of such pairs unnecessarily compare both
> coordinates?
It will compare the second value only if th
I did a search within this group, but couldn't find any information on
this.
I am sending base64 encoded data as the content over http using
urllib2 urlopen. When I receive the data and attempt to decode it, I
get an "Incorrect Padding" error. Is there a simple way to fix this? A
better way to sen
On 31 Jul 2009, at 18:24 , Terry Reedy wrote:
Masklinn wrote:
#each is simply a method that takes a function (called blocks in
ruby). One could call it a higher-order method I guess.
It's an implementation of the concept of internal iteration:
instead of collections yielding iterator objects
On Fri, 31 Jul 2009 18:15:15 +0200, Masklinn wrote:
> > I know, I know, Ruby people swear by
> > anonymous code blocks, and I've read Paul Graham too. But I'm really
> > not so sure that the benefits of anonymous code blocks are great
> > enough to overcome the disadvantages of anonymous code bloc
Hi
I want to create an instance of dcCursor which inherits from
dcObject. When I run the following code it gives the error shown.
Can some explain to me what is wrong? I have included the dcObject.py
and dcCursor.py below.
>>>import dcObject
>>> import dcCursor
>>> x = dcCursor.dcCursor()
Traceb
On Thu, 30 Jul 2009 15:40:37 -0700, Robert Dailey wrote:
> Anyone know of a way to print text in Python 3.1 with colors in a
> portable way? In other words, I should be able to do something like
> this:
>
> print_color( "This is my text", COLOR_BLUE )
>
> And this should be portable (i.e. it sho
Simon wrote:
Hi
I want to create an instance of dcCursor which inherits from
dcObject. When I run the following code it gives the error shown.
Can some explain to me what is wrong? I have included the dcObject.py
and dcCursor.py below.
import dcObject
import dcCursor
x = dcCursor.dcCursor()
Mornin'! and a good one, too, I hope.
Question for you...
First part of the question: What is the general value in having Null
capability for fields?
Second part: Is there a tangible difference between Null, and the
nothing of 0, '', False, etc, in python?
Third part: If there is a tan
On Friday 31 July 2009 18:54:23 Tim Rowe wrote:
> 2009/7/31 Steven D'Aprano :
> > On Thu, 30 Jul 2009 18:47:04 +0100, Tim Rowe wrote:
> >> That and the fact that I couldn't stop laughing for long enough to learn
> >> any more when I read in the Pragmatic Programmer's Guide that "Ruby,
> >> unlike l
On Friday 31 July 2009 19:49:04 Raymond Hettinger wrote:
> On Jul 20, 9:27 am, Phillip B Oldham wrote:
> > Specifically the "differences" between lists and tuples have us
> > confused and have caused many "discussions" in the office. We
> > understand that lists are mutable and tuples are not, but
Brandon Fredericks wrote:
> I did a search within this group, but couldn't find any information on
> this.
>
> I am sending base64 encoded data as the content over http using
> urllib2 urlopen. When I receive the data and attempt to decode it, I
> get an "Incorrect Padding" error. Is there a simp
On 31 Jul 2009, at 20:17 , Steven D'Aprano wrote:
On Fri, 31 Jul 2009 18:15:15 +0200, Masklinn wrote:
I know, I know, Ruby people swear by
anonymous code blocks, and I've read Paul Graham too. But I'm really
not so sure that the benefits of anonymous code blocks are great
enough to overcome the
On 31 Jul 2009, at 20:48 , Emmanuel Surleau wrote:
On Friday 31 July 2009 19:49:04 Raymond Hettinger wrote:
On Jul 20, 9:27 am, Phillip B Oldham
wrote:
Specifically the "differences" between lists and tuples have us
confused and have caused many "discussions" in the office. We
understand that
On Jul 31, 2:02 pm, Jonathan Gardner
wrote:
> On Jul 31, 10:44 am, Joshua Bronson wrote:
>
> > Say I want to maintain a heap of (x, y) pairs sorted only by
> > first coordinate. Without being able to pass key=itemgetter(0), won't
> > heapifying a list of such pairs unnecessarily compare both
> >
1 - 100 of 167 matches
Mail list logo