On Mon, Apr 21, 2008 at 8:10 PM, Gregory P. Smith <[EMAIL PROTECTED]> wrote:
>
>
>
> The 64K hunch is wrong. The system limit can be found using
> getsockopt(...SO_RCVBUF...). It can easily be (and often is) set to many
> megabytes either at a system default level or on a per socket level by the
On Tue, Apr 15, 2008 at 2:21 AM, Stefan Behnel <[EMAIL PROTECTED]> wrote:
> Neal Norwitz wrote:
> > Iteration with the dict methods (e.g., keys -> iterkeys()),
> > map/zip/filter returning iterator rather than list.
>
> That's only an optimisation, it's not functionally required. A list behaves
> IMO, encoding estimation is something that many web programs will have
> to deal with
Can you please explain why that is? Web programs should not normally
have the need to detect the encoding; instead, it should be specified
always - unless you are talking about browsers specifically, which
need
David Wolever wrote:
> IMO, encoding estimation is something that
> many web programs will have to deal with,
> so it might as well be built in; I would prefer
> the option to run `text=input.encode('guess')`
> (or something similar) than relying on an external
> dependency or worse yet using a ha
On 21-Apr-08, at 5:31 PM, Martin v. Löwis wrote:
This is useful when you get a hunk of data which _should_ be some
sort of intelligible text from the Big Scary Internet (say, a posted
web form or email message), and you want to do something useful with
it (say, search the content).
I don't think
Steven Bethard wrote:
I'm not a big fan of the sequence-or-callable argument. Why not just
make it a callable argument, and supply a utility function
Or have two different keyword arguments, one for a sequence
and one for a callable.
--
Greg
___
Pyth
Steven wrote:
It might help if you explain what sort of actual things that the user does
wrong that you are talking about.
Usually it's some kind of parsing error. Or it might be a
network connection getting closed unexpectedly.
Essentially it's anything due to factors outside the
program's co
On Mon, Apr 21, 2008 at 06:37:20PM -0300, Rodrigo Bernardo Pimentel wrote:
> On Mon, Apr 21 2008 at 06:31:06PM BRT, "\"Martin v. L??wis\"" <[EMAIL
> PROTECTED]> wrote:
> > > This is useful when you get a hunk of data which _should_ be some
> > > sort of intelligible text from the Big Scary Inter
On Mon, Apr 21 2008 at 06:31:06PM BRT, "\"Martin v. Löwis\"" <[EMAIL
PROTECTED]> wrote:
> > This is useful when you get a hunk of data which _should_ be some
> > sort of intelligible text from the Big Scary Internet (say, a posted
> > web form or email message), and you want to do something us
> This is useful when you get a hunk of data which _should_ be some
> sort of intelligible text from the Big Scary Internet (say, a posted
> web form or email message), and you want to do something useful with
> it (say, search the content).
I don't think that should be part of the standard
> | This problem has now been worked-around, by reformulating the test cases
> | so that the situation doesn't occur anymore, but IMO, it should not be
> | possible for an extension module to cause an interpreter abort.
>
> Agreed. But I can't test Windows builds myself. Could anybody help me in
>
At 1:14 PM -0400 4/21/08, David Wolever wrote:
>On 21-Apr-08, at 12:44 PM, [EMAIL PROTECTED] wrote:
>>
>> David> Is there some sort of text encoding detection module is the
>> David> standard library? And, if not, is there any reason not
>> to add
>> David> one?
>> No, there's not. I
On Mon, Apr 14, 2008 at 4:41 PM, Curt Hagenlocher <[EMAIL PROTECTED]>
wrote:
> On Mon, Apr 14, 2008 at 4:19 PM, Guido van Rossum <[EMAIL PROTECTED]>
> wrote:
> >
> > But why was imaplib apparently specifying 10MB? Did it know there was
> > that much data? Or did it just not want to bother looping
Guido> Note that the locale settings might figure in the guess.
Alas, locale settings in a web server have little or nothing to do with the
locale settings in the client submitting the form.
Skip
___
Python-Dev mailing list
Python-Dev@python.org
ht
Michael> The only approach I know of is a heuristic based approach. e.g.
Michael> http://www.voidspace.org.uk/python/articles/guessing_encoding.shtml
Michael> (Which was 'borrowed' from docutils in the first place.)
Yes, I implemented a heuristic approach for the Musi-Cal web server
To the contrary, an encoding-guessing module is often needed, and
guessing can be done with a pretty high success rate. Other Unicode
libraries (e.g. ICU) contain guessing modules. I suppose the API could
return two values: the guessed encoding and a confidence indicator.
Note that the locale setti
Christian Heimes schrieb:
> David Wolever schrieb:
>> Is there some sort of text encoding detection module is the standard
>> library?
>> And, if not, is there any reason not to add one?
>
> You cannot detect the encoding unless it's explicitly defined through a
> header (e.g. the UTF BOM). It's
On Sun, Apr 20, 2008 at 5:25 PM, Steven Bethard
<[EMAIL PROTECTED]> wrote:
>
> On Sun, Apr 20, 2008 at 4:15 PM, Tarek Ziadé <[EMAIL PROTECTED]> wrote:
> > I have submitted a patch for review here: http://bugs.python.org/issue2663
> >
> > glob-style patterns or a callable (for complex cases) can
Alexander Belopolsky schrieb:
>> ruby: undefined method `[]=' for 1:Fixnum (NoMethodError)
>
> I think it will be natural to unify [] error message with
> the other binary ops:
>
> Now:
1+""
> Traceback (most recent call last):
> File "", line 1, in
> TypeError: unsupported operand type(s
On 21-Apr-08, at 12:44 PM, [EMAIL PROTECTED] wrote:
>
> David> Is there some sort of text encoding detection module is the
> David> standard library? And, if not, is there any reason not
> to add
> David> one?
> No, there's not. I suspect the fact that you can't correctly
> determ
On Mon, 21 Apr 2008 17:50:43 +0100, Michael Foord <[EMAIL PROTECTED]> wrote:
>[EMAIL PROTECTED] wrote:
>> David> Is there some sort of text encoding detection module is the
>> David> standard library? And, if not, is there any reason not to add
>> David> one?
>>
>> No, there's not. I
David Wolever schrieb:
> Is there some sort of text encoding detection module is the standard
> library?
> And, if not, is there any reason not to add one?
You cannot detect the encoding unless it's explicitly defined through a
header (e.g. the UTF BOM). It's technically impossible. The best you
[EMAIL PROTECTED] wrote:
> David> Is there some sort of text encoding detection module is the
> David> standard library? And, if not, is there any reason not to add
> David> one?
>
> No, there's not. I suspect the fact that you can't correctly determine the
> encoding of a chunk of te
David> Is there some sort of text encoding detection module is the
David> standard library? And, if not, is there any reason not to add
David> one?
No, there's not. I suspect the fact that you can't correctly determine the
encoding of a chunk of text 100% of the time mitigates again
> ruby: undefined method `[]=' for 1:Fixnum (NoMethodError)
I think it will be natural to unify [] error message with
the other binary ops:
Now:
>>> 1+""
Traceback (most recent call last):
File "", line 1, in
TypeError: unsupported operand type(s) for +: 'int' and 'str'
Proposal:
>>> 1[2]
Tra
Is there some sort of text encoding detection module is the standard
library?
And, if not, is there any reason not to add one?
After some googling, I've come across this:
http://mail.python.org/pipermail/python-3000/2006-September/003537.html
But I can't find any changes that resulted from that
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Martin v. Löwis wrote:
| I think it would be helpful if you could analyze the crashes that bsddb
| caused on Windows. Just go back a few revisions in the subversion tree
| to reproduce the crashes.
I have no MS Windows machines in my environment :-(
Hello. I noticed when I removes following line in trunk/PC/pyconfig.h
#define Py_WIN_WIDE_FILENAMES
_fileio.c and posixmodule.c (and maybe more) cannot be compiled on Windows.
When Py_WIN_WIDE_FILENAMES is not defined, how should python behave?
- call posix functions like open(2)
- call A
The pattern matching uses the src_dir to call glob.glob(), which returns
the list of files to be excluded. That's why I added within the
copytree() function.
To make an excluding_patterns work, it could be coded like this::
def excluding_patterns(*patterns):
def _excluding_patterns(fi
29 matches
Mail list logo