On Sep 2, 4:31 am, ssecorp <[EMAIL PROTECTED]> wrote:
> X.__dict__() and ngot a dict of its variables.
>
> Now i get errors doing this. what am i doing wrong?
The immediate problem is you're not reading the error messages.
>>> X.__dict__()
Traceback (most recent call last):
File "", line 1, in
On Tue, 02 Sep 2008 11:13:27 +1000, Ben Finney wrote:
> [EMAIL PROTECTED] writes:
>
>> For Python 2.7/3.1 I'd now like to write a PEP regarding the
>> underscores into the number literals, like: 0b_0101_, 268_435_456
>> etc.
>
> +1 on such a capability.
>
> -1 on underscore as the separator
On Sep 2, 6:30 am, Jesse Aldridge <[EMAIL PROTECTED]> wrote:
> I want to put all the output from all of my python programs in one
> place.
Have you considered using the python logging module?
http://docs.python.org/lib/module-logging.html
http://www.onlamp.com/pub/a/python/2005/06/02/logging.html
bruce wrote:
> i've got the following situation, with the following test url:
> "http://schedule.psu.edu/soc/fall/Alloz/a-c/acctg.html#";.
>
> i can generate a list of the tables i want for the courses on the page.
> however, when i try to create the xpath query, and plug it into the xpath
> withi
hi...
i can use an xpath query to create a node from an html/dom representation.
however, if i have a node, is there a way to generate an xpath query from
the node.
in testing with firefox/dom inspector, i can use "ancestor::*", but i can't
determine where/how to implement this using mechanize/li
On Sat, Aug 30, 2008 at 11:07 AM, Eric Wertman <[EMAIL PROTECTED]> wrote:
>> I'm doing some simple file manipulation work and the process gets
>> "Killed" everytime I run it. No traceback, no segfault... just the
>> word "Killed" in the bash shell and the process ends. The first few
>> batch runs w
Ben Finney wrote:
I would argue that the precedent, already within Python, for using a
space to separate pieces of a string literal, is more important than
precedents from other programming languages.
that precedent also tells us that the whitespace approach is a common
source of errors. tak
"Marco Bizzarri" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
On Mon, Sep 1, 2008 at 3:25 PM, <[EMAIL PROTECTED]> wrote:
When I do ${urllib.unquote(c.user.firstName)} without encoding to
latin-1 I got different chars than I will get: no Łukasz but Å ukasz
--
http://mail.pytho
[EMAIL PROTECTED] writes:
> Ben Finney:
> > I don't see any good reason (other than your familiarity with the
> > D language) to use underscores for this purpose, and much more
> > reason (readability, consistency, fewer arbitrary differences in
> > syntax, perhaps simpler implementation) to use w
On Sep 1, 8:28 pm, "Guilherme Polo" <[EMAIL PROTECTED]> wrote:
> Can you clarify what is this "sticky" behavior ? Are you referring to
> a toggle button ? If yes, then you might be after a simple
> Checkbutton:
>
> checkbutton = Tkinter.Checkbutton(indicatoron=False, text='test')
I wouldn't spend
hi...
i've got the following situation, with the following test url:
"http://schedule.psu.edu/soc/fall/Alloz/a-c/acctg.html#";.
i can generate a list of the tables i want for the courses on the page.
however, when i try to create the xpath query, and plug it into the xpath
within python, i'm miss
hi...
i've got the following situation, with the following test url:
"http://schedule.psu.edu/soc/fall/Alloz/a-c/acctg.html#";.
i can generate a list of the tables i want for the courses on the page.
however, when i try to create the xpath query, and plug it into the xpath
within python, i'm miss
On Mon, Sep 1, 2008 at 11:01 PM, akineko <[EMAIL PROTECTED]> wrote:
> On Sep 1, 6:34 pm, "Guilherme Polo" <[EMAIL PROTECTED]> wrote:
>> This is an illusion you have, calling those methods are not the way
>> for explicitly controlling button's behavior, not more than generating
>> proper events. The
On Mon, Sep 01, 2008 at 08:40:42AM +0200, Diez B. Roggisch wrote:
> Johny schrieb:
> >To get a number of the http processes running on my Linux( Debia box)
> >I use
> >ps -ef | grep "[h]ttpd" | wc -l
[...]
> The shell does the exact same thing. And by the way: i think you miss a
>
> grep -v grep
On Ubuntu you want to install something like python-sqlite (a search
for "python" should turn up everything). There are 2 parts to this,
SQLite and the python bindings to SQLite. So you seem to have SQLite
installed but not the Python bindings. Also, on some systems you have
to have python-sqlit
On Sep 1, 6:34 pm, "Guilherme Polo" <[EMAIL PROTECTED]> wrote:
> This is an illusion you have, calling those methods are not the way
> for explicitly controlling button's behavior, not more than generating
> proper events. The explicit way is to not use a button, instead
> (ab)use Canvas.
Some of
Ben Finney:
> I don't see any good reason (other than your familiarity with the D
> language) to use underscores for this purpose, and much more reason
> (readability, consistency, fewer arbitrary differences in syntax,
> perhaps simpler implementation) to use whitespace just as with string
> liter
On Mon, Sep 1, 2008 at 10:09 PM, akineko <[EMAIL PROTECTED]> wrote:
> On Sep 1, 5:52 pm, "Guilherme Polo" <[EMAIL PROTECTED]> wrote:
>
>> Are you trying to simulate clicks ? You should be doing it using
>> event_generate, more below.
>>
>
> Actually, I was trying to implement a "sticky" button.
> (
[EMAIL PROTECTED] writes:
> For Python 2.7/3.1 I'd now like to write a PEP regarding the
> underscores into the number literals, like: 0b_0101_, 268_435_456
> etc.
+1 on such a capability.
-1 on underscore as the separator.
When you proposed this last year, the counter-proposal was made
htt
On Sep 1, 5:52 pm, "Guilherme Polo" <[EMAIL PROTECTED]> wrote:
> Are you trying to simulate clicks ? You should be doing it using
> event_generate, more below.
>
Actually, I was trying to implement a "sticky" button.
(Button Release is done later by another event)
I already tried event_generate.
On Sep 1, 2:15�pm, [EMAIL PROTECTED] wrote:
> I have just re-read the list of changes in Python 2.6, it's huge,
> there are tons of changes and improvements, I'm really
> impressed:http://docs.python.org/dev/whatsnew/2.6.html
>
> I'll need many days to learn all those changes! I can see it fixes
>
Marc 'BlackJack' Rintsch wrote:
First, thank you for the informative responses.
The windows command prompt expects cp437 because that's what old DOS
programs print to it.
Grrr. When the interpreter runs, it opens the command prompt window
with Python running, and the window closes when Py
On Sep 1, 6:55�pm, [EMAIL PROTECTED] wrote:
> Steven D'Aprano:
>
> > productory() -- I don't know that function, and googling mostly comes up
> > with retail product searches. Do you mean product(),
>
> Darn my English, you are right, sorry, I meant a product() of
> course :-)
But the name product
On Mon, Sep 1, 2008 at 7:45 PM, akineko <[EMAIL PROTECTED]> wrote:
> Hi everyone,
>
> This is a memorandum so that other people can share the info.
>
> The following methods are declared in the Tkinter Button class.
> tkButtonDown(), tkButtonEnter(), tkButtonInvoke(), tkButtonLeave(),
> tkButtonUp(
On Mon, 1 Sep 2008 21:03:44 + (UTC), Martin Gregorie
<[EMAIL PROTECTED]> wrote:
>On Mon, 01 Sep 2008 12:04:05 -0700, Robert Maas, http://tinyurl.com/uh3t
>wrote:
>
>>> From: George Neuner <[EMAIL PROTECTED]> A friend of mine had an
>>> early 8080 micros that was programmed through the front pa
Steven D'Aprano:
> productory() -- I don't know that function, and googling mostly comes up
> with retail product searches. Do you mean product(),
Darn my English, you are right, sorry, I meant a product() of
course :-)
Bye,
bearophile
--
http://mail.python.org/mailman/listinfo/python-list
On Mon, 01 Sep 2008 12:15:53 -0700, bearophileHUGS wrote:
> Now math has factorial:
> http://docs.python.org/dev/library/math.html#math.factorial Seen how
> reduce() is removed from Python 3 (I know it's in itertools), and seeing
> that for me to write a productory() function was the first usage I
Hi everyone,
I wrote a Tkinter program that has a blinking widget.
The blinking is controlled by the after() method available in the
Tkinter.
It worked very nicely.
However, when I tried the program with a Unix OS that is running under
VMware (hosted OS), I noticed the blinking rate is greatly re
Hi everyone,
This is a memorandum so that other people can share the info.
The following methods are declared in the Tkinter Button class.
tkButtonDown(), tkButtonEnter(), tkButtonInvoke(), tkButtonLeave(),
tkButtonUp()
However, they are not working, when you try, you will get:
_tkinter.TclError
Gandalf wrote:
if i want to print utf-8 string i should writre:
print u"hello word"
but what happen if i want to print variable?
u"hello world" is *not* an utf-8 encoded string. It's a unicode string.
I suggest you read http://www.joelonsoftware.com/articles/Unicode.html
Christian
--
http
On Sep 1, 11:59 pm, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote:
> Gandalf schrieb:
>
> > if i want to print utf-8 string i should writre:
>
> > print u"hello word"
>
> No, you don't. You write
>
> print u"hello world".encode("utf-8")
>
> Read this:
>
> http://www.reportlab.com/i18n/python_unicode
[EMAIL PROTECTED] wrote:
Now math has factorial:
http://docs.python.org/dev/library/math.html#math.factorial
That's rather underdocumented.
Does it really attempt exact calculation
for arbitrary integers?? Is there any
way to request a nice fast approximation
for large integers (e.g., with Gos
Gandalf schrieb:
if i want to print utf-8 string i should writre:
print u"hello word"
No, you don't. You write
print u"hello world".encode("utf-8")
Read this:
http://www.reportlab.com/i18n/python_unicode_tutorial.html
but what happen if i want to print variable?
Then you do
print varia
Blender Game Engine does not seem able to just play an AVI clip
file...
I want to play these files as cut-scenes in a game - subprocess it to
the OS, and continue on return seems a good solution - but so sorry,
it's been a while since I've delved in such places... I need a
refresher.
Must be plat
if i want to print utf-8 string i should writre:
print u"hello word"
but what happen if i want to print variable?
thank you
--
http://mail.python.org/mailman/listinfo/python-list
Neville Dempsey a écrit :
What do I need to add to HTMLDecorator?
A simpler example:
import cgi
class ClassX(object):
pass # ... with own __repr__
class ClassY(object):
pass # ... with own __repr__
inst_x=ClassX()
Why do you need to prefix your variables with 'inst_' ?
inst_y=ClassY(
On Mon, 01 Sep 2008 12:04:05 -0700, Robert Maas, http://tinyurl.com/uh3t
wrote:
>> From: George Neuner <[EMAIL PROTECTED]> A friend of mine had an
>> early 8080 micros that was programmed through the front panel using
>> knife switches
>
> When you say "knife switches", do you mean the kind that
I want to put all the output from all of my python programs in one
place. I've been trying to get this working for the last few days,
but there are lots of annoying little details that are making the
process quite difficult. I'm wondering if anyone can help me get this
working.
Currently I have o
Neville Dempsey a écrit :
Basically I have an existing (maybe a rather large and complicated
(existing) instance) that
I want to add new member to.
I suppose you mean "attributes" ?
Cheers
N
Hacks/attempts follow:
from math import sqrt
try2
duck_obj = [ i*i for i
On Mon, Sep 1, 2008 at 3:35 PM, <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm using a TkMessageBox for handling some errors and displaying them
> through the message boxes.
>
> My code is as below:
> if selectedVer == strNoArchivedResults:
>tkMessageBox._show("Error", \
>
On 2008-08-31 15:15, mark wrote:
> Hi there,
>
> I need to extract data from text files (~4 GB) on this data some
> operations are performed like avg, max, min, group etc. The result is
> formated and written in some other text files (some KB).
>
> I currently think about database tools might be
ssecorp a écrit :
I did nce (I think).
class X
X.__dict__() and ngot a dict of its variables.
Now i get errors doing this. what am i doing wrong?
cf Wojtek's answer.
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
I presume it's better for me to not hold my breath while I wait
CPython to be written in C99 :-)
First you have to convince Microsoft to release C99 compiler ... good luck!
Christian
--
http://mail.python.org/mailman/listinfo/python-list
Tom Harris wrote:
Greetings,
I need a little help with buffer objects. Many Python objects export
the buffer interface, or can be persuaded to create a buffer object
with a buffer() call.
...
It must be me but I have found the whole buffer thing difficult to
understand from the docs, it appe
On Mon, 01 Sep 2008 14:25:01 -0400, Terry Reedy wrote:
> Marc 'BlackJack' Rintsch wrote:
>> On Mon, 01 Sep 2008 02:27:54 -0400, Terry Reedy wrote:
>>
>> Most likely because Python figured out that the terminal expects cp437.
>> What does `sys.stdout.encoding` say?
>
> The interpreter in the comma
I have just re-read the list of changes in Python 2.6, it's huge,
there are tons of changes and improvements, I'm really impressed:
http://docs.python.org/dev/whatsnew/2.6.html
I'll need many days to learn all those changes! I can see it fixes
several of the missing things/problems I have found in
> From: George Neuner <[EMAIL PROTECTED]>
> A friend of mine had an early 8080 micros that was programmed
> through the front panel using knife switches
When you say "knife switches", do you mean the kind that are shaped
like flat paddles? I think that would be the IMSAI, which came
after the ALTA
Alexandru Palade wrote:
> lookfor = 'dfsdf'
> for item, value in kev.items():
>if lookfor in value:
>print item
>print value.index(lookfor)
>break # assuming you only want one result
slight variation:
lookfor = 'dfsdf'
for item, value i
Anyone have any benchmarks on the difference in performance between 32
and 64 bit versions of Python for specific categories of operation, eg.
math, file, string, etc. operations?
My question is OS neutral so feel free to share your experience with
either Windows or Linux OS's.
Thank you,
Malcolm
Manuel Ebert wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Okay, I'll take I wild guess: By "command lime code" you did not refer
to the algorithmic domination of citrus fruit, but rather to that window
with the tiny blinking cursor and loads of text in white on black. Also
by 'chdir
On Mon, 1 Sep 2008 11:31:42 -0700 (PDT), ssecorp wrote:
> I did nce(I think).
>
> class X
>
> X.__dict__() and ngot a dict of its variables.
>
> Now i get errors doing this. what am i doing wrong?
You're not asking smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html
HINT: the attr
Hi,
I'm using a TkMessageBox for handling some errors and displaying them
through the message boxes.
My code is as below:
if selectedVer == strNoArchivedResults:
tkMessageBox._show("Error", \
type='ok', icon='error', \
I did nce(I think).
class X
X.__dict__() and ngot a dict of its variables.
Now i get errors doing this. what am i doing wrong?
--
http://mail.python.org/mailman/listinfo/python-list
Marc 'BlackJack' Rintsch wrote:
On Mon, 01 Sep 2008 02:27:54 -0400, Terry Reedy wrote:
I doubt the OP 'chose' cp437. Why does Python using cp437 even when the
default encoding is utf-8?
On WinXP
>>> sys.getdefaultencoding()
'utf-8'
>>> s='\u012b'
>>> s
Traceback (most recent call last):
Chris Rebert a écrit :
On Sun, Aug 31, 2008 at 6:39 PM, ssecorp <[EMAIL PROTECTED]> wrote:
Why/how is it possible to add variables like this? I don't understand
this mechanism:
http://docs.python.org/tut/node11.html#SECTION001133
Under the covers, Python objects are implemented
Making money with affiliate programs is a better way, please see this
web-site:
http://www.abicana.com/affiliatenetworks.htm
--
http://mail.python.org/mailman/listinfo/python-list
On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
> Oddly, Leaning Python has no mention of datetime (not date or time), at
> least, that I could find. I'm considering the Nutshell book, 2nd ed., as a
> better reference (and cross reference) to various topics.
datetime is pretty new standard
On 2008-09-01, Luka Djigas <[EMAIL PROTECTED]> wrote:
> please, I need your help. I'm new to python, so I don't know if this
> will seem like a stupid question to some of you ...
There are several ways to do it. Have a look at the documentation
of modules time and datetime. For this exact problem
Mike P wrote:
I'm trying to use the CSV module to read in some data and then use a
hashable method (as there are millions of records) to find unique ids
and push these out to another file,
You could either zip with a counter or use the uuid module,
depending on just how unique you want your ids
http://docs.python.org/lib/module-csv.html
--
http://mail.python.org/mailman/listinfo/python-list
Hello. I have something like that:
from twisted.words.protocols.jabber import xmlstream
from twisted.internet import protocol
from twisted.words.xish import domish, utility
from twisted.internet import reactor
from twisted.python import log
import sys, hashlib
log.startLogging(sys.stdout)
def ma
On October 1, 2008, new FHA Refinance Loan Guidelines will go into
effect as part of The Housing and Economic Recovery Act of 2008. This
new FHA Mortgage program is designed to help thousands of homeowners
who are at risk of foreclosure in their curent conventional or sub-
prime home loans.
The det
Grant Edwards wrote:
On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
Grant Edwards wrote:
On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
That's the question in Subject. For example, the difference between
08/29/2008 and 09/03/2008 is +5. The difference between 02/28/2008 and
03/03
Luka Djigas wrote:
please, I need your help. I'm new to python, so I don't know if this
will seem like a stupid question to some of you ...
I have a need to write to a file (or just print on screen, that part
doesn't matter at this point) a list of dates, starting today. For
example:
>
02.09.2
Hello everyone,
please, I need your help. I'm new to python, so I don't know if this
will seem like a stupid question to some of you ...
I have a need to write to a file (or just print on screen, that part
doesn't matter at this point) a list of dates, starting today. For
example:
02.09.2008. tue
Greetings,
I need a little help with buffer objects. Many Python objects export
the buffer interface, or can be persuaded to create a buffer object
with a buffer() call.
First question, the buffer() function appears very quick. Does it just
wrap the internal pointer and then exit?
Second questio
On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
> Grant Edwards wrote:
>> On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
>>
>>> That's the question in Subject. For example, the difference between
>>> 08/29/2008 and 09/03/2008 is +5. The difference between 02/28/2008 and
>>> 03/03/2008
André a écrit :
Hi, I was trying to find a way to set, upon __init__() the parent of a
class to an existing instance.
??? Sorry but I just can't make any sense of this.
Here is a minimal example of what I'm
trying to do:
class A(object):
def __init__(self, x):
self.x = x
class B(A):
Hi,
I am writing Python extension in C++, in this extension I am using
methods from another Python extension. On Linux I am currently linking
my extension with used Python extension -- what is quite ugly.
gcc ... -lgdi
where gdi is a link to C++ extension imported by 'module'
I would like to av
Grant Edwards wrote:
On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
That's the question in Subject. For example, the difference between
08/29/2008 and 09/03/2008 is +5. The difference between 02/28/2008 and
03/03/2008 is 4, leap year--extra day in Feb. I'm really only interested in
year
Hans Müller wrote:
I'm quite often using this construct:
for l in open("file", "r"):
do something
here, l contains the \n or \r\n on windows at the end.
nope -- if you open a file in text mode (without the "b"), the I/O layer
will translate "\r\n" to "\n" on Windows.
if you want even
Hans Müller a écrit :
Hello,
I'm quite often using this construct:
for l in open("file", "r"):
do something
here, l contains the \n or \r\n on windows at the end.
I get rid of it this way:
for l in open("file", "r"):
while l[-1] in "\r\n":
l = l[:-1]
I find this a little bit
On 2008-08-29, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> I am new to python.
OK.
> I did find a page which listed some code - IE "chdir" type
> code but can not find it again.
I have absolutely no clue what you mean.
> Can you supply an address?
Sure, in fact, I can supply two!
http:/
On 2008-09-01, W. eWatson <[EMAIL PROTECTED]> wrote:
> That's the question in Subject. For example, the difference between
> 08/29/2008 and 09/03/2008 is +5. The difference between 02/28/2008 and
> 03/03/2008 is 4, leap year--extra day in Feb. I'm really only interested in
> years between, say,
On Aug 29, 11:02 pm, Thomas Heller <[EMAIL PROTECTED]> wrote:
>
> BTW: Let me say that the more I useloggingthe more I like it.loggingis a
> fantastic package!
>
Thank you, I can say the same for ctypes and py2exe :-)
Regards,
Vinay Sajip
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 1, 9:41 am, Wojtek Walczak <[EMAIL PROTECTED]> wrote:
> On Mon, 01 Sep 2008 15:25:03 +0200, Hans Müller wrote:
> > I'm quite often using this construct:
>
> > for l in open("file", "r"):
> > do something
> > Has someone a better solution ?
>
> The most general would be to use rstrip() wit
On Aug 30, 8:59 pm, josh logan <[EMAIL PROTECTED]> wrote:
> > Vincent Yau <[EMAIL PROTECTED]> writes:
> > > I am trying to use Python SAX API to parse XML files. I do see expat.py
> > > somewhere underneath my Python 2.1.1 installation (on Solaris).
> > > But I got this error when invoking the xml
On Mon, 01 Sep 2008 15:25:03 +0200, Hans M�ller wrote:
> I'm quite often using this construct:
>
> for l in open("file", "r"):
> do something
> Has someone a better solution ?
The most general would be to use rstrip() without
arguments:
>>> a="some string\r\n"
>>> a.rstrip()
'some string'
On Sep 1, 9:25 am, Hans Müller <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I'm quite often using this construct:
>
> for l in open("file", "r"):
> do something
>
> here, l contains the \n or \r\n on windows at the end.
> I get rid of it this way:
>
> for l in open("file", "r"):
> while
On Mon, Sep 1, 2008 at 3:25 PM, <[EMAIL PROTECTED]> wrote:
>
> When I do ${urllib.unquote(c.user.firstName)} without encoding to
> latin-1 I got different chars than I will get: no Łukasz but Å ukasz
> --
> http://mail.python.org/mailman/listinfo/python-list
That's crazy. "string".encode('latin1
Hi All,
I'm trying to use the CSV module to read in some data and then use a
hashable method (as there are millions of records) to find unique ids
and push these out to another file,
can anyone advise? Below is the code so far
fin = open(CSV_INPUT, "rb")
fout = open(CSV_OUTPUT, "wb")
reader = c
On 1 Wrz, 15:10, "Marco Bizzarri" <[EMAIL PROTECTED]> wrote:
> 2008/9/1 <[EMAIL PROTECTED]>:
>
>
>
> > Hi,
>
> > I have a problem with unicode string in Pylons templates(Mako). I will
> > print first char from my string encoded in UTF-8 and urllib.quote(),
> > for example string 'Łukasz':
>
> > ${
Hello,
I'm quite often using this construct:
for l in open("file", "r"):
do something
here, l contains the \n or \r\n on windows at the end.
I get rid of it this way:
for l in open("file", "r"):
while l[-1] in "\r\n":
l = l[:-1]
I find this a little bit clumsy
Hi, I was trying to find a way to set, upon __init__() the parent of a
class to an existing instance. Here is a minimal example of what I'm
trying to do:
class A(object):
def __init__(self, x):
self.x = x
class B(A):
def __init__(self, *args):
if not isinstance(args[0], A):
supe
Hi!!
I'm trying to program an application which have multiple windows and
is capable of executing method defined inside class of one another, i
tries a simpel frame work here and am creating Toplevel inside method
as the new window to be genereated, and again want another window to
be loaded when t
2008/9/1 <[EMAIL PROTECTED]>:
> Hi,
>
> I have a problem with unicode string in Pylons templates(Mako). I will
> print first char from my string encoded in UTF-8 and urllib.quote(),
> for example string 'Łukasz':
>
> ${urllib.unquote(c.user.firstName).encode('latin-1')[0:1]}
>
> and I received thi
On Sep 1, 8:19 am, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
> On Mon, 01 Sep 2008 02:27:54 -0400, Terry Reedy wrote:
> > I doubt the OP 'chose' cp437. Why does Python using cp437 even when the
> > default encoding is utf-8?
>
> > On WinXP
> > >>> sys.getdefaultencoding()
> > 'utf-8'
>
Hi,
I have a problem with unicode string in Pylons templates(Mako). I will
print first char from my string encoded in UTF-8 and urllib.quote(),
for example string 'Łukasz':
${urllib.unquote(c.user.firstName).encode('latin-1')[0:1]}
and I received this information:
: 'utf8' codec can't decode by
thanks for the help,
maybe the solution will be useful: in "various Linux distributions are starting to ship with a version of the GNU C compiler which incorporates an extension which implements protection for stack-smashing". In that case the Makefile has to modified with
CFLAGS = -fno-stack
Luca wrote:
Yes, this helps a lot. In facts I need to do something like a language parser.
a *parser* that works on object structures created by executing a Python
program?
--
http://mail.python.org/mailman/listinfo/python-list
On Mon, Sep 1, 2008 at 2:18 PM, Steven D'Aprano
<[EMAIL PROTECTED]> wrote:
>
> If your aim is to write something like a debugger, profiler, or some
> other application that needs to inspect arbitrary objects and work out
> what they do, then you probably should be using:
>
> isinstance(obj.methodNa
http://www.moneymaking4.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
http://www.moneymaking4.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
http://www.moneymaking4.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
http://www.moneymaking4.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Mon, 01 Sep 2008 02:27:54 -0400, Terry Reedy wrote:
> I doubt the OP 'chose' cp437. Why does Python using cp437 even when the
> default encoding is utf-8?
>
> On WinXP
> >>> sys.getdefaultencoding()
> 'utf-8'
> >>> s='\u012b'
> >>> s
> Traceback (most recent call last):
>File "", line
On Mon, 01 Sep 2008 11:45:36 +0200, Luca asked about recognizing methods:
> What is the best way to do this? The "most pythonic"?
That depends on why you are doing it, and what you want to do with the
information once you've found it.
If you are experimenting in the interactive interpreter, the
Luca wrote:
On Mon, Sep 1, 2008 at 11:35 AM, Steven D'Aprano
<[EMAIL PROTECTED]> wrote:
...
But not so easy to fool a type check:
type(x) == new.function
False
Of course that's not bullet-proof either. I leave it as an exercise to
discover how you might break that piece of code.
Ok, so..
On Mon, 01 Sep 2008 11:45:36 +0200, Luca wrote:
>> But not so easy to fool a type check:
>>
> type(x) == new.function
>> False
>>
>> Of course that's not bullet-proof either. I leave it as an exercise to
>> discover how you might break that piece of code.
>>
>>
> Ok, so...
>
> What is the bes
lee a écrit :
On Sep 1, 2:37 pm, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote:
lee wrote:
(snip)
i agree with u, my data strusture is not efficient. but all the
records,viz...name,phno, email,address are all generated at runtime ,
when the user enters them. so how can i design my datastructur
1 - 100 of 138 matches
Mail list logo