On May 16, 3:25 am, MRAB wrote:
> Chris Rebert wrote:
> > On Fri, May 15, 2009 at 9:12 AM, wrote:
> >> How do you parse a string enclosed in Curly Braces?
>
> >> For instance:
>
> >> x = "{ABC EFG IJK LMN OPQ}"
>
> >> I want to do x.split('{} ') and it does not work. Why does it not work
> >> an
In tkinter, when I place a photoimage on a button and disable the
button, the image has background dots scattered through the image.
Searching the web, I wasn't able to find any documentation on this
behavior, nor how to turn it off. So here I am. How do I keep this
from happening?
Also, how can I
On Fri, 15 May 2009 12:50:59 +0100, anuraguni...@yahoo.com
wrote:
try:
raise "abc"
except:
e, t, tb = sys.exc_info()
if not isinstance(e, str):
raise
print "caught", e
This seems to be the solution, thanks
Do be aware that string exceptions are going away, so at
On 15May2009 13:36, <> wrote:
| "anuraguni...@yahoo.com" writes:
| > there are many such exceptions and hence it is not feasible to catch
| > them all or know them all unless i go thru src code.
|
| But that is true of all exceptions. The alternative seems to be a
| "checked exception" scheme l
In Chris Rebert
writes:
>Take a look at inspect.getargspec(func):
>http://docs.python.org/library/inspect.html#inspect.getargspec
Thank you much, that did the trick. And inspect is a very handy
module to know about.
kynn
--
NOTE: In my address everything before the first period is backwards
On Fri, 15 May 2009 17:12:24 +0100, wrote:
How do you parse a string enclosed in Curly Braces?
For instance:
x = "{ABC EFG IJK LMN OPQ}"
I want to do x.split('{} ') and it does not work. Why does it not work
and what are EXCEPTIONS to using the split method?
Other people have already done
In <99246143-a853-4041-bc45-eeb648388...@r3g2000vbp.googlegroups.com> Carl
Banks writes:
>On May 14, 1:26=A0pm, kj wrote:
>> I've written a tiny module that I'd like to make available online
>> from my website. =A0This module is not "production-grade" code; it
>> is meant only as an illustratio
On Fri, 15 May 2009 14:58:16 +0100, wrote:
hello, I´m a student of linguistic an I need do this exercises. Can
anybody help me,please?
Thanks
Sorry, we're allergic to homework. If you've got any more specific
questions about how bits of Python work, do ask, but don't ask us to
do your assign
I'm happy to announce that ActivePython 2.6.2.2, 3.1.0b1.0 and 2.5.4.4
are now available for download from:
http://www.activestate.com/activepython/
This is a patch release that updates ActivePython to core Python 2.6.2
and 3.1b2. This release also contains updates to Tcl/Tk 8.5.7 and Tix
8
> I want to compile a minimal Python 2.6 for Debian Etch without support
> for optional features such as tk and sphinx. The configure script's
> help says that features can be disabled with an '--without-PACKAGE', so
> I guess disabling tk is '--without-tk', but where is there a list of the
> feat
norseman wrote:
Marco
Mariani wrote:
Gediminas Kregzde wrote:
def doit(i):
pass
def main():
a = [0] * 1000
t = time()
map(doit, a)
print "map time: " + str(time() - t)
Here you are calling a function ten million times, build a list with
of ten million None results, then
En Fri, 15 May 2009 09:04:05 -0300, Igor Katson escribió:
Lawrence D'Oliveiro wrote:
In message , Igor
Katson wrote:
Lawrence D'Oliveiro wrote:
In message , Igor
Katson wrote:
I have problems in getting a SocketServer to shutdown.
Do you want to do a shutdown or a close?
I want the se
This really isn't the fault of the "feedparser" module, but it's
worth mentioning.
I have an application which needs to read each new item from a feed
as it shows up, as efficiently as possible, because it's monitoring multiple
feeds. I want exactly one copy of each item as it comes in.
Hello all. Can anyone explain why this creates a list containing a
dictionary:
[{'a': 'b', 'foo': 'bar'}]
But this creates a list of keys of the dictionary:
list({ "a": "b", "foo": "bar" })
I expected them to be equivalent but clearly they're not! I'm using Python
2.6.1 if that helps.
-s
En Fri, 15 May 2009 16:39:41 -0300, Trevor
escribió:
Can a Tkinter application create a COM object and keep its own window
on top of it?
excel = win32com.client.Dispatch('Excel.Application')
I would like the user to be able to see and interact with the Excel
application but keep the Tkinter
En Fri, 15 May 2009 12:03:09 -0300, Rustom Mody
escribió:
I am trying to talk to a server that runs on localhost
The server runs on http://localhost:7000/ and that opens alright in a
web browser.
However if I use urlopen or urlretrieve what I get is this 'file' --
obviously not the one that
En Fri, 15 May 2009 17:58:55 -0300, eye zak
escribió:
I have a situation where i want a tuple from a generator/sequence
comprehension.
I am wondering, is this possible ? or is this just a bad idea all
together?
class iterator(object):
__slots__ = ('__iters',)
def __init__(self,*a
What is WinAppDbg?
==
The WinAppDbg python module allows developers to quickly code
instrumentation
scripts in Python under a Windows environment.
It uses ctypes to wrap many Win32 API calls related to debugging, and
provides
an object-oriented abstraction layer to manipulate thre
En Fri, 15 May 2009 15:09:45 -0300, Edd escribió:
As the comment on the last line indicates, looking at the .value() of
a Future may give the return value of the associated task, or it may
also propagate an exception that was raised in a child thread.
Inside the implementation I store caught e
In article
,
Sam Tregar wrote:
> Can anyone explain why this creates a list containing a
> dictionary:
> [{'a': 'b', 'foo': 'bar'}]
> But this creates a list of keys of the dictionary:
> list({ "a": "b", "foo": "bar" })
The first example is a list, expressed as a list display literal,
con
En Fri, 15 May 2009 12:35:09 -0300, escribió:
Using Python 2.6 or higher: Is there a way to configure
string.Template() to ignore the case of matched identifiers?
In other words, given the following Template string and
dictionary where all keys are lowercase, is there a way to have
my identifie
En Fri, 15 May 2009 22:17:43 -0300, Sam Tregar escribió:
Hello all. Can anyone explain why this creates a list containing a
dictionary:
[{'a': 'b', 'foo': 'bar'}]
But this creates a list of keys of the dictionary:
list({ "a": "b", "foo": "bar" })
I expected them to be equivalent but cl
En Fri, 15 May 2009 18:32:57 -0300, Esmail escribió:
Can anyone point to on the web, or possibly share a simple example
of the use of the ConfigParser module?
The (excellent!) article series by Doug Hellmann, "Python Module of the
Week", covers ConfigParser (and almost the whole standard li
Zhenhai Zhang wrote:
a: ['a', 1, 3, 4]
c: ['c' '2' '3' '4']
The lack of commas here suggests that c is actually
a numpy array rather than a list.
Did you import copy from Numeric or numpy, by any
chance?
The following experiment reproduces your result:
>>> import numpy
>>> a = ['a', 1, 2, 3
On 2009-05-14 16:18:07 -0700, CTO said:
On May 14, 7:01 pm, TomF wrote:
I'm looking for a medium-sized Python system with very good coding
style and good code organization, so I can learn from it. I'm reading
various books on Python with advice on such things but I'd prefer to
see a real sys
Gabriel Genellina wrote:
En Fri, 15 May 2009 09:04:05 -0300, Igor Katson escribió:
Lawrence D'Oliveiro wrote:
In message ,
Igor Katson wrote:
Lawrence D'Oliveiro wrote:
In message ,
Igor Katson wrote:
I have problems in getting a SocketServer to shutdown.
Do you want to do a shutdown or
101 - 126 of 126 matches
Mail list logo