s import Counter
>>> stmt = "cur.execute('''SELECT url FROM files WHERE url = %s''', ( fullpath,
>>> )"
>>> chars_count = Counter(stmt)
>>> print("Number of '(': %d" % chars_count['('])
>>> pri
Νικόλαος Κούρας writes:
> Τη Τρίτη, 4 Ιουνίου 2013 9:18:29 μ.μ. UTC+3, ο χρήστης Lele Gaifax έγραψε:
>> Νικόλαος Κούρας writes:
>
>> >>> from collections import Counter
>> >>> stmt = "cur.execute('''SELECT url FROM files WHERE url
n the specific case, your line 64 is missing an ending colon (":").
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
standalone Python interpreter? Did you
notice something strange, something like that an empty line is missing
between headers and body?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it
e/path"
>>> path.replace('some', '')
Traceback (most recent call last):
File "", line 1, in
TypeError: expected bytes, bytearray or buffer compatible object
>>> path.replace(b'some', b'')
b'/path&
Skip Montanaro writes:
> He will get an extra blank line, since he added a newline character at
> the end of his Content-Type string.
Right, missed that, sorry for the noise.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | cominc
igning *constant* expressions to both variables,
most probably not what you meant
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
tool!
*Read* the error message, *look* at the arrow (i.e. the caret character
"^"), *understand* what that is trying to tell you...
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapens
ndications to your
SyntaxErrors, you *must* learn how to detect and fix those by yourself.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
get garbage characters, mojibake, or errors.
Uhm, no: "encode" transforms a Unicode string into an array of bytes,
"decode" does the opposite transformation. You cannot do the former on
an "arbitrary" array of bytes:
>>> s = "νίκος"
>&g
Νικόλαος Κούρας writes:
> Τη Κυριακή, 9 Ιουνίου 2013 11:55:43 π.μ. UTC+3, ο χρήστης Lele Gaifax έγραψε:
>> Uhm, no: "encode" transforms a Unicode string into an array of bytes,
>> "decode" does the opposite transformation. You cannot do the former
.
http://www.foxnews.com/story/0,2933,511177,00.html
Or maybe his encoding algorithm needs some refinement
:-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it |
nth+year) == "k" in (name and month and year)
> True
>
> so both seem to work as expected.
That happens only by chance: it seems you now understand the evaluation
of "boolean" expressions in Python, so the following should be clear to
you:
>>> "k"
result = emptylist or mylist
>>> result.append('bar')
>>> result is mylist
True
>>> print(mylist)
['foo', 'bar']
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
ng something
> different. It's measuring how much disk space the file is using. For
> most files, that's the number of characters in the file rounded up to a
> full block.
I think âdu -câ emits a number very close to âwc -câ.
ciao, lele.
--
nickname: Lele Gaifax | Qua
which under Python 2.7 is enabled by default, another thing is
the behaviour, that is whether the interpreter will give priority to the
sys.path.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi c
t;> à
1
:-)
back to easily-enumerable issues,
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
try:
host = socket.gethostbyaddr( os.environ['REMOTE_ADDR'] )[0]
except Exception as e:
host = "Reverse DNS Failed"
print(e)
?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas |
ut with that??
>>> a = 1/0 or 100
Traceback (most recent call last):
File "", line 1, in
ZeroDivisionError: division by zero
>>> a
Traceback (most recent call last):
File "", line 1, in
NameError: name 'a' is not def
except:
host = "Reverse DNS Failed"
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
> error handler. You should almost never have a bare except.
I know, that's why I added "(almost)", I was just trying to explain why
he wasn't able to see the problem.
Thanks for pointing out the difference,
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho
not callable",)
Dave already told you the reason[1]. Νίκος, *read* **and** *understand*
our *whole* answers to your questions, otherwise we are wasting time,
you, and us!
ciao, lele.
[1] “… The other one is perhaps more subtle; I replaced square brackets
with parentheses.”
--
nickname: L
r(e)
>
>> which yields: TypeError("'_Environ' object is not callable",)
>
> Any thoufgs as to why os.environ('REMOTE_ADDR') gives the above error?
Yes, I'd try to understand the error message, and eventually lookup the
documentation on os.enviro
coder that tried to translate it to Unicode.
As already explained, your immediate goal should be trying to understand
from *where* that byte string is coming. I can't help on that, sorry.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | co
Νίκος Gr33k writes:
> Στις 5/7/2013 1:59 μμ, ο/η Lele Gaifax έγραψε:
>> Νίκος Gr33k writes:
>>
>>> UnicodeDecodeError('utf-8', b'\xb6\xe3\xed\xf9\xf3
>>>
>>> but what string does it try to decode and jeeps failing?
>>
>>
vironment.
As Νίκος discovered, when he "cloudfare" (whatever that means) his site,
the REMOTE_HOST envvar contains some (I guess) latin-greek encoded
string, and the remote address is carried by a different envvar...
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello
ovide your exact street address when signed the contract
with your ISP, but now ask yourself: would you be happy if your ISP
gives that kind of information to whomever may ask for it (in the
specific case, a geolocation service like maxmind.com)?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò
nt: what is the character at the caret position?
I am convinced you are not conceptually understanding FST very well.
Alternatively, you may have a strange notion of “impossible”.
Or both.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincer
ce",
I'd suggest *you* should find a better implementation and propose it to
the core devs.
An even better suggestion, with due respect, is to get a life and find
something more interesting to do, or at least better arguments :-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di
This thread did not mention alternative and existing modules with
(almost) the same goal, two come to mind:
* https://pypi.python.org/pypi/sh
* https://pypi.python.org/pypi/sarge
bye, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò
get my head around all this codecs/unicode stuff. I
> haven't had to deal with it until now but I'm determined to not let it
> get the best of me :-)
Two good readings on the subject:
- http://nedbatchelder.com/text/unipain.html
- http://www.joelonsoftware.com/articles/Unicode.html
ciao,
t;> print _.hexdigest()
acbd18db4cc2f85cedef654fccc4a4d8
Do yourself a favor and learn using the interpreter to test your
snippets line by line, most problems will find an easy answer :-)
ciao, lele.
[1] http://docs.python.org/2.7/library/hashlib.html#module-hashlib
--
nickname: Lele Gai
the corresponding "short" integer value.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
ES (%s, %s) RETURNING (pin)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
http://mail.python.org/mailman/listinfo/python-list
Ferrous Cranus writes:
> Τη Πέμπτη, 24 Ιανουαρίου 2013 1:25:20 μ.μ. UTC+2, ο χρήστης Lele Gaifax
> έγραψε:
Please, trim your response messages, cutting away useless details.
>
> I just tried this statement:
>
> ==
> cursor.ex
> [/code]
How? What's the error message/traceback?
If, as Chris said, MySQL does not support the “RETURNING” syntax, you
cannot use that. I gave two different solutions in my previous message,
did you try the “simplest” one?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quel
nters.page=%s)
AND visitors.host=%s
But I wonder about the "logic" here: why are you storing the "useros",
"browser" and "date" in a table where the primary key seems to be
("pin", "host")? I mean, what happens if a user visits the same p
ails of *where* a
logger writes the messages are better left to a configuration done at another
level :)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortu
7;s difficult-to-impossible to get a
one-size-fits-all configuration that satisfies everybody (where the
cardinality of "everybody" exceeds 1, of course).
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura
If it's just a matter of "finding one", look no further and try out Emacs's
TRAMP :-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it |
cs.python.org/3/faq/design.html#why-does-python-use-methods-for-some-functionality-e-g-list-index-but-functions-for-other-e-g-len-list
and the next one.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l
Chris Warrick writes:
> Zope is effectively dead these days.
Except it's alive and kicking: https://blog.gocept.com/
:-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapen
p3.zip.zip.zip", while the other would be
"movie.avi.zip.zip.zip.zip.zip"... some sort of
https://en.wikipedia.org/wiki/Water_memory applied to file system entries :-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comin
he point, MacroPy! See https://github.com/azazel75/macropy for a
3.5+ version.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero,
hon-36m-x86_64-linux-gnu.so
$ python -c "import life; print(life.life())"
42
As other said, for a single function accepting no arguments and returning a
single value Cython may be an heavy tool, but I bet you can imagine more
complex situations...
ciao, lele.
--
nickname: Lele Gaif
he case you mentioned, but obviously that
function can very well come from a library.
> People use languages like Python to get away from this stuff.
Which people? The OP explicitly asked for a way to access a C module from
Python, and Cython surely is one option to accomplish that.
ciao, le
fe.so
>>> dir(life)
['__builtins__', '__doc__', '__file__', '__name__', '__package__', '__test__',
'life']
Can you try to import the "life" module and print its "dir()" to see the
symbols it expose
NULL.
>
> Mmm true. Forgot about that part. So, yes, that's a different type
> of failure that could be happening. Makes the audit a bit harder.
More probably the problem is not directly from a Python API, as most of the
time when such APIs return NULL they also call PyErr_SetX
'spam', 'eggs', 7) \
== identity(('spam', 'eggs', 7)) \
== identity((('spam', 'eggs', 7),)) \
== identity'spam', 'eggs', 7),),))
should yield True?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
Chris Angelico writes:
> On Fri, Dec 8, 2017 at 6:29 AM, Lele Gaifax wrote:
>> Chris Angelico writes:
>>
>>> On Fri, Dec 8, 2017 at 5:53 AM, Peter Otten <__pete...@web.de> wrote:
>>>>
>>>> Hm, what does -- and what should --
>
ery/blob/43ce2e8cdf54e4e1e8b0352e37adbd72e568e100/src/postgres/include/nodes/parsenodes.h
[4] https://github.com/lelit/pg_query/blob/master/pg_query/enums/parsenodes.py
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapen
http://pyx.sourceforge.net/ to produce the images
for a book[1] on the Carrom game, and I enjoyed its simplicity.
ciao, lele.
[1] https://bitbucket.org/lele/cta
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi c
ling lucky" Google advices.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
Skip Montanaro writes:
> I don't see any sort of "fdopen" or "freopen" equivalent mentioned in the io
> module documentation. Is this possible in a clean way?
>
There is an os.fdopen(), so maybe
newf = os.fdopen(fp.fileno())
ciao, lele.
--
nickname: Lele G
Cameron Simpson writes:
> My fingers know vim. Some others' fingers know emacs.
Emacs has also an Evil[1] mode, that mimics some vi/vim features.
I suggest taking a look at Doom Emacs[2], a popular so-called "Emacs
distribution", that provides an out-of-the-box great experience with a modular
c
ecall we had a very brief exchange on this at the time, and I event spent a
few days trying a quick&dirty approach (basically passing also the ordered
list of keywords...).
Anyway, we are in a new millenium now, and two major versions forward! ;-)
Thank you all,
ciao, lele.
--
nickname: Lele Ga
https://docs.python.org/3.6/library/textwrap.html#textwrap.dedent ?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
documentation
(https://docs.python.org/3.6/library/re.html#re.sub)
“unknown escapes [in the repl argument] such as \& are left alone”.
Am I missing something, or is this a regression?
In the meantime, I will alert the pgcli people.
Thanks in advance,
bye, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
Peter Otten <__pete...@web.de> writes:
> Lele Gaifax wrote:
>
>> The original intent is to replace spaces within a string with the regular
>> expression \s+ (see
>> ...
>> Accordingly to the documentation
>> (https://docs.python.org/3.6/library/re.htm
Chris Angelico writes:
> There's a shift as of 3.6 to make unrecognized alphabetic escapes into
> errors, or at least warnings.
But we are talking about raw strings here, specifically r'\s+'.
I agree that with plain strings it's a plus.
ciao, lele.
--
nickname: Lel
Lele Gaifax writes:
> And the documentation as well, to clarify the fact immediately, without
> assuming one will scroll down to the "changed in version" part (at least, that
> is what seem the rule in other parts of the manual).
Also, I'd prefer the "Changed in 3
Ned Batchelder writes:
> On Friday, October 14, 2016 at 12:50:44 PM UTC-4, Lele Gaifax wrote:
>> Chris Angelico writes:
>>
>> > There's a shift as of 3.6 to make unrecognized alphabetic escapes into
>> > errors, or at least warnings.
>>
Serhiy Storchaka writes:
> Seems the documentation is not accurate. Could you file a report on
> https://bugs.python.org/ ?
Thank you everybody answered!
Here it is: http://bugs.python.org/issue28450
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ier
}
>>> print(f'this is {k} and {v}')
this is 1 and 2
>>> print(f'Email: {d:{{k}} {{v}}}')
Traceback (most recent call last):
File "", line 1, in
NameError: name 'd' is not defined
ciao, lele.
--
nickname: Le
st recent call last):
File "", line 1, in
ValueError: Invalid format specifier
Which Python version are you using?
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
Ken Kundert writes:
> Lele,
> I am using Python3.6. d has to be an object of mydict.
My bad, sorry, I completely missed the premise :-|.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi co
top-posting?
>> The answers that precede the questions
>>> What's the most boring thing in e-mails?
:-)
ciao, lele.
--
nickname: Lele Gaifax | Perché è contrario al normale senso di lettura
real: Emanuele Gaifas | > Cosa c'è di male nel rispondere in cima?
l...@metapensier
is correct, why not make len also as a part of list
> class itself?
Yes, that's correct. For the reason, see
https://docs.python.org/3/faq/design.html#why-does-python-use-methods-for-some-functionality-e-g-list-index-but-functions-for-other-e-g-len-list
ciao, lele.
--
nickname: Lele Gaifax
Paul Rubin writes:
> Lua is supposed to be easy to embed and sandbox. It might be
> interesting to write Python bindings for the Lua interpreter sometime.
Isn't this something similar to already existing
https://pypi.python.org/pypi/lupa/?
ciao, lele.
--
nickname: Lele Gaifax | Q
his helps,
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
n't
find a way to alter that name.
Did I miss something, or is the only way to duplicate the source .pyx file to
a different name?
Thanks in advance,
ciao, lele.
(*) https://github.com/lelit/pglast/blob/master/setup.py#L76
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
Greg Ewing writes:
> You could try creating a set of top-level .pyx stubs, each of
> which just 'include' the real code.
Thank you, will try this approach!
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad a
Ethan Furman writes:
> If you don't get an answer here, you can try the Cython Users group:
Thanks, reposted the same question there.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi
ve confused its meaning:
>>> class Base:
... pass
...
>>> class Derived(Base):
... pass
...
>>> print(Base.__subclasses__())
[]
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò a
est" nor the name "cv" are defined...
Thanks in advance for any enlightenment!
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
if callable(v):
print(" a callable, returning", v())
else:
print(" a value,", v)
In this case, it would be less practical to determine what the script defined:
by any chance this case is the first I wrote, and here the choice to pass the
t
bout this. Dunno how
far it has gone wrt Python support, but the following mode appeared in
MELPA archives in the last couple of days:
https://github.com/ankurdave/color-identifiers-mode
hth, ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | com
t just a glitch?
thanks in advance,
bye, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
Thank you Peter and Mark for the links.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python
n support on Debian systems,
but I think Daniele is missing the package "pythonX.Y-venv": they install the
needed stuff, and in particular /usr/bin/pyvenv-X-Y.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver p
Chris Warrick writes:
>> I am maters student in India,
>
> We don’t care (expect that you made a typo there).
Oh, really? Surprisingly, he's not alone :-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad
te = 'a'
elif nextchar in self.quotes:
if not self.posix:
self.token = nextchar
self.state = nextchar
...
I was not able to lookup an exact definition of netrc's syntax, so I wonder:
is the implementation somewhat flawed, or am I missing something?
Thanks in a
netrc-xxx, and comes from net/netrc.el.
Cfr. also https://www.emacswiki.org/emacs/GnusAuthinfo.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depe
ed down too, and act accordingly?
just-for-the-sake-of-arguing-ly, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
* return the object they are applied
(self that is).
This works though:
>>> box = [1,3,2]
>>> sorted(box) == [1,2,3]
True
hth, ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi m
Steven D'Aprano writes:
> if not (a is b is None): ...
>
> Or if you prefer:
>
> if a is not b is not None: ...
>>> 1 is not 1 is not None
False
So definitely the former!
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: E
Python\TestCases\list_dir_script.txt"
>
> or just use forward slashes:
>
> u"c:/automation_common/Python/TestCases/list_dir_script.txt"
The latter should be preferred, in case Python3 compatibility is a goal.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di que
)
> True
Yes, I bet in stupid languages that would be either a single character,
or a tuple of two or more characters, much more usable and compact.
> —
>
> PS A "mole" is not a number.
Oh, nice to know. And OOC, what is a "mole" in your stupid science?
OTOH, WTF
MRAB writes:
> On 15/08/2013 15:38, Lele Gaifax wrote:
>> wxjmfa...@gmail.com writes:
>>> PS A "mole" is not a number.
>>
>> Oh, nice to know. And OOC, what is a "mole" in your stupid science?
>> OTOH, WTF does that matter in current th
Chris Angelico writes:
> It may be that the -ext accelerator isn't available for Py3 in package
> form, or it might be incorporated, I don't know.
AFAICT, the Py3 accelerators will be available with SA 0.9.
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho p
from the underlying
nginx... I was finally able to register an account with the "manual"
method on the live site, but I'd prefer to learn the upload procedure on
the test site...
Are these known problems?
Thanks in advance,
bye, lele.
--
nickname: Lele Gaifax | Quando vivrò di quell
The actual syntax would be
[object method: arg1 withSomething: arg2 withSomethingElse: arg3]
and IMHO once you train your eyes the result is very readable, and
closely resembles Python's keywords (and I took advantage of the
similarity when I enjoyed developing PyObjC :)
ciao, lele.
--
nickna
Gregory Ewing writes:
> Steven D'Aprano wrote:
>> On Tue, 22 Oct 2013 09:38:16 +0200, Lele Gaifax wrote:
>>
>>>The actual syntax would be
>>>
>>> [object method: arg1 withSomething: arg2 withSomethingElse: arg3]
>>
>> I don't
lue) VALUES (%s, %s)" %
(myid, myvalue)
>>> print(mysql)
INSERT INTO sometable (theid, thevalue) VALUES (theid, Italy, Europe)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...
=dict()"
1000 loops, best of 3: 0.113 usec per loop
$ python3 -m timeit "d={}"
1000 loops, best of 3: 0.0601 usec per loop
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver p
Skip Montanaro writes:
> I also figure there must be some established best practices for exposing C++
> classes to Python.
Maybe http://docs.cython.org/src/userguide/wrapping_CPlusPlus.html?
bye, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele
live in a very strange corner!
;-)
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
Chris Angelico writes:
> On Sat, May 23, 2015 at 3:24 AM, Lele Gaifax wrote:
>> Laura Creighton writes:
>>
>>> In my corner of the world, everybody uses SQL.
>>> [...]
>>> The people who have tried SQLAlchemy really didn't like it, and of cou
Chris Angelico writes:
> On Sat, May 23, 2015 at 5:12 AM, Lele Gaifax wrote:
>> You are conflating two different layers, core and ORM. ORM relationships can
>> be declared either on the parent or on the child, it's up to your taste.
>
> Not sure why that's distin
t;> type(res)
>>> type(res[0])
>>> type(res[0].name)
>>> type(res[0][0])
>>> res[0].name == res[0][0]
True
ciao, lele.
--
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
l...@metapensiero.it | -- Fortunato Depero, 1929.
--
https://mail.python.org/mailman/listinfo/python-list
1 - 100 of 167 matches
Mail list logo