A commit (push) partition time and behavior into before and after (with
a short change period in between during which behavior is undefined).
Some commit messages have the form 'x does y'. Does 'does' mean before
or after? Sometimes that is clear. 'x crashes' means before. 'x return
correct va
On 5/9/2011 4:05 PM, Guido van Rossum wrote:
On Mon, May 9, 2011 at 12:36 PM, Eric Smith wrote:
On 05/09/2011 03:17 PM, Guido van Rossum wrote:
While my own preference is "make X properly raise an exception" I'm
happy with any of the alternatives proposed here, and grateful to
Terry for call
On 5/9/2011 1:54 PM, R. David Murray wrote:
If I do 'hg log' and search for a revno (that I got from hg annotate),
the commit message describing the change is not attached to that revno,
nor as far as I know is there a tool that makes it easy to get from that
revno to the explanatory commit mess
On 5/10/2011 10:59 AM, Nick Coghlan wrote:
On Tue, May 10, 2011 at 11:11 PM, R. David Murray wrote:
How about:
"reference to variable 'y' precedes an assignment that makes it a local
variable"
For comparison, the error messages I was able to elicit from 2.7 were
as follows:
# Module level
N
On 5/11/2011 12:39 PM, Éric Araujo wrote:
Funny, I always use the present tense, to convey what the code does now.
Which code ;-).
At the moment you write a push message, your private clone does
something different from the public repository (and other private
clones). At the moment people
On 5/11/2011 2:08 PM, Victor Stinner wrote:
Le mercredi 11 mai 2011 à 19:05 +0200, Éric Araujo a écrit :
Le 10/05/2011 01:52, victor.stinner a écrit :
http://hg.python.org/cpython/rev/3c87a13980be
changeset: 70001:3c87a13980be
branch: 2.7
parent: 69996:c9f07c69b138
user:Vict
On 5/18/2011 4:10 PM, Ethan Furman wrote:
Ethan Furman wrote:
[...]
Also posted to Python-Ideas.
Good. That is where it should have gone in the first place, as this is
about ideas not yet even in the PEP stage.
--
Terry Jan Reedy
___
Python-Dev
On 5/18/2011 2:51 PM, Ethan Furman wrote:
In Python 3 inequality comparisons became forbidden.
--> 123 < [1, 2, 3]
Traceback (most recent call last):
File "", line 1, in
TypeError: unorderable types: int() < list()
However, equality comparisons are still allowed
--> 123 == [1, 2, 3]
False
Bu
On 5/18/2011 10:19 AM, Nadeem Vawda wrote:
I'm not sure why you would encounter code like that in the first place.
Surely any code of the form:
''.join(c for c in my_string)
would just return my_string? Or am I missing something?
Good question. Anything useful like "'-'.join(c for c in
On 5/18/2011 5:34 PM, Victor Stinner wrote:
You initial example gave me the impression that the issue has something
to do with join in particular, or even comprehensions in particular. It
is really about for loops.
squares = (x*x for x in range(1))
>>> dis('for x in range(3): y = x
On 5/18/2011 5:37 PM, Amaury Forgeot d'Arc wrote:
Hi,
2011/5/18 Terry Reedy:
On 5/18/2011 10:19 AM, Nadeem Vawda wrote:
I'm not sure why you would encounter code like that in the first place.
Surely any code of the form:
''.join(c for c in my_string)
would just ret
On 5/18/2011 10:33 PM, anatoly techtonik wrote:
├[Python27]
│ ├─DLLs
│ ├─Doc
│ ├─include
│ ├─Lib
│ ├─libs
│ ├─Scripts
│ ├─tcl
│ └─Tools
Except for DLLs and tcl, these are the platform-independent names in the
source tree. They are copied directly over to the installations, and I
would not wa
On 5/18/2011 10:46 PM, anatoly techtonik wrote:
On Wed, May 18, 2011 at 10:37 PM, Georg Brandl wrote:
On 18.05.2011 21:09, "Martin v. Löwis" wrote:
http://hg.python.org/releasing/3.2.1/
To clarify: once the final is done, the repo Martin mentioned will be
merged back to main and then vani
On 5/19/2011 3:49 AM, Nick Coghlan wrote:
It's a mental model problem. People try to think of bytes as
equivalent to 2.x str and that's just wrong, wrong, wrong. It's far
closer to array.array('c').
Or like C char arrays
Strings are basically *unique* in
returning a length 1 instance of them
On 5/23/2011 1:20 PM, Ethan Furman wrote:
Glyph Lefkowitz wrote:
In fact, I feel like I would want to push in the opposite direction:
don't treat one-byte bytes slices less like integers; I wish I could
more easily treat n-byte sequences _more_ like integers! :). More
protocols have 2-byte or 4-
On 5/24/2011 8:25 AM, Sturla Molden wrote:
Artur Siekielski is not talking about cache locality, but copy-on-write
fork on Linux et al.
When reference counts are updated after forking, memory pages marked
copy-on-write are copied if they store reference counts. And then he
quickly runs out of m
On 5/24/2011 6:14 AM, M.-A. Lemburg wrote:
I have no idea why TextIOWrapper was added to the stdlib
instead of making StreamReaderWriter more capable,
since StreamReaderWriter had already been available in Python
since Python 1.6 (and this is being used by codecs.open()).
As I understand it, y
On 5/24/2011 6:27 AM, Nick Coghlan wrote:
On Tue, May 24, 2011 at 7:56 PM, Antoine Pitrou wrote:
Thank you very much! What a beautiful sight this is:
http://www.python.org/dev/buildbot/all/waterfall?category=3.x.stable
(until a sporadic failure comes up, that is)
I could turn test_crashers b
On 5/24/2011 12:06 PM, Victor Stinner wrote:
Le mardi 24 mai 2011 à 11:27 -0400, Terry Reedy a écrit :
+.. function:: RAND_bytes(num)
+
+ Returns *num* cryptographically strong pseudo-random bytes.
+
+ .. versionadded:: 3.3
+
+.. function:: RAND_pseudo_bytes(num)
+
+ Returns (bytes
On 5/24/2011 5:09 PM, srinivasan munisamy wrote:
Hi,
I would like to know how to set values to values to SQL_* constants
Please direct Python use questions to python-listor other user
discussion forums. Py-dev is for discussion of development of the next
versions of Python.
--
Terry Jan Ree
On 5/25/2011 1:09 AM, Nick Coghlan wrote:
The more important feature here is that it is exposing *OpenSSL's*
random number generation, rather than our own.
I agree, thought from a different stance, I think. The issue is whether
we should 'automatically' expose everything is a wrapped library,
On 5/26/2011 10:34 AM, Ronald Oussoren wrote:
On 26 May, 2011, at 16:10, Eric Smith wrote:
and make silent the Clang Static Analyzer :-)
I care less about that than maintainability and future-proofing.
Have to looked at the patch? The patch and resulting code look sane to me, and
if a
On 5/26/2011 2:08 PM, Guido van Rossum wrote:
Sorry to butt in here, but I agree with Eric that it was better
before. There is a common idiom, *pointer++ =, and
whenever you see that you know that you are appending something to an
output buffer. Perhaps the most important idea here is that this
On 5/27/2011 11:08 AM, Victor Stinner wrote:
Tell me if I am wrong, but only Marc-Andre is against deprecating StreamReader
While I am, in general, in favor of removing some duplication, I was and
am against doing this change precipitously. So I was for the reversion
(noted), at least tempor
On 5/31/2011 1:04 PM, anatoly techtonik wrote:
Hi,
I'd like to escalate http://bugs.python.org/issue12226 : 'use secured
channel for uploading packages to pypi' to be shipped with next Python
2.6+
This will prevent pydotorg password sniffing when submitting packages
through public networks (such
On 6/1/2011 1:37 AM, "Martin v. Löwis" wrote:
The requested one character change is
-DEFAULT_REPOSITORY = 'http://pypi.python.org/pypi'
+DEFAULT_REPOSITORY = 'https://pypi.python.org/pypi'
If Tarek (or perhaps Eric) agree that it is appropriate and otherwise
innocuous, then Martin and Ba
On 6/1/2011 6:50 PM, raymond.hettinger wrote:
- with open("mydata.txt") as fp:
- for line in iter(fp.readline, "STOP"):
> process_line(line)
As noted on the tracker, this will always loop forever. Even if "STOP"
is corrected to "STOP\n", it will still loop forever
On 6/7/2011 5:35 PM, David Malcolm wrote:
I know that this style is unpopular, but if it helps, try mentally
pronouncing "==" in C as "is the value of".
In this example, when I read that line, my mind is thinking:
"if 'u' is the value of typecode"
After ~12 years of doing this, it come
On 6/8/2011 3:30 PM, Tom Whittock wrote:
I'm writing in regards to http://bugs.python.org/issue1195571
I'm embedding Python in my application and ran into a need for this
functionality. I wrote a similar patch myself, and was about to submit
it. When I searched for similar issues I found that th
On 6/11/2011 6:32 AM, Petri Lehtinen wrote:
Nick Coghlan wrote:
[snip]
It seems to me that the intent of the pep and the current doc is that
field_names should match what one would write in code except that quotes
are left off of literal string keys. Which is to say, the brackets []
serve as
On 6/12/2011 1:57 PM, Benjamin Peterson wrote:
To download Python 2.7.2 visit:
http://www.python.org/download/releases/2.7.1/
That should be
http://www.python.org/download/releases/2.7.2/
--
Terry Jan Reedy
___
Python-Dev mailing list
Python-
On 6/12/2011 11:29 AM, Lukas Lueg wrote:
This sort of speculative idea might fit the python-ideas list better.
[Summary: we often need to extract a field or two from a binary record
in order to decide whether to toss it or unpack it all and process.]
One solution to this is using two format-
On 6/24/2011 7:18 AM, Victor Stinner wrote:
Le vendredi 24 juin 2011 à 10:52 +0200, Mark Dickinson a écrit :
One example: when opening a text file for reading and writing, the default
encoding used depends on the platform and on various environment variables.
... oh, I agree. This cho
On 6/25/2011 12:33 PM, Vlad Riscutia wrote:
I recently started looking at some ctypes issues. I dug a bit into
http://bugs.python.org/issue6069 and then I found
http://bugs.python.org/issue11920. They both boil down to the fact that
bitfield allocation is up to the compiler, which is different in
On 6/26/2011 2:52 PM, Senthil Kumaran wrote:
http://bugs.python.org/issue10403 is a documentation bug which talks
about using the term 'attribute' instead of the term 'member' when it
denotes the class attributes. Agreed.
But the discussion goes on to mention that,
"Members and methods" should
On 6/27/2011 4:24 AM, Antoine Pitrou wrote:
Le Mon, 27 Jun 2011 11:32:32 +1000,
Nick Coghlan a écrit :
"Members" is a historical relic that is best replaced by "attributes"
or "data attributes" if we want to explicitly exclude methods for some
reason. "Methods" is a subset of attributes that
On 6/27/2011 5:42 AM, Michael Foord wrote:
On 27/06/2011 09:24, Antoine Pitrou wrote:
FWIW, I tend to understand "members" as "methods + attributes", which
makes
it a nice term to use for that purpose.
That is my understanding / use of the terms as well.
On 6/27/2011 5:45 AM, Oleg Broytman
On 6/27/2011 2:33 PM, Terry Reedy wrote:
Let me repeat that that is historically wrong for Python, and illustrate
why the term 'members' should not be used. From the 1.5 Language
Reference, 3.2 Standard type hierarchy: "There are also some 'generic'
special attrib
On 6/28/2011 9:43 AM, Victor Stinner wrote:
In Python 2, open() opens the file in binary mode (e.g. file.readline()
returns a byte string). codecs.open() opens the file in binary mode by
default, you have to specify an encoding name to open it in text mode.
In Python 3, open() opens the file in
On 6/28/2011 10:02 AM, M.-A. Lemburg wrote:
How about a more radical change: have open() in Py3 default to
opening the file in binary mode, if no encoding is given (even
if the mode doesn't include 'b') ?
That'll make it compatible to the Py2 world again
I disagree. I believe
S = open('myfile
On 6/28/2011 10:06 AM, Antoine Pitrou wrote:
On Tue, 28 Jun 2011 15:43:05 +0200
Victor Stinner wrote:
- ISO-8859-1 os some FreeBSD systems
- ANSI code page on Windows, e.g. cp1252 (close to ISO-8859-1) in
Western Europe, cp952 in Japan, ...
- ASCII if the locale is manually set to an empt
On 6/28/2011 7:51 AM, R. David Murray wrote:
Also, instances can have methods as instance attributes.
Functions that are instance attributes do not act like methods
(instance.func() does not automagically turn instance in the first arg
of func) and have never, to my knowledge, been called me
On 6/28/2011 9:20 AM, Steven D'Aprano wrote:
>>> class C:
... def method(self, x):
... return x+1
...
>>> c = C()
>>> c.method = types.MethodType(lambda self, x: x+101, c)
types.MethodType creates a bound method, not a method. A bound method is
a partial or curried function, which is to sa
On 6/28/2011 10:48 AM, Michael Foord wrote:
On 28/06/2011 15:36, Terry Reedy wrote:
S = open('myfile.txt').read()
now return a text string in both Py2 and Py3 and a subsequent
'abc' in S
works in both.
Nope, it returns a bytestring in Python 2.
Which, in Py2 is a s
On 6/28/2011 10:46 AM, Paul Moore wrote:
I use Windows, and come from the UK, so 99% of my text files are
ASCII. So the majority of my code will be unaffected. But in the
occasional situation where I use a £ sign, I'll get encoding errors,
I do not understand this. With utf-8 you would never g
On 6/28/2011 11:35 AM, Michael Foord wrote:
On 28/06/2011 16:23, Terry Reedy wrote:
So-called 'staticmethods' are not really methods either, but are class
function attributes that are just functions and not treated as
methods. The decorator that negates normal method treatment
co
On 6/28/2011 5:42 PM, Georg Brandl wrote:
At the very least, a change like this needs a transitional strategy, like
it has been used during the 2.x series:
* In 3.3, accept "locale" as the encoding parameter, meaning the locale encoding
* In 3.4, warn if encoding isn't given and the locale enco
On 7/7/2011 7:28 AM, Antoine Pitrou wrote:
The main point of the PEP, IMO, is actually the deprecation itself. By
deprecating, we signal that something isn't actively maintained
anymore, and that a (allegedly better) alternative is available.
I think that's a very reasonable thing to do, regardl
On 7/18/2011 3:10 PM, Glenn Linderman wrote:
Attached reduced test case works fine with Python 3.1, fails with Python3.2:
SyntaxError: Non-ASCII character '\xc3' in file D:\my\py\t32enc.py on
line 1, but no encoding declared; see
http://www.python.org/peps/pep-0263.html for details
It runs fin
On 7/19/2011 12:21 PM, Paul Moore wrote:
On 19 July 2011 16:16, Antoine Pitrou wrote:
On Tue, 19 Jul 2011 16:00:57 +0100
Perhaps this could be changed? As far as I can see, python.exe is
a small executable around ~25KB (all the code being in the DLL), so
there doesn't seem to be any harm to
On 7/20/2011 3:22 AM, Paul Moore wrote:
On 20 July 2011 03:21, Terry Reedy wrote:
Suppose for Windows there were one '.../python' directory wherever the user
first asks it to be put and that all pythons, not just cpython, are
installed in directories below that and that the small st
On 7/20/2011 12:25 PM, Victor Stinner wrote:
Le 20/07/2011 17:58, Éric Araujo a écrit :
Do we have a policy of not adding new test files to stable branches?
New logging tests failed during some weeks. If we add new tests, we may
also break some stable buildbots. I don't think that we need to ad
On 7/20/2011 11:41 AM, r.david.murray wrote:
diff --git a/Lib/email/utils.py b/Lib/email/utils.py
# We need wormarounds for bugs in these methods in older Pythons (see below)
Is 'wormaround' (variation of workaround) an intentional play on the
fact that some worms prey on other 'bugs' ;-
On 7/20/2011 1:04 PM, P.J. Eby wrote:
This part worries me slightly. Imagine a program as such:
datagen.py
json/foo.js
json/bar.js
datagen.py uses the files in json/ to generate sample data for a
database. In datagen.py is the following code:
try:
import json
except ImportError:
import simple
On 7/21/2011 2:15 PM, Brett Cannon wrote:
It won't break any _existing_ code, but it could cause compatibility for
_future_ code. Imagine I wrote some code for 3.2.2 where this change was
backported and worked *only* with this fix. That would mean my code
would fail in any Python 3.2.1 or older
On 7/21/2011 2:58 AM, Raymond Hettinger wrote:
I concur with Brett. Nothing good will come from backporting tests that
aren't aimed at a specific bugfix.
They could catch reversions that otherwise would not be caught. This
would mainly apply to 2.7. It would not be an issue for 3.2 if all fix
On 7/20/2011 7:55 PM, Mark Hammond wrote:
On 21/07/2011 4:38 AM, Terry Reedy wrote:
Many installers first make an organization directory and then an app
directory within that. This annoys me sometimes when they only have one
app to ever install, but is useful when there might really be
On 7/27/2011 9:24 AM, Antoine Pitrou wrote:
On Wed, 27 Jul 2011 16:14:40 +0300
Eli Bendersky wrote:
Will it take long for newbie code to appear with the test.support version?
Not to mention that grepping code that imports the "unlink" function
directly doesn't reveal which one is being used.
On 7/27/2011 10:27 AM, Eli Bendersky wrote:
Initially I was *for* documenting, but this thing with showing up
in the index is a compelling counter-point.
"The basic version makes entries in the general index; if no index
entry is desired, you can give the directive option flag
On 7/27/2011 9:24 AM, Antoine Pitrou wrote:
Docstrings are sufficient for own our purposes.
>>> import test.support as t
>>> help(t.rmtree)
Help on function rmtree in module test.support:
rmtree(path)
;-)
--
Terry Jan Reedy
___
Python-Dev mailing
On 7/27/2011 1:27 PM, Brett Cannon wrote:
Perhaps what we could do is move the documentation for test.support to
the devguide, and then vet the test suite so that unlink and friends
are always called as 'support.unlink', etc.
I like this solution since this issue of documenting tes
On 7/27/2011 1:57 PM, Eli Bendersky wrote:
Out of curiosity, why would a user need to run Python's tests?
If one compiles Python, running the tests is essential.
Some people like to run a test suite to verify an installation.
Sometimes people have problems that might arise from an installation
On 7/29/2011 11:18 AM, Barry Warsaw wrote:
I'd much rather solve this problem by adding markup to functions that
explicitly disclaim our normal backward compatibility guarantees.
I suggested adding a footnote marker (1) to each one.
test.support *is* part of the stdlib.
So once again, is
On 7/29/2011 11:25 AM, Antoine Pitrou wrote:
t
We have lots of internal APIs which are not documented, though.
They are generally used only within the module itself as helper
functions. So one only needs to even know about them when looking at the
module code.
And test.support *is* for int
On 7/29/2011 5:32 PM, Antoine Pitrou wrote:
On Fri, 29 Jul 2011 11:51:18 -0400
Barry Warsaw wrote:
On Jul 29, 2011, at 05:25 PM, Antoine Pitrou wrote:
test.support *is* part of the stdlib.
We have lots of internal APIs which are not documented, though.
And test.support *is* for internal use
On 7/29/2011 6:54 PM, Antoine Pitrou wrote:
On Fri, 29 Jul 2011 18:47:07 -0400
Terry Reedy wrote:
And test.support *is* for internal use.
No, the stuff in there is *not* for internal use within the module but
for external use is possiby every test module.
I meant internal use for us
On 7/29/2011 7:27 PM, Antoine Pitrou wrote:
On Fri, 29 Jul 2011 19:02:32 -0400
Terry Reedy wrote:
On 7/29/2011 5:32 PM, Antoine Pitrou wrote:
On Fri, 29 Jul 2011 11:51:18 -0400
Barry Warsaw wrote:
The solution then is to rename test.support to test._support to make it clear
it'
Please add a link to the PEP index (which is also missing from
docs.python.org, though not from python.org/doc/.
And consider at least some PEPs as part of the corpus indexed (ie, those
with info not in the regular docs).
tjr
___
Python-Dev mailing
"Darrin Thompson" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| First of all 1000 apologies if this is the wrong list. Please redirect
| me if necessary.
Usage questions should usually be directed first to comp.lang.python /
gmane.comp.python.general / python-list (all 3 are int
"Raghuram Devarakonda" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| There is an entry in "Core and builtins" section of Misc/NEWS:
|
| "Bug #1722484: remove docstrings again when running with -OO.".
|
| The actual bug is 1722485. Incidentally, 1722484 appears to be spam.
Sure en
"Oodi Pilzer" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Hi, I am trying to duplicate the indenting functionality of the IDLE into
another environment used in an educational setting at MIT. As Python is
open software, I assume I can look at the source code for the IDLE. If
s
"Stephen J. Turnbull" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Raymond Hettinger writes:
|
| > [Matthieu on itertools.dropwhile() docs]
|
| > > Note, the iterator does not produce any output until the
| > > predicate is true
|
| > it did return EVERY element from the first fa
For me, .pyz is fine. Python has more or less a trademark on .pyx
extensions, and one more fits well. I think we should stick with them.
Confusion of .pyz with .py.z is not an issue with Windows users, though I
can understand how it might be for *nix users. On the other hand, pyzip is
quite
"Facundo Batista" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| >>> class C(object):
| ... def __cmp__(self, other):
| ... return NotImplemented
| ...
Given that you 'should' return an int, doing elsewise has undefined
results.
| >>> c = C()
| >>> print c < None
I
"Carlos Martínez" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Someone knows since as I can obtain the information detailed about the
| compiler of Python? (Table of tokens, lists of productions of the
syntactic
| one , semantic restrictions...)
Ask this sort of question on the
"Bruce Frederiksen" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
A 64K attachment. Please do not do such a worse-than-useless thing again.
Especially when only 1K is original.
___
Python-Dev mailing list
Python-Dev@python.org
http://
"Michael Foord" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Guido van Rossum wrote:
[snip first part of nice summary of Python i/o model]
| > The other translation deals with line endings. Upon input, any of
| > \r\n, \r, or \n is translated to a single \n by default (this is
"Michael Foord" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Terry Reedy wrote:
| > There are two normal ways for internal Python text to have \r\n:
| > 1. Read from a file with \r\r\n. Then \r\r\n is correct output (on the
| > same platform).
| > 2
"Nick Maclaren" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| The question is independent of what the outside system believes a
| text file should look like, and is solely what Python believes a
| sequence of characters should mean. For example, does 'A\r\nB'
| mean that B is sep
"Lauri Alanko" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| All this just shows that treating plain octet sequences as "strings"
| simply won't work in the long run. You have to have separate type for
| _textual_ data (i.e. Unicode strings, in Python), and encode and decode
| bet
"Raymond Hettinger" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|> I'm not sure about the name "propset" ...
| >Maybe something like "setproperty" would be better.
|
| I think not. Saying "setproperty" has too many ambiguous mental
parsings. When does "set" take place -- assig
""Martin v. Löwis"" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|> If yes, we have three paths to follow... leave 2.5 as is and say that
| > the behaviour change is ok (windows fault), change 2.5 to use the same
| > API than 2.4 and get the same behaviour, or hardwire the behaviou
"Gustavo Carneiro" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|I am finding myself often doing for loops over a subset of a list, like:
|
|for r in results:
|if r.numNodes != numNodes:
|continue
|# do something with r
Why write it
If I understand correctly, this would negate the need for staticmethod()
when accessing the function via the class (and not instances) since the
main effect of that is to prevent the wrapping. (And since I consider
instance.somestaticmeth() as even less idiomatic Python that
class.somestaticme
"Guido van Rossum" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|Do we need a PEP?
In my view, no. And I am a fan of PEPs. I personally saw unbound method
wrapping as more of a CPython implementation detail than an essential part
of the language definition. This in spite of i
"Guido van Rossum" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Also, there was discussion of this before:
| http://mail.python.org/pipermail/python-dev/2005-January/050625.html
| -- why didn't we decide to do it then?
1. Nobody ran with it.
2. There was mild concern with breaki
"Christian Heimes" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
||
| What name do you prefer? I'm +1 with Raymond on __root__ but I'm still
| open for better suggestions.
Ok with me, or __rootnames__, but __root_namespace__ is too long for me ;-)
__
"Nick Coghlan" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| [EMAIL PROTECTED] wrote:
| > Sorry if this is a dumb question, but are there actually good reasons
to remove "types"?
|
| Mainly because it is an unrelated grab bag of types that could be put in
| more topical locations
"Guido van Rossum" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| But then I thought, what if we renamed the __builtin__ module instead
| to builtins, and left __builtins__ alone?
|
| In Python 0.1, __builtin__ *was* called builtin, and I think the
| reason for renaming it wasn't p
"Greg Ewing" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| I think the situation with __main__ is different from __builtin__,
I effectively agreed by not disputing Guido's response ;-)
___
Python-Dev mailing list
Python-Dev@python.o
"Guido van Rossum" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| On Dec 1, 2007 7:09 PM, Neil Toronto <[EMAIL PROTECTED]> wrote:
| > Are there any use-cases for allowing namespace dicts (such as globals,
| > builtins and classes) to have non-string keys? I'm asking because I'm
| >
I would prefer plain 'yield' to 'yield break' as a synonym for 'raise
StopIteration'.
But the raise stands out better visually as an exit point.
The point about the raise not being explicitly caught is not valid since
any generator could be used in the following code
g = some_gen
try:
while
"Guido van Rossum" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Is it reading text or binary data from stream blah? We can't tell. If
| it's meant to be reading text, 2to3 should leave it alone. But if it's
| meant to be reading binary data, 2to3 should change the string
| liter
"Jameson "Chema" Quinn" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| I'm writing a source code editor that translates identifiers and keywords
| on-screen into a different natural language. This tool will do no
| transformations except at the reversible word level. There is one s
"Guido van Rossum" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Does no-one thinks it means round(f) either?
Not me. Int should truncate, so trunc() not needed unless is does
something different.
And I would prefer the float-input-only converters be in math. There is
nothi
""Martin v. Löwis"" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|> If the ambiguity is that 'int' behaviour is unspecified for floats - is
| > it naive to suggest we specify the behaviour?
|
| The concern is that whatever gets specified is arbitrary. There are many
| ways how an i
"Jeffrey Yasskin" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|| To elaborate the point I was trying to make: If float() does not mean
| "the float part of"
The 'float part' of a complex number is meaningless since both components
of a complex are floats (in practice, or reals i
"Nick Coghlan" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Raymond Hettinger wrote:
| > A prefix would be better.
|
| I initially thought that, but found the suffix to be the least annoying
| of the ideas I had for denoting abstract base classes. To try and give
|| INumber
|| AB
"Michael Urman" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| 2) The semantics of int() are fuzzy; even non-numeric types
| (strings) are handled
One could just as well say that the semantics of float() are fuzzy since it
also handles strings.
The actual claim seems to have b
"Eric Smith" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| The tests for float.__format__ are breaking on Windows, because of this
| issue: http://bugs.python.org/issue1600. Basically, Windows is using 3
| digits for exponents < 100, and Linux (and at least MacOS) are using 2.
|
1701 - 1800 of 2504 matches
Mail list logo