On Sep 14, 11:45 am, "Guilherme Polo" <[EMAIL PROTECTED]> wrote:
> On Sun, Sep 14, 2008 at 10:33 AM, Clodoaldo <[EMAIL PROTECTED]> wrote:
> > I have installed cjson 1.05 in Fedora 8 (python 2.5.1).
>
> > The cjson home page shows a keyword argument "e
On Sep 14, 10:33 am, Clodoaldo <[EMAIL PROTECTED]> wrote:
> I have installed cjson 1.05 in Fedora 8 (python 2.5.1).
>
> The cjson home page shows a keyword argument
> "encoding".http://python.cx.hu/python-cjson/
>
> When i use it i get an error:
>
&
On Mar 28, 1:56 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 13:22:06 -0300, Clodoaldo <[EMAIL PROTECTED]>
> escribió:
>
>
>
> > On Mar 28, 12:09 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote:
> >>
On Mar 28, 12:09 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 10:54:49 -0300, Clodoaldo <[EMAIL PROTECTED]>
> escribió:
>
>
>
> > I'm using a md5 hash encoded with base64.urlsafe_b64encode as a
> > parameter of
swer will make my regexp safer.
In another point, does the "=" char make it urlunsafe? I guess not
because i believe it would only be unsafe if the equal appeared like
in "&var=" and since there are no "&" in the string than there is no
problem right? Or wrong?
Re
2008/3/25, D'Arcy J.M. Cain <[EMAIL PROTECTED]>:
> On Tue, 25 Mar 2008 06:39:57 -0700 (PDT)
> Clodoaldo <[EMAIL PROTECTED]> wrote:
> > I need to know if an email was refused for whatever reason, it makes
> > no difference.
> >
> > The email is se
an exception but it does
not. And the returned dictionary is empty as if the email was
accepted.
d = smtpserver.sendmail(sender, recipient, m.as_string())
I guess that the error code returned by the destination mail server is
not is not forwarded to the client by my mail server.
Regards, Clodoaldo
On May 30, 4:25 am, Duncan Booth <[EMAIL PROTECTED]> wrote:
> Clodoaldo <[EMAIL PROTECTED]> wrote:
> > On May 29, 12:57 pm, "Richard Brodie" <[EMAIL PROTECTED]> wrote:
> >> "Clodoaldo" <[EMAIL PROTECTED]> wrote in message
>
&
On May 30, 8:53 am, Tommy Nordgren <[EMAIL PROTECTED]> wrote:
> On 29 maj 2007, at 17.52, Clodoaldo wrote:
>
>
>
> > I was looking for a function to transform a unicode string into
> > htmlentities. Not only the usual html escaping thing but all
> > character
On May 29, 12:57 pm, "Richard Brodie" <[EMAIL PROTECTED]> wrote:
> "Clodoaldo" <[EMAIL PROTECTED]> wrote in message
>
> news:[EMAIL PROTECTED]
>
> >I was looking for a function to transform a unicode string into
> >htmlentities.
> >
python builtin modules? If not
is there a better way to do it?
Regards, Clodoaldo Pinto Neto
--
http://mail.python.org/mailman/listinfo/python-list
On May 24, 6:40 am, Peter Otten <[EMAIL PROTECTED]> wrote:
> Clodoaldo wrote:
> > When using unicode the case change works:
>
> >>>> print u'É'.lower()
> > é
>
> > But when using the pt_BR.utf-8 locale it doesn't:
>
>
27;utf')
>>> print 'É'.lower()
É
What am I missing? I'm in Fedora Core 5 and Python 2.4.3.
# cat /etc/sysconfig/i18n
LANG="en_US.UTF-8"
SYSFONT="latarcyrheb-sun16"
Regards, Clodoaldo Pinto Neto
--
http://mail.python.org/mailman/listinfo/python-list
76, True)
'9876'
>>> locale.localeconv()['thousands_sep']
''
>>> locale.localeconv()['mon_thousands_sep']
'.'
The thousands separator is defined only for the ['mon_thousands_sep']
key and not for the ['thousands_sep
s like one byte of garbage is appended at the end of file. Please
> file a bug report.
Bug number 1597011
Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
Fredrik Lundh wrote:
> Clodoaldo Pinto Neto wrote:
>
> > The offending file is 5.5 MB. Sorry, i could not reproduce this problem
> > with a smaller file.
>
> but surely you can post the repr() of the last two lines?
This is the output:
$ python bzp.py
line number: 588
lines += 1
if line1 != line2:
print 'line number:', lines
print repr(line1)
print repr(line2)
f1.close()
f2.close()
##
The offending file is 5.5 MB. Sorry, i could not reproduce this problem
with a smaller file.
http://fahstats.c
Fredrik Lundh wrote:
> Clodoaldo Pinto Neto wrote:
>
> > But I still don't understand what is happening. The manual says that
> > when shell=True the executable argument specifies which shell to use:
>
> no, it says that when shell=True, it runs the command "thro
Fredrik Lundh wrote:
> [EMAIL PROTECTED] wrote:
>
> > I can't see any obvious way to ask subprocess to use a shell other than
> > the default.
>
> -c ?
>
> >>> f = Popen(["/bin/bash", "-c", "set|grep IFS"], stdout=PIPE)
> >>> f.stdout.read()
> "IFS=$' \\t\\n'\n"
> >>> f = Popen(["/bin/sh", "-c",
Now we have 3 different outputs from 3 people to the command:
>>> f = subprocess.Popen("set | grep IFS", shell=True,
stdout=subprocess.PIPE)
>>> f.stdout.readlines()
>From me on FC5:
["BASH_EXECUTION_STRING='set | grep IFS'\n", "IFS=' \t\n"]
>From Fredrik Lundh on unknown
Fredrik Lundh wrote:
> this works for me:
>
> >>> f = subprocess.Popen("set | grep IFS", shell=True,
> stdout=subprocess.PIPE)
> >>> f.stdout.readlines()
> ["IFS=$' \\t\\n'\n"]
>
> what does the above return on your machine?
>>> f = subprocess.Popen("set | grep IFS", shell=True, stdout=subproce
27; \t\n"
Both outputs for comparison:
IFS=$' \t\n'
"IFS=' \t\n"
The subprocess.Popen() output is missing the $ and the last '
How to get the raw shell output from subprocess.Popen()?
Regards, Clodoaldo Pinto Neto
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> Clodoaldo Pinto Neto wrote:
>
> > print 'The submited name was "' + name + '"'
>
> Bzzt! Script injection security hole. See cgi.escape and use it (or a
> similar function) for *all* text -> HTML output.
>
le-structure, etc),
> and thus should only be used while debugging, and turned off in
> any sort of production code.
Yes, another warning was issued.
Thanks for your help. Clodoaldo Pinto Neto
--
http://mail.python.org/mailman/listinfo/python-list
Clodoaldo Pinto Neto wrote:
> I'm just building a Python CGI Tutorial and would appreciate any
> feedback from the many experts in this list.
http://webpython.codepoint.net
--
http://mail.python.org/mailman/listinfo/python-list
Clodoaldo Pinto Neto wrote:
> I'm just building a Python CGI Tutorial and would appreciate any
> feedback from the many experts in this list.
http://webpython.codepoint.net
--
http://mail.python.org/mailman/listinfo/python-list
I'm just building a Python CGI Tutorial and would appreciate any
feedback from the many experts in this list.
Regards, Clodoaldo Pinto Neto
--
http://mail.python.org/mailman/listinfo/python-list
Thank you guys, you are great!
--
http://mail.python.org/mailman/listinfo/python-list
I know how to format strings using a dictionary:
>>> d = {'list':[0, 1]}
>>> '%(list)s' % d
'[0, 1]'
Is it possible to reference an item in the list d['list']?:
>>> '%(list[0])s' % d
Traceback (most recent call
ry:
> return self.allowed[node.name]
> except KeyError:
> raise Unsafe_Source_Error("Strings must be quoted",
> node.name, node)
>
Thank you both Michael and Felipe. The solutions work great!
Regards, Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
)
File "safe_eval.py", line 19, in visit
return meth(node, **kw)
File "safe_eval.py", line 47, in visitName
node.name, node)
__main__.Unsafe_Source_Error: Line 1. Strings must be quoted: True
This is just to let you know. I can live with that. I just replace True
for 1.
Regards, Clodoaldo Pinto
--
http://mail.python.org/mailman/listinfo/python-list
Is there a simple way to build a dictionary from a string without using
eval()?
>>> s = '{"a":1}'
>>> d = eval(s)
>>> d
{'a': 1}
Regards, Clodoaldo Pinto
--
http://mail.python.org/mailman/listinfo/python-list
easy and intuitive to learn, and in
> most cases it is. It just happens that division is one area where it is
> a bit awkward.
Right again !!
Although the Python way is almost always easy to learn I won't be
pythonic (as in specific to Python) where it won't help.
Regards, Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
Frank Millman wrote:
>
> We know that Python is in the process of changing the division
> operator. The main reason for the change is that the current approach
> is not intuitive to a newcomer (whether experienced or not).
>
> Why not think to the future, and do it like this. Instruct the reader
>
where this issue can be discussed.
http://programming-crash-course.com/integer_versus_float_division
Regards, Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
glish speaker I don't
know what sounds less mathematical and more natural. I changed integer
to whole following the previous suggestion but I really don't know.
Regards, Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
John Salerno wrote:
> Clodoaldo Pinto wrote:
>
> > "Python is a remarkably powerful dynamic programming language that is
> > used in a wide variety of application domains. Python is often compared
> > to Tcl, Perl, Ruby, Scheme or Java. Some of its key distin
I used
the term "integer" for the lack of a better one and I didn't mention
"float". Any suggestions?
Regards, Clodoaldo.
--
http://mail.python.org/mailman/listinfo/python-list
Bruno Desthuilliers wrote:
> Clodoaldo Pinto a écrit :
> > bill pursell wrote:
> >
> (snip)
> >>2) In the section on installing, you begin with:
> >>"Python is an interpreted, interactive, object-oriented programming
> >>language.". The comp
ary)
If you have any suggestions for that page's title please do so.
Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
The complete novice sees those words and expects
> them to be explained, but there is no definition given. I would
> recommend simplifying that sentence, or explaining the terms.
Ok, i will think about something, or just delete it.
Clodoaldo
--
http://mail.python.org/mailman/listinfo/python-list
I'm starting a programming tutorial for absolute beginners using Python
and I would like your opinions.
http://programming-crash-course.com
Regards, Clodoaldo Pinto
--
http://mail.python.org/mailman/listinfo/python-list
42 matches
Mail list logo