R. David Murray added the comment:
Well, I'm not so attached to the unexpected skip list that I want to block this
from getting implemented. So I guess the bottom line is that things that are
unexpected skips now should not be fai
R. David Murray added the comment:
The general approach of the patch looks good to me. Since formataddr is
designed to be called from user code that is constructing a message, having it
raise for non-ascii in the address is probably OK. However, there should be a
test for that, and I
R. David Murray added the comment:
You should check if 'charset' is a string, and call Charset on it only if it is
(a Charset may be passed directly in other email package interfaces, and so
should be supported here as well.
The test doesn't need to cater for the fact that ei
R. David Murray added the comment:
Thanks. Looks good except that it should check isinstance(string) rather than
isinstance(Charset), that way someone can pass a custom class that implements
the Charset API if they want. (Alternatively, the check could be for an
encode_header method
R. David Murray added the comment:
Ah, yes. Header is probably wrong there, I should fix that at some point.
Sorry for the misytpes in my last message (it was late at night for me when I
wrote it :)
As for time, it probably didn't take any more time than it would have to write
it m
Changes by R. David Murray :
--
versions: -Python 2.7, Python 3.1, Python 3.2
___
Python tracker
<http://bugs.python.org/issue1690608>
___
___
Python-bugs-list m
R. David Murray added the comment:
This seems to be causing some issues on the buildbots:
http://www.python.org/dev/buildbot/all/builders/AMD64%20Snow%20Leopard%202%203.x/builds/137
--
nosy: +r.david.murray
status: closed -> open
___
Python trac
Changes by R. David Murray :
--
keywords: -easy
___
Python tracker
<http://bugs.python.org/issue9205>
___
___
Python-bugs-list mailing list
Unsubscribe:
R. David Murray added the comment:
All the references I could find talk about triggering the match without the
proceeding newline. That is, it is not certain that a blank line will precede
the 'From ' header, and the typical quoting rules for mbox format call for any
'From
New submission from R. David Murray :
As part of the email6 design, the email-sig came up with the idea of
simplifying the current email API by introducing the concept of "policy
objects". A policy object is an object that hold various parameters and
methods that can be used to c
R. David Murray added the comment:
I have a vague memory of changing some code, in linecache I think, that
involved anonymous names. I might have fixed it by accident.
--
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue4
R. David Murray added the comment:
I don't know what re is doing with respect to locale, but I do know that the
implementation of string.letters is at least somewhat broken in 2.x. It has no
useful meaning in unicode, which is why it doesn't exist in 3.x.
A standard that talks a
Changes by R. David Murray :
--
nosy: +pitrou
___
Python tracker
<http://bugs.python.org/issue11746>
___
___
Python-bugs-list mailing list
Unsubscribe:
R. David Murray added the comment:
Yeah, as far as I could tell from a brief scan of google hits, locale support
in regex in general is a legacy thing, and the "correct" thing to do is to use
unicode properties. So I'll close this as won't fix. If someone comes along
wi
R. David Murray added the comment:
Actually, this is a duplicate of issue 9951.
--
nosy: +r.david.murray
resolution: invalid -> duplicate
stage: -> committed/rejected
superseder: -> introduce bytes.hex method
___
Python track
R. David Murray added the comment:
Using assertRaises as a context manager is not a hack, and is the correct way
to do this in unittest.
--
nosy: +r.david.murray
status: open -> closed
___
Python tracker
<http://bugs.python.org/issu
R. David Murray added the comment:
For some reason the create patch button isn't working (perhaps because I'm
using a named branch?), so here is a patch representing the current state of
the feature branch.
--
keywords: +patch
Added file: http://bugs.python.org/file21533/po
Changes by R. David Murray :
Removed file: http://bugs.python.org/file21533/policy.patch
___
Python tracker
<http://bugs.python.org/issue11731>
___
___
Python-bugs-list m
R. David Murray added the comment:
Try again with a patch going in the expected direction :)
--
Added file: http://bugs.python.org/file21534/policy.patch
___
Python tracker
<http://bugs.python.org/issue11
R. David Murray added the comment:
Well, it's two years later, but I did look at this during the sprints at PyCon,
though I didn't get as far as posting it then (I only just now rediscovered the
patch on my laptop).
Python3 no longer has a "binary" flag on base64mime.
New submission from R. David Murray :
I discovered the attached failure case in the process of investigating another
issue. The bug (a continuation line with no leading white space) doesn't exist
in 2.7, but in 2.7 the extra whitespace is not preserved (that is, the output
of the new
R. David Murray added the comment:
I'm working on this. It appears to be a bug in the bytes parser, rather than
the generator.
--
___
Python tracker
<http://bugs.python.org/is
R. David Murray added the comment:
Although there's a (different) bug in the generator, too, I think :)
--
___
Python tracker
<http://bugs.python.org/is
R. David Murray added the comment:
No, the need for an encoding parameter for read/write makes it unambiguous that
it is indeed a feature.
--
resolution: -> wont fix
status: open -> closed
___
Python tracker
<http://bugs.python.org/i
R. David Murray added the comment:
The goal of tolerant mode is to accept anything a typical browser would accept.
I suspect that means the tolerant regex should stay, but I don't remember the
details.
As for the strictas far as I know the current module follows 4.01, not 5.
I&
R. David Murray added the comment:
Here is a patch against 3.2, with test. Simple fix, but it took me a while to
track down the critical piece of code.
--
keywords: +patch
stage: needs patch -> patch review
Added file: http://bugs.python.org/file21546/parse_8bit_multipart.pa
R. David Murray added the comment:
Ah, it isn't broken, it's just that the default changed. In 2.x, the default
was maxlinelen=78, in 3.x, the default is maxlinelen=None (unlimited), but
generator passes in an override of 78 when formatting output. So you can
specify an explicit
Changes by R. David Murray :
--
assignee: -> r.david.murray
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue11780>
___
___
Python-
R. David Murray added the comment:
Thanks for the testing.
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by R. David Murray :
--
assignee: -> r.david.murray
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue11684>
___
___
Python-
Changes by R. David Murray :
--
assignee: -> r.david.murray
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue11782>
___
___
Python-
R. David Murray added the comment:
Finally got around to committing this; thanks, Torsten. As a reward, I'm going
to make you nosy on a new, related issue I'm about to create. It is, of
course, your option whether you want to work on it :)
By the way, have you submitted a c
New submission from R. David Murray :
The patch for issue 1690608 adds support for unicode in the realname field to
formataddr. To complete the currently-workable internationalization of address
specs, both parseaddr and formataddr should be made IDNA aware. It is probably
a good idea to do
R. David Murray added the comment:
Issue 1690608 addresses part of this issue, and issue 11783 will address the
IDNA part.
>From my point of view those two issues solve this problem from the perspective
>the email package infrastructure and *current* API. In the email6 API I do
&g
New submission from R. David Murray :
Attached is a patch. I'm not sure that I've done everything that needs to be
done on the Windows side, though. Martin?
--
keywords: +patch
nosy: +loewis
Added file: http://bugs.python.org/file21550/build_update_for_test_e
Changes by R. David Murray :
--
assignee: -> r.david.murray
___
Python tracker
<http://bugs.python.org/issue11781>
___
___
Python-bugs-list mailing list
Un
Changes by R. David Murray :
--
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue11785>
___
___
Python-bugs-list mailing list
Unsubscribe:
R. David Murray added the comment:
It is not clear from the docs what the expected behavior of factory is. It is
certainly the case that the custom classes used by mailbox by default do not
close the file they are passed. So either those classes should close the input
file and factory
Changes by R. David Murray :
--
assignee: docs@python -> r.david.murray
___
Python tracker
<http://bugs.python.org/issue11785>
___
___
Python-bugs-list mai
R. David Murray added the comment:
You have to do an 'encode' to get the wrapped header. __str__ uses
maxlinelen=None.
However, there does seem to be a problem with the line wrapping algorithm
revealed by your example: it is only doing a line break at the ';', not at
R. David Murray added the comment:
Sounds fine to me.
--
___
Python tracker
<http://bugs.python.org/issue7311>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by R. David Murray :
Removed file: http://bugs.python.org/file21554/11767.patch
___
Python tracker
<http://bugs.python.org/issue11767>
___
___
Python-bugs-list m
R. David Murray added the comment:
get_file's promise is that what is returned is a file like object, so it not
having a close() method would be an error. So I don't think you need the
try/except. What I would suggest is to use the 'closing' context manager
around the r
R. David Murray added the comment:
Given your problem report wouldn't the simplest solution be to change the close
method to be:
if hasattr(self, '_file'):
if hasattr(self._file, 'close'):
self._file.close()
del self._file
As for a test, i
R. David Murray added the comment:
I don't understand what you are saying about raising a ValueError on close. f
= open('x'); f.close(); f.close() does not raise any error, as Amaury pointed
out.
So I still don't understand the motivation fo
R. David Murray added the comment:
OK, it looks like the wrapping problem arises when the line contains runs of
blank delimited tokens longer than maxlinelen *and* the line also contains
';'s. The line is then split at the ';' and the remaining overlong pieces are
not sp
R. David Murray added the comment:
Here is a patch containing three test cases that demonstrate three different
failings of the header folding algorithm. I'm working on the fix, but it is
non-trivial.
--
components: +Library (Lib) -None
keywords: +patch
title: email.header.H
Changes by R. David Murray :
Removed file: http://bugs.python.org/file21563/header_folding_tests.patch
___
Python tracker
<http://bugs.python.org/issue11492>
___
___
Pytho
R. David Murray added the comment:
Note that 2.7 fails two of these tests as well, but for different reasons. I'm
not currently planning to fix 2.7, as its behavior at least (a) doesn't lose
non-whitespace information and (b) doesn't exceed the maxheaderlen.
--
A
R. David Murray added the comment:
Ah, that's exactly why I suggested using the 'closing' context manager from
contextlib. That context manager returns the object passed to it, and then
when its __exit__ method is called, calls the close method of that object that
w
Changes by R. David Murray :
Removed file: http://bugs.python.org/file21564/header_folding_tests.patch
___
Python tracker
<http://bugs.python.org/issue11492>
___
___
Pytho
R. David Murray added the comment:
Here is an updated test patch that brings the test coverage of the relevant
code much closer to 100%. There are still three lines and one branch
uncovered, but it appears as though one of the bugs is preventing the test case
that would produce full
R. David Murray added the comment:
To a pythonista, the perl behavior is counter-intuitive :)
That said, the behavior of r'\' *is* somewhat counter-intuitive. See issue
1271 for a fairly thorough exploration of why it is the way it is.
--
nosy: +r.da
R. David Murray added the comment:
I shouldn't have assumed that you knew about contextlib, and should have
mentioned it by name the first time.
The patch looks good to me. Not sure it is necessary to loop through ten fake
mailboxes, but it doesn't hurt, either. (Other potential
R. David Murray added the comment:
Putting in a size limit is reasonable. We did this for fnmatch not that long
ago (issue 7846). That was in fact the inspiration for lru_cache.
--
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.
R. David Murray added the comment:
I believe Torsten is interested, but he can of course speak for himself.
Just to make sure you are aware: Python has a built in idna codec, so this
should be a fairly simple patch.
--
___
Python tracker
<h
R. David Murray added the comment:
Terry, the test is in the other issue, so this time Steffen has provided the
test :).
I'll take a look at both issues, probably next week.
--
___
Python tracker
<http://bugs.python.org/is
R. David Murray added the comment:
Python 2.7 is closed for new features, I afraid. And Berkeley DB is not
included in the Python3 stdlib. It has reverted to being maintained entirely
as a third party package.
--
nosy: +r.david.murray
resolution: -> rejected
stage: -> com
Changes by R. David Murray :
--
resolution: -> duplicate
stage: needs patch -> committed/rejected
status: open -> closed
superseder: -> email.header.Header doesn't fold headers correctly
___
Python tracker
<http://bugs.p
R. David Murray added the comment:
This was quite the adventure. The more I worked on fixing the tests, the more
if/else cases the existing splitting algorithm grew. When I reached the point
where fixing one test broke two others, I thought maybe it was time to try a
different approach
R. David Murray added the comment:
Note that this fix solves issue 11772, so I've closed that one as a duplicate.
--
___
Python tracker
<http://bugs.python.org/is
R. David Murray added the comment:
Nudge: report on the Ubuntu bug tracker that this is still an issue with 3.2:
https://bugs.launchpad.net/bugs/517552
--
nosy: +r.david.murray
versions: +Python 3.2, Python 3.3
___
Python tracker
<h
R. David Murray added the comment:
I vote for (2) (I presume 'it' in that sentence is 'subprocess'). list2cmdline
shouldn't be a "real" public method, at least not without the issues
surrounding being given careful design attention
R. David Murray added the comment:
Patch mostly looks good to me, modulo some English wording that I'll fix up
when I commit it.
The issue with the '@' is that it might not be there. So you do need to check
for that case (it means the domain part defaults to the 'local&
R. David Murray added the comment:
Ah, right. I guess I was advocating that the docs be written from the
perspective that list2cmdline doesn't exist as an identifiable entity. From
the POV of the updated docs, it is just subprocess's behavior, and list2cmdline
is an implementat
R. David Murray added the comment:
Hmm. You are correct. I thought the RFC's covered this case, but apparently
they don't.
The email package gets used in MUA contexts, where the domain part of the
address may be omitted and the MUA must fill it in before transmitting the
mess
R. David Murray added the comment:
Well, if it is judged a bug (and it seems to me that it is), then it can get
fixed in 2.7 and 3.2 (and yes I did confirm that the same bug is present in
2.7).
It appears to be the result of startswith/endswith applying naive parsing to
their arguments
R. David Murray added the comment:
It's a doc issue. Doc issues are pretty much by definition easy in the sense
of the easy keyword (doable in a day) (unless they are controversial), so we
don't bother to attach the easy keyword to them.
--
nosy: +r.da
Changes by R. David Murray :
--
nosy: +mark.dickinson, skrah
___
Python tracker
<http://bugs.python.org/issue11830>
___
___
Python-bugs-list mailing list
Unsub
R. David Murray added the comment:
Thanks, Sandro.
--
assignee: bob.ippolito ->
nosy: +r.david.murray
resolution: accepted -> fixed
stage: commit review -> committed/rejected
status: open -> closed
___
Python tracker
<http://
R. David Murray added the comment:
Thanks for working on this.
The tests seem to be missing, as is the line that adds 'clean' to the def, so
the patches won't work as is.
However, now that I've looked at the patch in more detail, adding a parameter
to a public method is
R. David Murray added the comment:
For easy reference, here's a hash for that changeset that roundup will turn
into a link: e727cf354720.
TestIdempotent is already run for both the bytes and str cases (they are widely
separated in the test file...I'll fix that at
Changes by R. David Murray :
--
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue8809>
___
___
Python-bugs-list mailing list
Unsubscribe:
R. David Murray added the comment:
OK, so when I went to apply this, I figured out that the patch isn't quite
right. I've redone the doc updates, and am attaching a version of the patch
containing them.
The issue is that the place that the IDNA decode support needs to be added
R. David Murray added the comment:
I applied this as part of #11684. Thanks.
--
resolution: -> fixed
stage: -> committed/rejected
status: open -> closed
type: -> behavior
___
Python tracker
<http://bugs.python
R. David Murray added the comment:
Thanks for correcting my oversight :)
--
resolution: -> accepted
stage: -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by R. David Murray :
--
versions: -Python 3.2
___
Python tracker
<http://bugs.python.org/issue11684>
___
___
Python-bugs-list mailing list
Unsubscribe:
R. David Murray added the comment:
Yes, putting the function in _parseaddr is fine. And yes, 232 looks like a
good place. The alternative would be understanding the rfc822 parser, which is
pretty mind bending, and of doubtful additional benefit. (At most it would
save a pair of split/join
R. David Murray added the comment:
Despite the apparent similarity, your issue is something different from what
was reported in this issue. Could you please open a new issue for your problem?
--
nosy: +r.david.murray
___
Python tracker
<h
R. David Murray added the comment:
Éric did a review of the previous patch (mostly doc stuff) which should
be pretty much addressed in this new version of the patch.
I'd like to propose this version (modulo any forthcoming comments) for
commit to trunk. I've removed some paramet
Changes by R. David Murray :
Removed file: http://bugs.python.org/file21662/policy_for_review.patch
___
Python tracker
<http://bugs.python.org/issue11731>
___
___
Pytho
Changes by R. David Murray :
Added file: http://bugs.python.org/file21663/policy_for_review.patch
___
Python tracker
<http://bugs.python.org/issue11731>
___
___
Python-bug
R. David Murray added the comment:
Like Stefan says, use the default build options with the checkout. If it
works, then the problem is an Ubuntu bug, and not a Python bug.
--
___
Python tracker
<http://bugs.python.org/issue8
R. David Murray added the comment:
What I hope is the final patch, after Barry's review, and Éric's second.
--
Added file: http://bugs.python.org/file21674/policy_final.patch
___
Python tracker
<http://bugs.python.o
Changes by R. David Murray :
--
assignee: -> r.david.murray
___
Python tracker
<http://bugs.python.org/issue11701>
___
___
Python-bugs-list mailing list
Un
R. David Murray added the comment:
Here's a patch that fixes the reported bug (calling close twice fails with an
AttributeError) the simple way.
Note that there was actually a test for the buggy behavior, which is rather odd
considering that there is also a 'closed' method
R. David Murray added the comment:
Ah. Well, since the io module and its classes didn't exist when that code in
mailbox.py was written, no, that's not what happened :)
Nor does 'file like object' in Python necessarily mean conformance to the io
specification. We a
R. David Murray added the comment:
Thanks. I should be able to look at this tomorrow.
You are correct about the fact that Message currently doesn't do any decoding.
That is part of the design: you get the string out of Message and use the
helper decoding functions (decode_h
R. David Murray added the comment:
Updated patch addressing Stefen and Ezio's comments.
--
Added file: http://bugs.python.org/file21699/mailbox_close_twice.patch
___
Python tracker
<http://bugs.python.org/is
New submission from R. David Murray :
Attached is a patch to remove the last sleeps from test_mailbox. I believe
this makes the test suite deterministic. It also shaves 4 seconds of fixed
overhead off the test run time.
--
components: Tests
files: mailbox_fork_with_ipc.patch
Changes by R. David Murray :
--
versions: +Python 2.7
___
Python tracker
<http://bugs.python.org/issue11867>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by R. David Murray :
--
priority: -> normal
___
Python tracker
<http://bugs.python.org/issue11828>
___
___
Python-bugs-list mailing list
Unsubscri
Changes by R. David Murray :
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
R. David Murray added the comment:
This is fixed in 3.2/3.3 by the fix for issue 11492. The suggested fix for 2.7
is more radical than I'm comfortable with for a point release. I'm open to
argument on that, but in the meantime I'm closing the issue with 11492 as
R. David Murray added the comment:
As of the fix for issue 11492, the email package only uses continuation_ws when
folding RFC2047 encoded words. So I consider this issue fixed. (I have, by
the way, come around to the view that we should never be introducing or
deleting whitespace except
R. David Murray added the comment:
This now works correctly in 3.2/3.3 (see issue 11492). Note that the
whitespace compression is too deeply embeded in the 2.7 email package for there
to be any way to fix it there.
--
resolution: -> duplicate
stage: test needed -> com
R. David Murray added the comment:
Thanks for testing this. I was afraid something like that would happen, since
socket implementations are different on different platforms. I presume you ran
it on OSX.
Now I have to decide if I want to fix it, or if I should just switch to using
threads
R. David Murray added the comment:
I think the fix is to either put a try/except around the socket shutdown call,
or to remove it entirely (I think things will still work right on linux without
it). If you leave the self.c_sock_close = True in, it should take care of the
resource warning
R. David Murray added the comment:
This is a repeatable error? What is your system timezone set to? The
difference is exactly one half hour. Does the test pass if you change the
calendar.timegm call to have '0' or '1' as the last element of the tuple
instead of
Changes by R. David Murray :
--
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue11873>
___
___
Python-bugs-list mailing list
Unsubscribe:
1101 - 1200 of 10554 matches
Mail list logo