Ezio Melotti added the comment:
FWIW I recently made a talk at PyCon Finland called "Understanding Encodings"
that goes through the things you mentioned in the last message.
I could turn that in a patch for the Unicode Howto.
--
___
Pyth
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue13866>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
keywords: +easy
nosy: +ezio.melotti
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue13999>
___
___
Python-
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue14003>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> needs patch
___
Python tracker
<http://bugs.python.org/issue14034>
___
___
Python-bugs-list mai
Ezio Melotti added the comment:
See #13770 and #13769.
--
nosy: +eric.araujo
___
Python tracker
<http://bugs.python.org/issue14042>
___
___
Python-bugs-list m
Ezio Melotti added the comment:
We could just mention that a TypeError is raised if some of the elements can't
be compared. (Note that sorting a list that contains some types that cannot be
compared might still succeed in some corner cases, but there's no reason to
me
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue11698>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
Actually I would change the devguide/patch.html page to focus less on mq (but
this is a bit orthogonal).
The easiest thing to do is to make some changes and use "hg diff > patch.diff"
and the devguide should advertise this IMHO. This also works fi
Changes by Ezio Melotti :
--
nosy: +francismb
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue13447>
___
___
Python-bugs-list mai
Ezio Melotti added the comment:
Can you paste (or upload) a minimal working example (with a short sample
string) that uses re.split and str.split and shows how re.split is failing?
--
___
Python tracker
<http://bugs.python.org/issue14
Ezio Melotti added the comment:
As long as you don't mix str and unicode everything works.
With strings:
>>> s = '与清新。阿德莱'
>>> re.split('。', s)
['\xe4\xb8\x8e\xe6\xb8\x85\xe6\x96\xb0', '\xe9\x98\xbf\xe5\xbe\xb7\xe8\x8e\xb1']
>
Ezio Melotti added the comment:
+1
Patch attached.
--
assignee: -> ezio.melotti
keywords: +patch
nosy: +ezio.melotti
stage: needs patch -> commit review
Added file: http://bugs.python.org/file24597/issue14081.diff
___
Python tracker
Ezio Melotti added the comment:
> I went for something even simpler: one new file Lib/test/test_tools.py.
I'm fine with this option too; if it grows too big we can always split it in
several modules later.
> My only concern is communication: how do we tell people working on a
Ezio Melotti added the comment:
This behavior is now documented, but the situation could still be improved.
Adding a new method that receives the converted entity seems a good way to
handle this. The parser can call both, and users can pick either one.
One problem with the current methods
Ezio Melotti added the comment:
I tried to reproduce it on 3.1 and 3.2 but it worked fine here (WinXP).
This is what I did:
1) open IDLE;
2) file --> new window;
3) write some text;
4) select with the mouse some text;
5) press shift and keep it pressed;
6) press end;
7) press home;
8) rele
Ezio Melotti added the comment:
Converting sounds good to me, but it should be done carefully.
I think you can have two paragraphs in the docstrings: the first with the
description of what it does and what it returns, and the second with the
arguments.
For example Lib/xml/etree
New submission from Ezio Melotti :
I was reading the "introduction" page of the tutorial [0], and noticed a few
things that could be improved:
1) the first paragraph is a bit confusing, showing a simple example and
explaining what the >>> is would be better;
2) comment
Changes by Ezio Melotti :
--
nosy: +haypo, pitrou
stage: -> patch review
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue14100>
___
__
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue14103>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
The attached patch addresses 8) -- you might want to use it as a starting point
(that's what I was going to fix before deciding to do a full review of the
page).
--
assignee: rhettinger -> docs@python
keywords: +patch
Added file: http://bugs.py
Changes by Ezio Melotti :
--
stage: test needed -> committed/rejected
___
Python tracker
<http://bugs.python.org/issue13909>
___
___
Python-bugs-list mai
Ezio Melotti added the comment:
New patch that changes .rsplit() too and updates docs and docstrings.
--
Added file: http://bugs.python.org/file24625/issue14081-2.diff
___
Python tracker
<http://bugs.python.org/issue14
Ezio Melotti added the comment:
Fixed, thanks for the report and the patch.
--
assignee: -> ezio.melotti
nosy: +ezio.melotti
resolution: -> fixed
stage: -> committed/rejected
type: -> enhancement
___
Python tracker
<http://
Changes by Ezio Melotti :
--
stage: -> test needed
versions: +Python 3.3 -Python 3.1
___
Python tracker
<http://bugs.python.org/issue8077>
___
___
Python-
Changes by Ezio Melotti :
--
nosy: +eric.araujo
versions: +Python 3.3 -Python 3.1
___
Python tracker
<http://bugs.python.org/issue1112955>
___
___
Python-bug
Changes by Ezio Melotti :
--
nosy: +eli.bendersky
stage: needs patch -> test needed
versions: +Python 3.3 -Python 3.1
___
Python tracker
<http://bugs.python.org/issu
Changes by Ezio Melotti :
--
keywords: +patch
stage: needs patch -> patch review
versions: +Python 3.3 -Python 3.2
___
Python tracker
<http://bugs.python.org/iss
Changes by Ezio Melotti :
--
versions: -Python 3.1
___
Python tracker
<http://bugs.python.org/issue12817>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/issue1531415>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/issue1116520>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
stage: -> needs patch
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue9056>
___
___
Python-bugs-list
Ezio Melotti added the comment:
"$" refers to JQuery, and should be defined in
http://docs.python.org/_static/jquery.js.
Maybe you have to import/include that file before
http://docs.python.org/_static/copybutton.js?
There are also other js scripts there that use JQuery so I'
Ezio Melotti added the comment:
> Be careful with whitespace changes.
Here I agree with you and disagree with the PEP 8 (specifically where it says
that "hypot2 = x*x + y*y" and "c = (a+b) * (a-b)" are "wrong").
In
- >>> 3+1j*3
+ >>> 3 +
Ezio Melotti added the comment:
Even if they know the meaning of "shallow" (which is not a really common word
AFAICT), they might not know what it means in this context.
Adding an entry to glossary might be a better solution.
In this context I think the best solution would be t
Ezio Melotti added the comment:
18bbfed9aafa is the changeset that introduced the copy button.
Maybe the part in the "extrahead" (in Doc/tools/sphinxext/layout.html, see also
first chunk of the diff) block shouldn't be
Ezio Melotti added the comment:
> FWIW it's pretty much the only way of saying what it means.
However, even using "not deep" here would still be ambiguous. What's a deep
copy? What's a non-deep copy?
Using "shallow" might be a problem, but the real prob
Ezio Melotti added the comment:
JQuery and the other scripts (like sidebar.js) are part of Sphinx, whereas the
copy button is something that was added to our instances only, by changing the
template.
--
___
Python tracker
<http://bugs.python.
Ezio Melotti added the comment:
Should be fixed now, let me know if it works.
(Thanks Georg for the help.)
--
stage: -> committed/rejected
type: -> behavior
___
Python tracker
<http://bugs.python.org/i
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> patch review
type: -> enhancement
versions: -Python 3.1, Python 3.4
___
Python tracker
<http://bugs.python.org/i
Ezio Melotti added the comment:
Fixed!
Thanks for the reviews and for spotting the extra '['.
(While suggesting the use of maxsplit, be aware that str.split uses -1 as
default value, whereas re.split uses 0.)
--
resolution: -> fixed
stage: commit review -> committed
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue14128>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
nosy: +ezio.melotti, facundobatista, gregory.p.smith, orsenthil
___
Python tracker
<http://bugs.python.org/issue14132>
___
___
Pytho
Ezio Melotti added the comment:
Note that the 2.7 docs now use a recent Sphinx too, so :c:macro: should work on
all the 3 branches (so you don't have to use :cmacro: on 2.7 and :c:macro: on
3.x).
--
___
Python tracker
<http://bugs.py
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: needs patch -> committed/rejected
type: -> enhancement
___
Python tracker
<http://bugs.python.org/i
Ezio Melotti added the comment:
This is a new patch based on Martin work.
I don't think it's necessary to explain what happens while using r'\b' or r'\B'
on an empty string in the doc -- that's not a common case and it might end up
confusing users. I thin
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> patch review
versions: -Python 3.2
___
Python tracker
<http://bugs.python.org/issue8706>
___
___
Py
Ezio Melotti added the comment:
On one hand I agree that it would be nice to get rid of these implementation
details that prevent some C functions/methods to accept keyword args, but on
the other hand I'm not sure that changing them all is the right thing to do.
For some functions/me
Ezio Melotti added the comment:
FWIW PyPy doesn't seem to support keyword args for e.g. str.join() (so that's
extra work for them too), and I don't see what would be the advantage of being
able to do '-'.join(iterable=a_list). Even if I also don't see a valid r
Ezio Melotti added the comment:
See
http://docs.python.org/faq/design.html#why-can-t-raw-strings-r-strings-end-with-a-backslash
--
nosy: +ezio.melotti
resolution: -> invalid
stage: -> committed/rejected
status: open -> closed
___
Pytho
Changes by Ezio Melotti :
--
stage: -> committed/rejected
___
Python tracker
<http://bugs.python.org/issue14145>
___
___
Python-bugs-list mailing list
Un
Changes by Ezio Melotti :
--
stage: needs patch -> committed/rejected
versions: +Python 2.7, Python 3.2
___
Python tracker
<http://bugs.python.org/issu
Changes by Ezio Melotti :
--
stage: patch review -> committed/rejected
___
Python tracker
<http://bugs.python.org/issue13086>
___
___
Python-bugs-list mai
Ezio Melotti added the comment:
Fixed, thanks for the patch!
--
assignee: docs@python -> ezio.melotti
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python
Ezio Melotti added the comment:
Patch attached.
--
assignee: docs@python -> ezio.melotti
components: +Regular Expressions
keywords: +patch
nosy: +mrabarnett
stage: -> patch review
Added file: http://bugs.python.org/file24677/issue1415
Ezio Melotti added the comment:
Fixed.
I changed something, as suggested by Éric.
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Ezio Melotti added the comment:
Fixed, thanks for the patch!
--
assignee: -> ezio.melotti
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
type: behavior -> enhancement
___
Python
Ezio Melotti added the comment:
Converting prints to warnings on 3.2 might not be a good idea. I can probably
still apply the rest of the patch there, and change the warnings on 3.3 only.
--
___
Python tracker
<http://bugs.python.org/issue13
Ezio Melotti added the comment:
Matthew, do you think this should be documented somewhere or that the behavior
should be changed (e.g. raising a warning when 65535 is used)?
If not I'll just close the issue.
--
___
Python tracker
Changes by Ezio Melotti :
--
keywords: +needs review
___
Python tracker
<http://bugs.python.org/issue9041>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
IMHO the documentation is fine as is. Using pos in combination with
lookarounds that match on the beginning/end of the "slice" seems a rather
uncommon corner case, and I don't think it's worth documenting it. Even if it
was documented
Changes by Ezio Melotti :
--
stage: -> needs patch
___
Python tracker
<http://bugs.python.org/issue11379>
___
___
Python-bugs-list mailing list
Unsubscri
Changes by Ezio Melotti :
--
components: +Interpreter Core
nosy: +eric.araujo, ezio.melotti, pitrou
stage: -> needs patch
versions: -Python 2.6
___
Python tracker
<http://bugs.python.org/issu
Ezio Melotti added the comment:
The attached patch seems to do the trick (not sure if it's the best way to fix
the issue though):
>>> open('woo\raa')
>>> open('woo\ra\'a', 'w')
>>> open('woo\ra\'a"',
Ezio Melotti added the comment:
Do you think I should mention that you can still use match and a regex that
starts to ^ in combination with the start argument of r.match to match at the
beginning of a line?
I'm not sure that's
Ezio Melotti added the comment:
> also: just because an argument is listed in the docs with a name does
> not mean that that name is the most appropriate; part of adding keyword
> support should be choosing a sensible name.
I agree, but other implementations might not have this l
Changes by Ezio Melotti :
--
components: +Unicode -None
nosy: +ezio.melotti
type: -> behavior
___
Python tracker
<http://bugs.python.org/issue14176>
___
___
Py
Ezio Melotti added the comment:
"Minimal" sounds good to me, it also matches the name of the module.
--
___
Python tracker
<http://bugs.python.o
Ezio Melotti added the comment:
Because it looks like line noise and doesn't provide an useful information in
most of the cases (at least for me), see e.g.:
+ test_format (__main__.MyTestCase) ... [0.000612s] skipped 'not supported in
this library version'
+ test_no
Changes by Ezio Melotti :
--
nosy: +eli.bendersky, ezio.melotti, flox
stage: -> needs patch
___
Python tracker
<http://bugs.python.org/issue14178>
___
___
Py
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> patch review
type: -> enhancement
versions: +Python 2.7, Python 3.2
___
Python tracker
<http://bugs.python.org/i
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> patch review
type: -> enhancement
versions: +Python 2.7, Python 3.2
___
Python tracker
<http://bugs.python.org/i
Ezio Melotti added the comment:
This was fixed in 8de95f3b2404 (3.2) and d4b17c478e49 (default).
Thanks for the report and the patch!
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python track
Ezio Melotti added the comment:
You should try to port the patch to 3.3 and do some benchmark there.
Having some additional tests to make sure that it works fine in all the cases
would be nice too (even if listcomps are already used elsewhere in the
code/tests).
--
nosy
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> needs patch
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue14135>
___
___
Ezio Melotti added the comment:
Yep, #12707.
--
___
Python tracker
<http://bugs.python.org/issue4773>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
Thanks for the patch, but I think Brett meant to say that this should be added
to Lib/test/regrtest.py:750, among the other resources.
--
___
Python tracker
<http://bugs.python.org/issue14
Changes by Ezio Melotti :
--
nosy: +haypo, loewis, ned.deily, terry.reedy
type: -> crash
___
Python tracker
<http://bugs.python.org/issue14200>
___
___
Python-
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue14187>
___
___
Python-bugs-list mai
Ezio Melotti added the comment:
You forgot to use raw strings:
>>> text = "The cat ate the rat."
>>> print("before: %s" % text)
before: The cat ate the rat.
>>> text = re.sub("(\w+) ate the (\w+)", r"\2 ate the \1", text)
>&
Changes by Ezio Melotti :
--
nosy: +haypo, loewis
___
Python tracker
<http://bugs.python.org/issue14227>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
stage: -> patch review
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue14217>
___
___
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue8754>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
My opinion is that in general you should worry about the semantic of the
role/directive you are using, rather than its aspect while rendered.
Some entries (especially some directives) might benefit from a rendered
example, but I don't think it's ne
Ezio Melotti added the comment:
> I also agree. I'm just thinking someone who reads that doc should be
> able to see the output without building anything.
Indeed I wasn't thinking about this use case, but IME people learn most of they
know about rst "on the field" (i
Ezio Melotti added the comment:
Can you provide a minimal example to reproduce this error?
On Python 2 it's always better to decode the HTML first and then pass unicode
to the parser. Even though on Python 2 the parser accepts bytes string too,
there are a few corner cases where it
Ezio Melotti added the comment:
See also #3932.
--
___
Python tracker
<http://bugs.python.org/issue14251>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
I don't think the patch can be applied as is -- in order to work s should be an
ascii-only str. I will look at this again as soon as I have some time and see
if something can be done.
FTR the Python 3 doc for html.parser can be found here:
Ezio Melotti added the comment:
FWIW searching for "annotations" in the Sphinx quick search doesn't yield
anything interesting, and the first result that actually contains a paragraph
about annotations is the 11th (comp
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue14258>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ezio Melotti added the comment:
Fixed, thanks for the patches!
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by Ezio Melotti :
--
assignee: -> ezio.melotti
___
Python tracker
<http://bugs.python.org/issue13394>
___
___
Python-bugs-list mailing list
Unsubscri
Ezio Melotti added the comment:
Fixed, thanks for the patch!
--
assignee: -> ezio.melotti
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python
Ezio Melotti added the comment:
I test this again and indeed a bare s.decode() is not enough to fix the
problem. The attribute might contain non-ascii characters, and that will
result in an error (see for example the "test.py" script attached to #3932).
The correct solution is
Ezio Melotti added the comment:
See #13241.
--
nosy: +ezio.melotti
resolution: -> duplicate
stage: -> committed/rejected
status: open -> closed
superseder: -> llvm-gcc-4.2 miscompiles Python (XCode 4.1 on Mac OS 10.7)
___
Python tr
Ezio Melotti added the comment:
What it's trying to say is that in case the operation in the "try" block
succeeds there's almost no overhead, so it's very efficient. On the other
hand, raising and then catching the error is expensive.
-
Ezio Melotti added the comment:
Most of the patches are against 3.2 or 2.7, so applying them to "default" might
fail.
If we specify the correct branch, rietveld should be able to apply them cleanly
to the head of the branch even without knowing the exact revision (so even with
git-
Ezio Melotti added the comment:
Raymond, I think it's better to leave the documentation and use
"deprecated-removed" to signal clearly that those functions are deprecated and
when they will be removed (even if this means 3.4).
IME removing documentation creates more confusion
Ezio Melotti added the comment:
I don't mind if they are removed in 3.3 or 3.4, as long as they are documented
in all the versions where they are present.
--
___
Python tracker
<http://bugs.python.org/is
Changes by Ezio Melotti :
--
nosy: +ezio.melotti
___
Python tracker
<http://bugs.python.org/issue14326>
___
___
Python-bugs-list mailing list
Unsubscribe:
901 - 1000 of 1631 matches
Mail list logo