Carl Banks wrote:
I'm surprised there is anyone who still gives castironpi credit for
being fully human.
His recent posts have generally been quite different from those of some
months ago. Even he recognizes that they were somewhat weird and has
tried to do better.
Did he ever make any de
On Sep 12, 6:38 pm, [EMAIL PROTECTED] wrote:
> Hello!
>
> I wanted to get the full contents of a character array stored in a
> struct, i.e.
> _fields_ = [...("array", c_char * 12)...]
> however, ctypes seems to try to return struct.array as a Python string
> rather than a character array, and stops
On Sep 12, 8:16 am, Steve Holden <[EMAIL PROTECTED]> wrote:
> castironpi wrote:
> > On Sep 7, 5:03 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
> >> On Mon, 08 Sep 2008 07:34:55 +1000, James Mills wrote:
> >>> This is the strangest post I've seen
> >>> since I've joined this list (only
>
On Sep 12, 12:35 pm, Fredrik Lundh <[EMAIL PROTECTED]> wrote:
> Steve Holden wrote:
> > The defence rests.
>
> can you please stop quoting that guy, so we don't have to killfile you
> as well...
Guy?
Carl Banks
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 12, 9:08 pm, [EMAIL PROTECTED] wrote:
> First off, I'm a python n00b, so feel free to comment on anything if
> I'm doing it "the wrong way." I'm building a discrete event simulation
> tool. I wanted to use coroutines. However, I want to know if there's
> any way to hide a yield statement.
>
Hi,
The menubar of OS X is showing the application name as Python instead
of the name of my wxpython gui app. How do I make my application name
show-up in the menu bar?
Thanks!
Erik
--
http://mail.python.org/mailman/listinfo/python-list
Duncan Booth <[EMAIL PROTECTED]> wrote:
>
>The not too scientific test I did was to copy the font embedding example
>from the Reportlab documentation, modify it enough to make it actually
>run, and then change the output to have only one glyph. The resulting
>PDF is virtually identical. I'm not
On Sep 12, 8:08 pm, [EMAIL PROTECTED] wrote:
> First off, I'm a python n00b, so feel free to comment on anything if
> I'm doing it "the wrong way." I'm building a discrete event simulation
> tool. I wanted to use coroutines. However, I want to know if there's
> any way to hide a yield statement.
>
Insider information, fackbook labs open today, we the first to
register!
www.fackbooklabs.com
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 12, 6:08 pm, "Chris Rebert" <[EMAIL PROTECTED]> wrote:
> I've heard good things about The Django Book:http://www.djangobook.com/
> - Chris
>
>
>
> On Fri, Sep 12, 2008 at 5:57 PM, bhaarat Sharma <[EMAIL PROTECTED]> wrote:
> > Hi Guys,
>
> > I am very new to python. I am looking for a good b
On Saturday 13 September 2008 01:04, sturlamolden wrote:
> On Sep 12, 8:33 pm, [EMAIL PROTECTED] (Al Dykes) wrote:
>
>> OK, what are my choices for an IDE/GUI development tool that runs on XP?
[...]
> Cpython with PyQt: BlackAdder
People using this combination apparently prefer Eric, these day
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On behalf of the Python development team and the Python community, I
am happy to announce the first release candidate for Python 2.6.
This is a release candidate, so while it is not suitable for
production environments, we strongly encourage you
That will be concentrating more on the Django framework
On Fri, Sep 12, 2008 at 6:08 PM, Chris Rebert <[EMAIL PROTECTED]> wrote:
> I've heard good things about The Django Book: http://www.djangobook.com/
> - Chris
>
> On Fri, Sep 12, 2008 at 5:57 PM, bhaarat Sharma <[EMAIL PROTECTED]>
> wrote:
>
First off, I'm a python n00b, so feel free to comment on anything if
I'm doing it "the wrong way." I'm building a discrete event simulation
tool. I wanted to use coroutines. However, I want to know if there's
any way to hide a yield statement.
I have a class that I'd like to look like this:
class
I've heard good things about The Django Book: http://www.djangobook.com/
- Chris
On Fri, Sep 12, 2008 at 5:57 PM, bhaarat Sharma <[EMAIL PROTECTED]> wrote:
> Hi Guys,
>
> I am very new to python. I am looking for a good book about python web
> programming.
>
> I looked at a few online like Web Pr
Hi Guys,
I am very new to python. I am looking for a good book about python web
programming.
I looked at a few online like Web Programming In Python but most are quite
old.
If you've read a good book on python web programming can you please suggest
some?
Thanks
--
http://mail.python.org/mailma
On Sep 12, 11:15 pm, Matt Nordhoff <[EMAIL PROTECTED]> wrote:
> Steven D'Aprano wrote:
> > On Thu, 11 Sep 2008 17:27:33 +0200, Sjoerd Mullender wrote:
>
> >> When mail messages bounce, the MTA (Message Transfer Agent--the program
> >> that handles mail) *should* send the bounce message to whatever
Grant Edwards wrote:
> On 2008-09-12, Matt Nordhoff <[EMAIL PROTECTED]> wrote:
>
>> I think you misunderstand. He's referring to the Sender
>> header, not the From header. The messages the listbot sends
>> out have a Sender header of
>> "[EMAIL PROTECTED]" (supposing
>> the subscriber's email addr
Hello!
I wanted to get the full contents of a character array stored in a
struct, i.e.
_fields_ = [...("array", c_char * 12)...]
however, ctypes seems to try to return struct.array as a Python string
rather than a character array, and stops as soon as it encounters a
null within the character arra
On 2008-09-12, Matt Nordhoff <[EMAIL PROTECTED]> wrote:
> I think you misunderstand. He's referring to the Sender
> header, not the From header. The messages the listbot sends
> out have a Sender header of
> "[EMAIL PROTECTED]" (supposing
> the subscriber's email address is [EMAIL PROTECTED]). Bou
On Sep 11, 11:07 am, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote:
> i3dmasterschrieb:
>
> > Is there a feature in distutils or easy_install to specify what
> > version of python that the target package can be installed? For
> > example, if a package has a module that only needed if the python
> >
On Sep 12, 8:33 pm, [EMAIL PROTECTED] (Al Dykes) wrote:
> OK, what are my choices for an IDE/GUI development tool that runs on XP?
That depends on the GUI toolkit you are using. My suggestion:
CPython with wxPython: wxFormBuilder
Cpython with PyQt: BlackAdder
CPython with PyGTK: GLADE 3
Jytho
On Sep 12, 11:08 am, Bojan Mihelac <[EMAIL PROTECTED]> wrote:
> Hi all - when trying to set some dynamic attributes in class, for
> example:
>
> class A:
> for lang in ['1', '2']:
> exec('title_%s = lang' % lang) #this work but is ugly
> # setattr(A, "title_%s" % lang, lang) # t
> (1) Would CPython be a good choice for this? How about iron python? How
> about Jython (probably not).
You can use CPython without any problems. Alternatives are pywin32,
ctypes, cython, pyrex, Python C API.
You can use .NET platform invoke from IronPython.
You can use JNI from Jython, or an
Steven D'Aprano wrote:
> On Thu, 11 Sep 2008 17:27:33 +0200, Sjoerd Mullender wrote:
>
>> When mail messages bounce, the MTA (Message Transfer Agent--the program
>> that handles mail) *should* send the bounce message to whatever is in
>> the Sender header, and only if that header does not exist, s
On Sep 12, 10:01 am, Hrvoje Niksic <[EMAIL PROTECTED]> wrote:
> Chris <[EMAIL PROTECTED]> writes:
> >> descr = GetAttrString(cls,"varname");
> >> offset = descr->d_member->offset;
> >> slotvar = (PyObject*)(((char*)obj)+offset)
>
> > Unfortunately, I am inexperienced at this kind of thing, so I was
Greg Lindstrom wrote:
Hello,
I would like to create and manipulate Open Office documents using
Python. I have found then UNO Python page and odfpy modules which
seem to be exactly what I need. The odfpy manual is, to me, a
confusing list of objects and methods (it's an impressive list!), bu
Eric,Fredrik,
Many thanks for your prompt advice, it was a 'better safe than sorry' type
of question.
Don
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 12, 4:30 pm, Bojan Mihelac <[EMAIL PROTECTED]> wrote:
> On Sep 12, 5:21 pm, Christian Heimes <[EMAIL PROTECTED]> wrote:
>
> > Bojan Mihelac wrote:
> > > I guess A class not yet exists in line 4. Is it possible to achive
> > > adding dynamic attributes without using exec?
>
> > Correct, the c
On Sep 8, 5:05 am, Praveena P <[EMAIL PROTECTED]> wrote:
> Hi folks,
>
> I am new to Python... so am not too sure about how the type conversion
> works.
>
> I have to read a file that contains hexadecimal data and use the data
> further to do some arithmetic calculations.
> A sample of the input is
I am trying to build lxml package in SunOS 5.10. I got the following
errors. Does anybody know why?
$ python setup.py build
Building lxml version 2.1.
NOTE: Trying to build without Cython, pre-generated 'src/lxml/
lxml.etree.c' needs to be available.
Using build configuration of libxslt 1.1.7
Buil
Matt Nordhoff:
> BTW, I could easily be wrong, but I think C behaves the same way as Python.
C syntax has many traps that are much better out of modern languages
like Python/D/etc.
I think C has that feature because it lacks an operator for string
concatenation, while both Python and D have one (
Matt Nordhoff:
> It's useful when wrapping a line. For lack of better lorem ipsum:
>
> whatever = some_function("Your mistake is caused by Python not "
> "following one of its general rules:\n\n"
> "Explicit is better than implicit.")
>
> You can a
On Sep 12, 1:33 pm, [EMAIL PROTECTED] (Al Dykes) wrote:
> In article <[EMAIL PROTECTED]>,
> Alan Franzoni <[EMAIL PROTECTED]> wrote:
>
> >zamil was kind enough to say:
>
> >[cut]
>
> >If your needs are very basic, you can stick with the tk module that comes
> >with python. It's not really feature-
On Sep 12, 3:51 pm, John Machin <[EMAIL PROTECTED]> wrote:
> On Sep 13, 5:36 am, byron <[EMAIL PROTECTED]> wrote:
>
>
>
> > I am reading o'reilly's learning python (great book), but i came
> > across an example (pg 291, pdf) that I am not quite understanding the
> > reasoning for the author's expla
On Sep 13, 12:52 am, Fredrik Lundh <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> > multipleSpaces = re.compile(u'\\h+')
>
> > importantTextString = '\n \n \n \t\t '
> > importantTextString = multipleSpaces.sub("M", importantTextString)
>
> what's "\\h" supposed to mean?
Match *h*orizo
Al Dykes wrote:
In article <[EMAIL PROTECTED]>,
Alan Franzoni <[EMAIL PROTECTED]> wrote:
zamil was kind enough to say:
[cut]
If your needs are very basic, you can stick with the tk module that comes
with python. It's not really feature-packed, but it's maintained and pretty
cross-platform.
[EMAIL PROTECTED] wrote:
> Ben Keshet:
>> ...wrong. I thought I should omit the comma and didn't put it. I guess
>> that stating the obvious should be the first attempt with beginners like
>> me. Thanks for thinking about it (it's running perfect now).
>
> In CLisp, Scheme etc, lists such comma
On Sep 13, 5:36 am, byron <[EMAIL PROTECTED]> wrote:
> I am reading o'reilly's learning python (great book), but i came
> across an example (pg 291, pdf) that I am not quite understanding the
> reasoning for the author's explanation:
>
> if f1() or f2():
>
> The author states that do to the nature
Note the parentheses after f1 and f2 in the second example. That's
what calls the functions and causes them to be evaluated and run.
- Chris
Sent from my iPod
On Sep 12, 2008, at 12:36 PM, byron <[EMAIL PROTECTED]> wrote:
I am reading o'reilly's learning python (great book), but i came
acro
byron a écrit :
I am reading o'reilly's learning python (great book), but i came
across an example (pg 291, pdf) that I am not quite understanding the
reasoning for the author's explanation:
if f1() or f2():
The author states that do to the nature of that expression, if f1()
returns True, f2()
I am reading o'reilly's learning python (great book), but i came
across an example (pg 291, pdf) that I am not quite understanding the
reasoning for the author's explanation:
if f1() or f2():
The author states that do to the nature of that expression, if f1()
returns True, f2() will not be evalua
> Anybody here that had the same problem and solved it?
Did you install the 32-bit or the 64-bit installer?
If the 64-bit installer, did you also install 32-bit or 64-bit
installers for iPython, PIL, and easy_install?
If you try to use 32-bit extensions or installers to locate a 64-bit
Python, t
Ben Keshet:
> ...wrong. I thought I should omit the comma and didn't put it. I guess
> that stating the obvious should be the first attempt with beginners like
> me. Thanks for thinking about it (it's running perfect now).
In CLisp, Scheme etc, lists such commas aren't necessary, but in
Python
I am getting an Internal Server Error 500 when i run my client code. I am
trying to call a function at the server side which for now only returns a
string. Meanwhile this calling i also set the header of HTTP request.
Following are my client and server code. Am i doing something wrong?
#-
python dev wrote:
Hello everyone,
I am trying to get a list of all the partitions (along with their respective
file system types) listed in the /media directory. Does anybody know if
there is a way to do this using Python, or do I have to get this information
by parsing the output of a Linux co
In article <[EMAIL PROTECTED]>,
Alan Franzoni <[EMAIL PROTECTED]> wrote:
>zamil was kind enough to say:
>
>[cut]
>
>If your needs are very basic, you can stick with the tk module that comes
>with python. It's not really feature-packed, but it's maintained and pretty
>cross-platform.
OK, what are
Hello everyone,
I am trying to get a list of all the partitions (along with their respective
file system types) listed in the /media directory. Does anybody know if
there is a way to do this using Python, or do I have to get this information
by parsing the output of a Linux command?
Thanks in ad
Emile van Sebille wrote:
Ben Keshet wrote:
Hi Pythoneers,
I have a question about a code I wrote with the help of someone. The
code below copy a few lines from different files into one file. It
works fine as it is given here and generates the new file
'pockets.out' correctly, but says:"p
On Sep 12, 6:11 pm, Ben Keshet <[EMAIL PROTECTED]> wrote:
> Hi Pythoneers,
>
> I have a question about a code I wrote with the help of someone. The
> code below copy a few lines from different files into one file. It works
> fine as it is given here and generates the new file 'pockets.out'
> correc
Ben Keshet wrote:
Hi Pythoneers,
I have a question about a code I wrote with the help of someone. The
code below copy a few lines from different files into one file. It works
fine as it is given here and generates the new file 'pockets.out'
correctly, but says:"py returned exit code 0". H
Eric Wertman wrote:
The subprocess module is one though
footnote: subprocess works on older versions too, and can be trivially
installed along with your application under Python 2.2 and 2.3.
binary builds for Windows are available here:
http://effbot.org/downloads/#subprocess
--
http:
Don wrote:
I'm a reasonably experienced in other languages and have just decided to
get my feet wet with Python. But I'm using FC6 which has v2.4.4 installed,
is this good enough to start out with or am I likely to encounter bugs that
have been fixed in later versions.
Python 2.4 is definitely
> I'm a reasonably experienced in other languages and have just decided to
> get my feet wet with Python. But I'm using FC6 which has v2.4.4 installed,
> is this good enough to start out with or am I likely to encounter bugs that
> have been fixed in later versions.
I'm sure there will be other op
Hi,
I'm a reasonably experienced in other languages and have just decided to
get my feet wet with Python. But I'm using FC6 which has v2.4.4 installed,
is this good enough to start out with or am I likely to encounter bugs that
have been fixed in later versions.
Don
--
http://mail.python.org/mail
In article <[EMAIL PROTECTED]>,
Fredrik Lundh <[EMAIL PROTECTED]> wrote:
>Steve Holden wrote:
>>
>> The defence rests.
>
>can you please stop quoting that guy, so we don't have to killfile you
>as well...
+1
--
Aahz ([EMAIL PROTECTED]) <*> http://www.pythoncraft.com/
"Argue f
Hi Pythoneers,
I have a question about a code I wrote with the help of someone. The
code below copy a few lines from different files into one file. It works
fine as it is given here and generates the new file 'pockets.out'
correctly, but says:"py returned exit code 0". However, if I add
m
Steven D'Aprano <[EMAIL PROTECTED]> wrote:
> On Thu, 11 Sep 2008 03:36:35 -0500, Nick Craig-Wood wrote:
>
> > As an ex-perl programmer and having used python for some years now, I'd
> > type the explicit
> >
> > v1,v2,v3 = mydict['one'], mydict['two'], mydict['two'] # 54 chars
> >
> > Or mayb
Steve Holden wrote:
The defence rests.
can you please stop quoting that guy, so we don't have to killfile you
as well...
--
http://mail.python.org/mailman/listinfo/python-list
Karthik Krishnan wrote:
> Hi,
>
> I am a newbie to python and I hope this is not a stupid question. I am
> trying to run a main method from a Python command line using the command
> shell using the command.
>
> python main_test.py
>
> I get the following error.
>
>
> File "", line 1
> python
Aaron "Castironpi" Brady wrote:
> On Sep 12, 7:23 am, Steve Holden <[EMAIL PROTECTED]> wrote:
>> castironpi wrote:
>>
>> If you are flattered to be compared to an AI you must come from the same
>> race as Mr. Spock in Star Trek.
>
> No, I said 'for my logic to compared'. Speaking of which, I thin
On Sep 12, 10:36 am, "Siegfried Heintze" <[EMAIL PROTECTED]>
wrote:
> I need to understand some User32.dll functions and I'm making an elaborate
> GUI so I can easily experiment with different parameters. This is taking a
> long time. I'm new to python and I'm thinking it would sure be nice to have
Marco Bizzarri:
> >>> any([x for x in [1, 2, 3]])
>
> I mean, I'm afraid I can't use an expression like that without
> building a list... not at least in python2.3
Note that you don't need a list comp there:
>>> any([x for x in [1, 2, 3]])
True
>>> any([1, 2, 3])
True
so this may suffice:
any(s
Marco Bizzarri a écrit :
(snip)
I'm afraid this have another problem for me...
[EMAIL PROTECTED]:/var/local/zope28/porting/Products/PAFlow$ python2.3
Python 2.3.5 (#2, Oct 18 2006, 23:04:45)
[GCC 4.1.2 20061015 (prerelease) (Debian 4.1.1-16.1)] on linux2
Type "help", "copyright", "credits" or "
D'Arcy J.M. Cain wrote:
Is there ever any advantage to having something as a builtin rather
than as a regular user method? What difference does it make to the
running script? I can see that adding "bar" from module "foo" to
"__builtins__" means that you can use "bar()" instead of "foo.bar()".
On Sep 12, 5:35 pm, Wojtek Walczak <[EMAIL PROTECTED]> wrote:
> On Fri, 12 Sep 2008 08:08:18 -0700 (PDT), Bojan Mihelac wrote:
> > Hi all - when trying to set some dynamic attributes in class, for
> > example:
>
> > class A:
> > for lang in ['1', '2']:
> > exec('title_%s = lang' % lang)
I need to understand some User32.dll functions and I'm making an elaborate
GUI so I can easily experiment with different parameters. This is taking a
long time. I'm new to python and I'm thinking it would sure be nice to have
an interpreter I can type a few lines of code into and test things.
(
On Fri, 12 Sep 2008 08:08:18 -0700 (PDT), Bojan Mihelac wrote:
> Hi all - when trying to set some dynamic attributes in class, for
> example:
>
> class A:
> for lang in ['1', '2']:
> exec('title_%s = lang' % lang) #this work but is ugly
> # setattr(A, "title_%s" % lang, lang) #
On Sep 12, 5:21 pm, Christian Heimes <[EMAIL PROTECTED]> wrote:
> Bojan Mihelac wrote:
> > I guess A class not yet exists in line 4. Is it possible to achive
> > adding dynamic attributes without using exec?
>
> Correct, the class doesn't exist until the end of the class body. You
> can either do i
Bojan Mihelac wrote:
I guess A class not yet exists in line 4. Is it possible to achive
adding dynamic attributes without using exec?
Correct, the class doesn't exist until the end of the class body. You
can either do it outside the class definition or you can use a metaclass.
Christian
--
On Fri, 12 Sep 2008 17:11:47 +0200
Fredrik Lundh <[EMAIL PROTECTED]> wrote:
> The "__builtins__" object is an implementation detail, and shouldn't be
> accessed directly. And I hope I don't need to point out that adding
> custom builtins nillywilly is a bad idea...
Is there ever any advantage t
Bojan Mihelac wrote:
Hi all - when trying to set some dynamic attributes in class, for
example:
class A:
for lang in ['1', '2']:
exec('title_%s = lang' % lang) #this work but is ugly
# setattr(A, "title_%s" % lang, lang) # this wont work
setattr(A, "title_1", "x") # this wo
Marco Bizzarri wrote:
I would like to make this available to the whole project. I suspect I
could put it in the package __init__.py... in that way, the
__builtins__ namespace should have it... am I right?
the __init__ module for package "foo" defines the contents of the "foo"
module; it does
Hi all - when trying to set some dynamic attributes in class, for
example:
class A:
for lang in ['1', '2']:
exec('title_%s = lang' % lang) #this work but is ugly
# setattr(A, "title_%s" % lang, lang) # this wont work
setattr(A, "title_1", "x") # this work when outside class
p
On Fri, Sep 12, 2008 at 4:44 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
>>> if any(instance.forbitToClose(archivefolder) for instance in
>>> self.findActiveOutgoingRegistrationInstances())
>>
>> Can you clarify where I can find "any"? It seems to me I'm unable to find
>> it...
>
> It's part of
On Fri, Sep 12, 2008 at 4:44 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
>>> if any(instance.forbitToClose(archivefolder) for instance in
>>> self.findActiveOutgoingRegistrationInstances())
>>
>> Can you clarify where I can find "any"? It seems to me I'm unable to find
>> it...
>
> It's part of
[EMAIL PROTECTED] wrote:
multipleSpaces = re.compile(u'\\h+')
importantTextString = '\n \n \n \t\t '
importantTextString = multipleSpaces.sub("M", importantTextString)
what's "\\h" supposed to mean?
I would have expected consecutive spaces and tabs to be replaced by M
but nothing is bein
Marco Bizzarri wrote:
Can you clarify where I can find "any"? It seems to me I'm
> unable to find it...
it's a 2.5 addition. to use this in a "future-compatible" way in 2.3,
you can add
try:
any
except NameError:
def any(iterable):
for element in it
if any(instance.forbitToClose(archivefolder) for instance in
self.findActiveOutgoingRegistrationInstances())
Can you clarify where I can find "any"? It seems to me I'm unable to find it...
It's part of python2.5.
If you don't have that, you can write it your own and stuff it into
__builtins_
Hrvoje Niksic <[EMAIL PROTECTED]> writes:
> Chris <[EMAIL PROTECTED]> writes:
>
>>> descr = GetAttrString(cls,"varname");
>>> offset = descr->d_member->offset;
>>> slotvar = (PyObject*)(((char*)obj)+offset)
>>
>> Unfortunately, I am inexperienced at this kind of thing, so I wasn't
>> able to get s
On Fri, Sep 12, 2008 at 4:09 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
> Marco Bizzarri schrieb:
>>
>> Hi all.
>>
>> In many parts of my code I've the following schema of code:
>>
>>def isInUseByOutgoingRegistrations(self, archivefolder):
>>for instance in self.findActiveOutgoingR
Marco Bizzarri schrieb:
Hi all.
In many parts of my code I've the following schema of code:
def isInUseByOutgoingRegistrations(self, archivefolder):
for instance in self.findActiveOutgoingRegistrationInstances():
if instance.forbidToClose(archivefolder):
Chris <[EMAIL PROTECTED]> writes:
>> descr = GetAttrString(cls,"varname");
>> offset = descr->d_member->offset;
>> slotvar = (PyObject*)(((char*)obj)+offset)
>
> Unfortunately, I am inexperienced at this kind of thing, so I wasn't
> able to get something working. Maybe someone could tell me what's
On Sep 12, 7:23 am, Steve Holden <[EMAIL PROTECTED]> wrote:
> castironpi wrote:
>
> If you are flattered to be compared to an AI you must come from the same
> race as Mr. Spock in Star Trek.
No, I said 'for my logic to compared'. Speaking of which, I think you
excluded the possibility of diligent
Chris <[EMAIL PROTECTED]> writes:
>> In my experience, as long as you're
>> accessing simple slots, you should notice a difference.
>
> (I'm not sure what you mean by a 'simple slot'.
I mean a slot defined by __slots__ = slot1, slot2, slot3, ..., without
descriptors or specific __getattribute__ c
Hi all.
In many parts of my code I've the following schema of code:
def isInUseByOutgoingRegistrations(self, archivefolder):
for instance in self.findActiveOutgoingRegistrationInstances():
if instance.forbidToClose(archivefolder):
return True
return
Peter Waller wrote:
> Dear Pythoners,
>
> I know this will probably be perceived as 'evil voodoo', and fair
> enough: it probably is. I guess it is unpythonic.
>
> .. but I want to know how to do it anyway - mostly for my own
> interest.
Well, if you're really just asking out of curiosity, it sh
Hrvoje Niksic xemacs.org> writes:
...
> Chris users.sourceforge.net> writes:
>
> >> PyObject_GetAttrString is convenient, but it creates a Python string
> >> only so it can intern it (and in most cases throw away the freshly
> >> created version). For maximum efficiency, pre-create the string
>
Dear Pythoners,
I know this will probably be perceived as 'evil voodoo', and fair
enough: it probably is. I guess it is unpythonic.
.. but I want to know how to do it anyway - mostly for my own
interest.
Consider the following snippet of code:
---
def Get( *names ):
if not names: return Non
On Sep 12, 4:34 am, Paul Boddie <[EMAIL PROTECTED]> wrote:
> On 12 Sep, 08:30, Steven D'Aprano
>
> <[EMAIL PROTECTED]> wrote:
>
> > Which is why I previously said that XML was not well suited for random
> > access.
>
> Maybe not.
No, it's not. Element trees are, which if I just would have said
or
On Sep 11, 8:04 pm, Arnaud Delobelle <[EMAIL PROTECTED]> wrote:
> On Sep 11, 5:40 pm, "Giampaolo Rodola'" <[EMAIL PROTECTED]> wrote:
>
>
>
> > Hi,
> > I'm trying to implement a function which returns whether a path is a
> > subpath of another one (e.g. /a/b/c is a subpath of /a/b).
> > I wrote this
Tim Golden wrote:
Strato wrote:
Hi folks,
I want to write some kind of test to check at startup if another
instance of my script is already running.
I don't want to handle writing of a PID file because it is too
Unix/Linux specific way to do this, and I need to keep the code to be
cross-pl
Praveena P wrote:
> Hi folks,
>
> I am new to Python... so am not too sure about how the type conversion
> works.
>
> I have to read a file that contains hexadecimal data and use the data
> further to do some arithmetic calculations.
> A sample of the input is : 20E032F840
Strato wrote:
Hi folks,
I want to write some kind of test to check at startup if another
instance of my script is already running.
I don't want to handle writing of a PID file because it is too
Unix/Linux specific way to do this, and I need to keep the code to be
cross-platform.
I think t
On Thu, 11 Sep 2008 17:27:33 +0200, Sjoerd Mullender wrote:
> When mail messages bounce, the MTA (Message Transfer Agent--the program
> that handles mail) *should* send the bounce message to whatever is in
> the Sender header, and only if that header does not exist, should it use
> the From header
Carl Banks gmail.com> writes:
...
> You can determine the offset the of the slot in the object structure
> by
> querying the member descriptor of the type object.
That sounds like just the kind of thing we were looking for - thanks!
> descr = GetAttrString(cls,"varname");
> offset = descr->d_mem
castironpi wrote:
[...]
> For example, I sometimes hear people talk about salary as though it
> were social approval, and vice versa. Even though the analogy doesn't
> hold in every case generally, it is still a good way to express
> yourself in many contexts, and especially when the more precise
castironpi wrote:
> On Sep 7, 5:03 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
>> On Mon, 08 Sep 2008 07:34:55 +1000, James Mills wrote:
>>> This is the strangest post I've seen
>>> since I've joined this list (only
>>> recently). What the ?
>> Yeah, castironpi sometimes doesn't make mu
Hi folks,
I want to write some kind of test to check at startup if another
instance of my script is already running.
I don't want to handle writing of a PID file because it is too
Unix/Linux specific way to do this, and I need to keep the code to be
cross-platform.
I think the better way t
multipleSpaces = re.compile(u'\\h+')
importantTextString = '\n \n \n \t\t '
importantTextString = multipleSpaces.sub("M", importantTextString)
I would have expected consecutive spaces and tabs to be replaced by M
but nothing is being replaced. If I try the following, then I'm left
only with M,
1 - 100 of 119 matches
Mail list logo