Re: [Python-Dev] Revert #12085 fix for __del__ attribute error message

2013-09-25 Thread Glenn Linderman
like Uncaught exception in __del__ | method ignored? It explains fairly clearly what has | happened, and also indicates what do do about it -- | catch it in the __del__ method. | | Exception in __del__ caught and not propagated: | Georg On 24Sep2013 09:33, Glenn Linderman v+pyt...@g.nevcal.com

Re: [Python-Dev] Revert #12085 fix for __del__ attribute error message

2013-09-24 Thread Glenn Linderman
On 9/24/2013 5:51 AM, Nick Coghlan wrote: Why not just say something like Cannot propagate exception...; it's simpler than Unpropagatable exception That would definitely be an improvement on the status quo and avoids Antoine's concern about an adjective being interpreted as an inherent

Re: [Python-Dev] Revert #12085 fix for __del__ attribute error message

2013-09-22 Thread Glenn Linderman
On 9/22/2013 9:29 PM, Guido van Rossum wrote: On Sunday, September 22, 2013, Nick Coghlan wrote: Brevity is still a virtue. The relevant C API function is called PyErr_WriteUnraisable, so just starting the message as something like Unraisable exception suppressed in... might work.

Re: [Python-Dev] License() release list is imcomplete; intentional?

2013-09-17 Thread Glenn Linderman
On 9/17/2013 10:51 AM, Guido van Rossum wrote: But only the PSF has the list of original contributors and their licenses. So can that list be made public, and available in multiple archives? ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] TransformDict (PEP 455) Naming

2013-09-16 Thread Glenn Linderman
On 9/15/2013 11:28 PM, anatoly techtonik wrote: Does anybody know if http://vote.python.org is already operational? I decided to start a separate thread for TransformDict name, because I want to change it. Current implementation of PEP 455 only touches dictionary keys and it is more narrow than

Re: [Python-Dev] Add a transformdict to collections

2013-09-12 Thread Glenn Linderman
On 9/12/2013 8:40 AM, Antoine Pitrou wrote: Le Thu, 12 Sep 2013 08:05:44 -0700, Ethan Furman et...@stoneleaf.us a écrit : On 09/12/2013 07:43 AM, Antoine Pitrou wrote: Yeah, so this is totally silly. What you're basically saying is we don't need TransformDict since people can re-implement it

Re: [Python-Dev] Offtopic: OpenID Providers

2013-09-10 Thread Glenn Linderman
On 9/6/2013 10:22 AM, Dan Callahan wrote: On 9/5/13 12:31 PM, Jesus Cea wrote: I have big hopes for Mozilla Persona, looking forward Python infrastructure support :). Hi, I'm the project lead on Persona signin, and I spoke at PyCon earlier this year regarding why and how Mozilla is building

Re: [Python-Dev] Add a transformdict to collections

2013-09-10 Thread Glenn Linderman
On 9/10/2013 8:54 AM, Janzert wrote: I intuitively expected, and I think most often would want, the first key to be held. My intuition matches yours, but my thoughts are that it should be changeable by specific request. ___ Python-Dev mailing

Re: [Python-Dev] Offtopic: OpenID Providers

2013-09-10 Thread Glenn Linderman
On 9/10/2013 8:08 AM, Guido van Rossum wrote: Why do several posts in this thread have an Unsubscribe link that tries to unsubscribe me from the list? (I saw one by Glen, and another one by Donald Stufft.) Seems to be in all of them. Probably added by the mailing list software. Why don't you

Re: [Python-Dev] Add a transformdict to collections

2013-09-10 Thread Glenn Linderman
On 9/10/2013 2:46 PM, Antoine Pitrou wrote: Which reminds one - this class should obviously have a method for retrivieng the original key value, given a matching key - d.canonical('foo') - 'Foo' I don't know. Is there any use case? (sure, it is trivially implemented) Well, I'd

Re: [Python-Dev] Offtopic: OpenID Providers

2013-09-05 Thread Glenn Linderman
On 9/5/2013 1:30 PM, Tres Seaver wrote: +1 for supporting Persona as an alternative to OpenID on all *.python.org servers. Is there a Python implementation of Persona I can install on my web server? ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] Completing the email6 API changes.

2013-09-02 Thread Glenn Linderman
On 9/1/2013 8:03 PM, Stephen J. Turnbull wrote: This is getting off-topic IMO; we should probably take this thread to email-sig. Probably, but you didn't :) Glenn Linderman writes: I recall being surprised when first seeing messages generated by Apple Mail software, that are multipart

Re: [Python-Dev] Completing the email6 API changes.

2013-09-02 Thread Glenn Linderman
On 9/2/2013 2:40 PM, R. David Murray wrote: I'm still not understanding how the text/plain part*refers* to the related parts. I don't think the text/plain part can refer to the related parts, but, like you, am willing to be educated if there is a way; but while the text/html may be able to if

Re: [Python-Dev] Completing the email6 API changes.

2013-09-01 Thread Glenn Linderman
On 9/1/2013 3:10 PM, R. David Murray wrote: This doesn't work, though, because you could (although you usually won't) have more than one 'text/html' part in a single multipart. I was traveling and your original message is still unread in my queue of things to look at later :( I haven't

Re: [Python-Dev] format, int, and IntEnum

2013-08-14 Thread Glenn Linderman
On 8/14/2013 9:27 PM, Nick Coghlan wrote: I think Eric is overinterpreting the spec, there. While that particular sentence requires that the empty format string will be equivalent to a plain str() operation for builtin types, it is only a recommendation for other types. For enums, I believe

Re: [Python-Dev] The Return Of Argument Clinic

2013-08-05 Thread Glenn Linderman
On 8/5/2013 1:48 AM, Larry Hastings wrote: The impl should know whether or not it failed. So it's the interface we're defining that forces it to throw away that information. If we provided a way for it to return that information, we could shave off some cycles. The problem is, how do we do

Re: [Python-Dev] Python 3.4 and Windows XP: just 45 days until EOL

2013-07-12 Thread Glenn Linderman
On 7/12/2013 8:50 AM, Guido van Rossum wrote: You underestimate the reach of XP. For older or underpowered hardware outside the developed world it is still the de facto choice. And it definitely is the best version of Windows ever. None of the Win98 crap and none of the Vista junk. Telling

Re: [Python-Dev] PEP 409 and the stdlib

2013-05-28 Thread Glenn Linderman
On 5/28/2013 6:02 AM, Serhiy Storchaka wrote: 20.05.13 18:46, Antoine Pitrou написав(ла): I think it is a legitimate case where to silence the original exception. However, the binascii.Error would be more informative if it said *which* non-base32 digit was encountered. Please open a new issue

Re: [Python-Dev] PEP 443 - Single-dispatch generic functions

2013-05-23 Thread Glenn Linderman
On 5/23/2013 12:14 AM, Antoine Pitrou wrote: On Thu, 23 May 2013 02:33:57 -0400 Devin Jeanpierrejeanpierr...@gmail.com wrote: On Thu, May 23, 2013 at 2:04 AM, Antoine Pitrousolip...@pitrou.net wrote: On Thu, 23 May 2013 12:12:26 +1000 Nick Coghlanncogh...@gmail.com wrote: The binary

Re: [Python-Dev] PEP 443 - Single-dispatch generic functions

2013-05-22 Thread Glenn Linderman
On 5/22/2013 3:33 PM, Łukasz Langa wrote: 2. does not have a standard way for methods to be added to existing generic functions (i.e., some are added using registration functions, others require defining ``__special__`` methods, possibly by monkeypatching). I assume you are talking

Re: [Python-Dev] PEP 443 - Single-dispatch generic functions

2013-05-22 Thread Glenn Linderman
On 5/22/2013 5:55 PM, Guido van Rossum wrote: On Wed, May 22, 2013 at 5:14 PM, Glenn Linderman v+pyt...@g.nevcal.com wrote: Yet about half of the operator overloads would be incomplete if there were not corresponding __r*__ methods (__radd__, __rsub__, etc.) because the second parameter

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-21 Thread Glenn Linderman
On 5/14/2013 7:16 AM, Ethan Furman wrote: Thank you for being persistent. You are correct, the value should be an IntET (at least, with a custom __new__ ;). You know, when you look at something you wrote the night before, and have no idea what you were trying to say, you know you were tired.

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-21 Thread Glenn Linderman
On 5/20/2013 11:44 PM, Glenn Linderman wrote: On 5/14/2013 7:16 AM, Ethan Furman wrote: Thank you for being persistent. You are correct, the value should be an IntET (at least, with a custom __new__ ;). You know, when you look at something you wrote the night before, and have no idea what

Re: [Python-Dev] Purpose of Doctests [Was: Best practices for Enum]

2013-05-20 Thread Glenn Linderman
On 5/19/2013 9:08 PM, Ethan Furman wrote: On 05/19/2013 05:24 PM, Nick Coghlan wrote: This is the point I was trying to make: once you use IntEnum (as you would in any case where you need bitwise operators), Enum gets out of the way for everything other than __str__, __repr__, and one other

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-13 Thread Glenn Linderman
On 5/13/2013 7:36 PM, Ethan Furman wrote: On 05/10/2013 10:15 PM, Glenn Linderman wrote: So it is quite possible to marry the two, as Ethan helped me figure out using an earlier NamedInt class: class NIE( IntET, Enum ): x = ('NIE.x', 1) y = ('NIE.y', 2) z = ('NIE.z', 4

[Python-Dev] PEP 435 doesn't help with bitfields [Was: Re: PEP 435 - ref impl disc 2]

2013-05-13 Thread Glenn Linderman
On 5/13/2013 7:36 PM, Ethan Furman wrote: 2) Is something like demo2 interesting to anyone but me? Of course, I think it would be great for reporting flag values using names rather than a number representing combined bit fields. No idea. ;) There's been some talk of Enum-ing constants in

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-11 Thread Glenn Linderman
On 5/10/2013 11:02 PM, Ethan Furman wrote: On 05/10/2013 10:15 PM, Glenn Linderman wrote: But the last few lines of demo1 demonstrate that NIE doesn't like, somehow, remember that its values, deep down under the covers, are really int. And doesn't even like them when they are wrapped

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-11 Thread Glenn Linderman
On 5/11/2013 12:11 AM, Glenn Linderman wrote: * I'm playing with adding another keyword parameter to Enum, but it is presently giving me an error about unknown keyword parameter passed to __prepare__ even though I added **kwds to the list of its parameters. I'll learn something by doing

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-11 Thread Glenn Linderman
On 5/11/2013 12:11 AM, Glenn Linderman wrote: Oh, newest code posted. That'll give me some practice pulling from your repository into mine :) Well, I had to bring your changes to my local repository, and then push them up to my bitbucket repo... not sure if there is a way to merge from

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-10 Thread Glenn Linderman
So, thanks everyone for helping me understand the metaclass issues, and helping fix my code and the reference implementation, so that I got a working workaround for enumerations. Twiddling some more newly using hg and bitbucket... learned a lot today... at

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-06 Thread Glenn Linderman
On 5/6/2013 6:26 PM, Ethan Furman wrote: On 05/05/2013 01:01 AM, Glenn Linderman wrote: The bigger problem is that the arithmetic on enumeration items, which seems like it should be inherited from NamedInt (and seems to be, because the third value from each print is a NamedInt), doesn't pick

Re: [Python-Dev] PEP 435: initial values must be specified? Yes

2013-05-06 Thread Glenn Linderman
On 5/6/2013 7:58 PM, Tim Delaney wrote: On 7 May 2013 12:29, Ethan Furman et...@stoneleaf.us mailto:et...@stoneleaf.us wrote: On 05/05/2013 02:55 PM, Tim Delaney wrote: So long as I can get one of the requirements documented to implement an auto-number syntax I'll be

[Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
So I have a class based on Nick's Named Values, that has been extended to propagate names into expressions, so that if you have named values 'x' and 'y', when you x + y, the result is a named value whose name is '(x + y)'. Seems pretty awkward to integrate this with Enum. Maybe I'm missing

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/4/2013 11:31 PM, Glenn Linderman wrote: So I have a class based on Nick's Named Values, that has been extended to propagate names into expressions, so that if you have named values 'x' and 'y', when you x + y, the result is a named value whose name is '(x + y)'. Seems pretty awkward

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/4/2013 11:46 PM, Glenn Linderman wrote: Somehow, the overloading is not finding the __add__ operator in the NamedInt class, when the NamedInt's are wrapped in enumerations. And I guess I figured it out... NamedInt needs to test issubclass( type( self ), NamedInt ) rather than

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/5/2013 12:10 AM, Glenn Linderman wrote: On 5/4/2013 11:46 PM, Glenn Linderman wrote: Somehow, the overloading is not finding the __add__ operator in the NamedInt class, when the NamedInt's are wrapped in enumerations. And I guess I figured it out... NamedInt needs to test issubclass

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/5/2013 12:21 AM, Ethan Furman wrote: On 05/04/2013 11:31 PM, Glenn Linderman wrote: x = NamedInt('the-x', 1 ) y = NamedInt('the-y', 2 ) # demonstrate that NamedInt propagates the names into an expression syntax print( repr( x ), repr( y ), repr( x+y )) from ref435 import Enum

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/5/2013 6:07 AM, Ethan Furman wrote: class NEI( NamedInt, Enum ): x = NamedInt('the-x', 1 ) y = NamedInt('the-y', 2 ) @property def __name__(self): return self.value.__name__ This cured it, thank you. But I really still don't understand why the numbers showed up

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/5/2013 7:14 PM, Nick Coghlan wrote: I think there comes a point where subclass the metaclass is the right answer to how do I do X with this type?. I believe making two different kinds of value labelling mechanisms play nice is such a case :) Could be. Could be that sufficient operators

Re: [Python-Dev] PEP 435 - ref impl disc 2

2013-05-05 Thread Glenn Linderman
On 5/5/2013 9:51 PM, Nick Coghlan wrote: On Mon, May 6, 2013 at 12:46 PM, Glenn Linderman v+pyt...@g.nevcal.com wrote: Sadly, once the Enums are defined, there is to be no way to subclass them to add functionality, like producing a NamedInt result from operations on them. That rule is enforced

Re: [Python-Dev] PEP 4XX: pyzaa Improving Python ZIP Application Support

2013-05-03 Thread Glenn Linderman
On 5/3/2013 6:41 PM, Steven D'Aprano wrote: Many official Microsoft file extensions are four or more letters, e.g. docx. I don't see any value in making long-lasting decisions on file extensions based on (transient?) bugs that aren't our responsibility. +1

Re: [Python-Dev] PEP-435 reference implementation

2013-05-01 Thread Glenn Linderman
On 4/30/2013 9:19 PM, Ethan Furman wrote: Latest code available at https://bitbucket.org/stoneleaf/aenum. -- class Color(Enum): ... red = 1 ... green = 2 ... blue = 3 Enum items are virtual attributes looked by EnumType's __getattr__. The win here is that --

Re: [Python-Dev] enum discussion: can someone please summarize open issues?

2013-05-01 Thread Glenn Linderman
On 4/30/2013 11:08 PM, Barry Warsaw wrote: On Apr 28, 2013, at 07:46 PM, Ethan Furman wrote: and similarly, Enum behavior /should be/ (in my opinion ;) Season.AUTUMN is Season('AUTUMN') is Season(3) I think you'll have a problem with this. flufl.enum did this, but it has an inherent

Re: [Python-Dev] PEP-435 reference implementation

2013-04-30 Thread Glenn Linderman
On 4/30/2013 1:12 PM, Ethan Furman wrote: Greetings, Eli asked me to put the reference implementation here for review. It is available at https://bitbucket.org/stoneleaf/aenum in ref435.py and test_ref435.py Thanks for the code reference. Tests ran fine here on Python 3.3 If I alter

Re: [Python-Dev] PEP-435 reference implementation

2013-04-30 Thread Glenn Linderman
On 4/30/2013 4:49 PM, Ethan Furman wrote: On 04/30/2013 03:34 PM, Ethan Furman wrote: On 04/30/2013 03:24 PM, Glenn Linderman wrote: On 4/30/2013 1:12 PM, Ethan Furman wrote: Greetings, Eli asked me to put the reference implementation here for review. It is available at https

Re: [Python-Dev] Enumeration items: `type(EnumClass.item) is EnumClass` ?

2013-04-29 Thread Glenn Linderman
On 4/29/2013 10:01 AM, Guido van Rossum wrote: On Mon, Apr 29, 2013 at 9:12 AM, Ethan Furman et...@stoneleaf.us wrote: On 04/29/2013 08:39 AM, Guido van Rossum wrote: Indeed, the type(Color.red) is Color claim was meant for the situation where red is defined directly in Color, and I used

Re: [Python-Dev] enum discussion: can someone please summarize open issues?

2013-04-28 Thread Glenn Linderman
On 4/28/2013 4:37 PM, Steven D'Aprano wrote: I have also suggested that that the enum package provide a decorator which can be used to explicitly flag values to *not* be turned into enum values. See here: http://mail.python.org/pipermail/python-dev/2013-April/125641.html Even if the Enum class

Re: [Python-Dev] enum discussion: can someone please summarize open issues?

2013-04-28 Thread Glenn Linderman
On 4/28/2013 9:09 PM, Guido van Rossum wrote: (2a. We could also allow Color('red') is Color.red, but that could be confusing, and we can already do that with getattr(Color, 'red'), and bool('False') doesn't return False anyway, so let's not do that.) Glad you made this pronouncement in this

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-26 Thread Glenn Linderman
On 4/25/2013 9:19 PM, Guido van Rossum wrote: On Thu, Apr 25, 2013 at 8:39 PM, Glenn Linderman v+pyt...@g.nevcal.com wrote: an enumeration of objects whose class defines __call__ would not be so weird. Seriously? You'd complexificate the basic usage in order to cater for such an esoteric use

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-26 Thread Glenn Linderman
On 4/26/2013 6:22 PM, Greg Ewing wrote: Guido van Rossum wrote: If we had access to the syntax used for the definition, this would be simple: assignments define items, def statements define methods. But at run time we only see the final object resulting from the definition, Another way we

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-25 Thread Glenn Linderman
On 4/25/2013 3:37 PM, Guido van Rossum wrote: On Thu, Apr 25, 2013 at 3:29 PM, Barry Warsawba...@python.org wrote: On Apr 25, 2013, at 03:19 PM, Guido van Rossum wrote: I suppose you were going to propose to use isinstance() overloading, but I honestly think that Color.red.__class__ should be

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-25 Thread Glenn Linderman
On 4/25/2013 3:23 PM, Barry Warsaw wrote: My point is, days of the week has a natural ordering, so why wouldn't you use IntEnum for that? Problem solved. While the ordering is natural, some implementations start from 0, some start from 1, and on the naming side, some start from Sunday, and

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-25 Thread Glenn Linderman
On 4/25/2013 4:53 PM, Ethan Furman wrote: On 04/25/2013 04:26 PM, Glenn Linderman wrote: My question is, once an enumeration is defined, is there a way, short of element-by-element assignment, to import the individual enumeration instances into the current namespace, so that I can say red

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-25 Thread Glenn Linderman
On 4/25/2013 7:25 PM, Ethan Furman wrote: On 04/25/2013 07:09 PM, Glenn Linderman wrote: On 4/25/2013 4:53 PM, Ethan Furman wrote: On 04/25/2013 04:26 PM, Glenn Linderman wrote: My question is, once an enumeration is defined, is there a way, short of element-by-element assignment, to import

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-25 Thread Glenn Linderman
On 4/25/2013 8:22 PM, Greg wrote: On 26/04/2013 3:12 p.m., Glenn Linderman wrote: On 4/25/2013 7:49 PM, Nick Coghlan wrote: You couldn't create an enum of callables, but that would be a seriously weird thing to do anyway But aren't all classes callable? An enum of classes would

Re: [Python-Dev] Why can't I encode/decode base64 without importing a module?

2013-04-24 Thread Glenn Linderman
On 4/24/2013 1:22 AM, M.-A. Lemburg wrote: On 23.04.2013 19:24, Guido van Rossum wrote: On Tue, Apr 23, 2013 at 9:04 AM, M.-A. Lemburg m...@egenix.com wrote: On 23.04.2013 17:47, Guido van Rossum wrote: On Tue, Apr 23, 2013 at 8:22 AM, M.-A. Lemburg m...@egenix.com wrote: Just as reminder:

Re: [Python-Dev] Deciding against the CLA

2013-04-15 Thread Glenn Linderman
On 4/15/2013 12:15 AM, Ben Finney wrote: Steven D'Aprano st...@pearwood.info writes: On 13/04/13 20:30, Ben Finney wrote: Stephen J. Turnbull step...@xemacs.org writes: A failure to sign the CLA is already a decision not to contribute to the distribution As someone who cannot in good faith

Re: [Python-Dev] Sharing docstrings between the Python and C implementations of a module

2013-04-15 Thread Glenn Linderman
On 4/15/2013 4:21 PM, Larry Hastings wrote: On 04/15/2013 09:31 AM, Eli Bendersky wrote: Would it make sense to think about adding this in the scope of the argument clinic work, or is it too unrelated? This seems like a commonly needed thing for large parts of the stdlib (where the C

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread Glenn Linderman
On 4/12/2013 3:59 PM, Guido van Rossum wrote: class Insect(Enum): wasp = 1 bee = 1 ant = 2 We'd have Insect.wasp == Insect.bee Insect.ant but Insect.wasp is not Insect.bee. can't define two names in the same enum to have the same value, per the PEP.

Re: [Python-Dev] PEP 4XX: pyzaa Improving Python ZIP Application Support

2013-04-01 Thread Glenn Linderman
On 4/1/2013 5:47 PM, Daniel Holth wrote: users expect .py to be opened with a text editor. This user expects .py to be executed as an executable script, and thinks that is the default after an installation of Python on Windows. Windows has a separate option, Edit, to use to edit things.

Re: [Python-Dev] IDLE in the stdlib

2013-03-20 Thread Glenn Linderman
On 3/20/2013 5:15 PM, Terry Reedy wrote: Broken (and quirky): it has an absurdly limited output buffer (under a thousand lines) People keep claiming that Windows CMD has a limited output buffer. It is configurable, at least to lines, which is where I have mine set. That is far too much

Re: [Python-Dev] Status of XML fixes

2013-03-17 Thread Glenn Linderman
On 3/17/2013 8:48 PM, Barry Warsaw wrote: On Mar 17, 2013, at 05:37 PM, Christian Heimes wrote: Any attempt to fix the XML issues *will* change the behavior of the library and result into an incompatibility with older releases. Benjamin doesn't want to change the behavior of our XML libraries.

Re: [Python-Dev] Fwd: PEP 426 is now the draft spec fordistribution metadata 2.0

2013-02-19 Thread Glenn Linderman
On 2/19/2013 11:06 AM, Daniel Holth wrote: This feature does something to remedy the setuptools chicken/egg problem. We have eliminated the egg ;-) This is the most artfully crafted comment I've seen on topic on this list for some months! Thanks!

Re: [Python-Dev] PEP 433: Add cloexec argument to functions creating file descriptors

2013-01-13 Thread Glenn Linderman
On 1/13/2013 5:49 AM, Nick Coghlan wrote: I agree it makes it obvious what the right default behaviour should be: flag every FD as sensitive by default, and pass an argument to say sensitive=False when you want to disable Python's automatic protections. sensitive is a bad name... because the

Re: [Python-Dev] Posting frequent spurious changes in bugtracker

2013-01-03 Thread Glenn Linderman
On 1/3/2013 12:13 PM, Brett Cannon wrote: It is a form so technically nothing is being done incorrectly in changing values based on what you submit, whether you view them stale or not. Well, it sounds like a pretty shaky technology foundation, if simultaneous updates of a shared data

Re: [Python-Dev] Posting frequent spurious changes in bugtracker

2013-01-03 Thread Glenn Linderman
On 1/3/2013 2:43 PM, Brett Cannon wrote: On Thu, Jan 3, 2013 at 4:06 PM, Glenn Linderman v+pyt...@g.nevcal.com mailto:v+pyt...@g.nevcal.com wrote: On 1/3/2013 12:13 PM, Brett Cannon wrote: It is a form so technically nothing is being done incorrectly in changing values based

Re: [Python-Dev] Draft PEP for time zone support.

2012-12-13 Thread Glenn Linderman
On 12/12/2012 11:32 PM, Janzert wrote: On 12/13/2012 1:39 AM, Glenn Linderman wrote: On 12/12/2012 6:10 PM, Janzert wrote: On 12/12/2012 8:43 PM, Glenn Linderman wrote: On 12/12/2012 5:36 PM, Brian Curtin wrote: C:\ProgramData\Python ^ That. Is not the path that the link

Re: [Python-Dev] Draft PEP for time zone support.

2012-12-12 Thread Glenn Linderman
On 12/12/2012 5:36 PM, Brian Curtin wrote: C:\ProgramData\Python ^ That. Is not the path that the link below is talking about, though. Making a new top-level directory without asking is obnoxious. See

Re: [Python-Dev] Draft PEP for time zone support.

2012-12-12 Thread Glenn Linderman
On 12/12/2012 6:10 PM, Janzert wrote: On 12/12/2012 8:43 PM, Glenn Linderman wrote: On 12/12/2012 5:36 PM, Brian Curtin wrote: C:\ProgramData\Python ^ That. Is not the path that the link below is talking about, though. It actually does; it is rather confusing though

Re: [Python-Dev] Proposing Argument Clinic, a new way of specifying arguments to builtins for CPython

2012-12-03 Thread Glenn Linderman
On 12/3/2012 3:42 PM, Gregory P. Smith wrote: All the core devs I've asked said given all that, I'd prefer the hairy preprocessor macros. But by the end of the conversation they'd changed their minds to prefer the custom DSL. Maybe I'll make a believer out of you too--read on!

Re: [Python-Dev] Accept just PEP-0426

2012-11-20 Thread Glenn Linderman
On 11/20/2012 12:46 PM, PJ Eby wrote: On Tue, Nov 20, 2012 at 11:49 AM, Vinay Sajip vinay_sa...@yahoo.co.uk mailto:vinay_sa...@yahoo.co.uk wrote: Also: what happens when a requirement is for setuptools (= X.Y), but the distribute fork hasn't kept pace, and so only supports

Re: [Python-Dev] Accept just PEP-0426

2012-11-20 Thread Glenn Linderman
On 11/20/2012 1:48 PM, PJ Eby wrote: (We've been over this before, the last time this discussion came up on the Distutils-SIG for a previous Metadata PEP a year or two back, but here goes) Thanks. I wasn't over there. Makes it clear that clarifying PEPs to reflect discussions is a good

Re: [Python-Dev] Improve error message UnboundLocalError: local variable referenced before assignment

2012-11-12 Thread Glenn Linderman
On 11/12/2012 7:30 AM, Jan Matějek wrote: I believe the human problem here is that the one tends to gloss over local variable VARNAME, because it describes VARNAME and you already think you know what that is, so you don't stop to think about it. The following would be better in this regard,

Re: [Python-Dev] [RELEASED] Python 3.3.0

2012-09-29 Thread Glenn Linderman
On Sat, Sep 29, 2012 at 5:18 AM, Georg Brandl ge...@python.org wrote: In total, almost 500 API items are new or improved in Python 3.3. For a more extensive list of changes in 3.3.0, see http://docs.python.org/3.3/whatsnew/3.3.html Reading this to see if I missed anything while

Re: [Python-Dev] Should urlencode() sort the query parameters (if they come from a dict)?

2012-08-18 Thread Glenn Linderman
On 8/18/2012 11:47 AM, MRAB wrote: I vote -0. The issue can also be addressed with a small and simple helper function that wraps urlparse and compares the query parameter. Or you cann urlencode() with `sorted(qs.items)` instead of `qs` in the application. Hm. That's actually a good point.

Re: [Python-Dev] PEP 423 : naming conventions and recipes related to packaging

2012-06-28 Thread Glenn Linderman
On 6/28/2012 9:36 AM, Ethan Furman wrote: When I search PyPI I ignore anything with djange, zope, etc., as I have zero interest in pulling in a bunch of unrelated packages that I don't need. If some of these pieces are truly stand-alone it would be nice if they were presented that way. +1

Re: [Python-Dev] Optimize Unicode strings in Python 3.3

2012-05-29 Thread Glenn Linderman
On 5/29/2012 3:51 PM, Nick Coghlan wrote: On Wed, May 30, 2012 at 8:44 AM, Victor Stinner victor.stin...@gmail.com wrote: I also compared str%args and str.format() with Python 2.7 (byte strings), 3.2 (UTF-16 or UCS-4) and 3.3 (PEP 393): Python 3.3 is as fast as Python 2.7 and sometimes faster!

Re: [Python-Dev] sys.implementation

2012-05-12 Thread Glenn Linderman
On 5/12/2012 10:50 AM, Eric Snow wrote: given a normal (dict-based) object you can use vars() to turn it into a dict: data = SomeClass(a=1, b=2, c=3) ns = vars(data) ns['a'] 1 ns['b'] 2 ns['c'] 3 I'll grant that it doesn't work for some objects (like named tuples), Why not?

Re: [Python-Dev] PEP 405 (pyvenv) and system Python upgrades

2012-05-05 Thread Glenn Linderman
On 5/4/2012 9:39 PM, Terry Reedy wrote: The gist of my response is that the venv 'tail' should way the python 'dog' as little as possbile. Yes, that was exactly my thought too. But I'm not sure the technology permits, with Windows not having exec. On the other hand, one might speculate

Re: [Python-Dev] PEP 405 (pyvenv) and system Python upgrades

2012-05-04 Thread Glenn Linderman
On 5/4/2012 8:48 PM, Terry Reedy wrote: CPython is developed, tested, packaged, distributed, and installed as one unit. It is intended to be run as one package. If something caches a copy of python.exe, it seems to me that it should check and update as needed. Could venv check the file date of

Re: [Python-Dev] CRLF line endings

2012-05-03 Thread Glenn Linderman
On 5/3/2012 2:00 PM, mar...@v.loewis.de wrote: I think that .bat files strictly *have* to have CRLF line endings. Nope. Both .bat and .cmd work fine with LF only in Win7 (and IIRC, in XP as well, but I just tested Win7) ___ Python-Dev mailing list

Re: [Python-Dev] sys.implementation

2012-04-27 Thread Glenn Linderman
On 4/27/2012 12:34 AM, Eric Snow wrote: On Thu, Apr 26, 2012 at 8:31 AM, Barry Warsawba...@python.org wrote: It's somewhat of a corner case, but I think a PEP couldn't hurt. The rationale section would be useful, at least.

Re: [Python-Dev] sys.implementation

2012-04-27 Thread Glenn Linderman
On 4/27/2012 11:49 AM, R. David Murray wrote: On Fri, 27 Apr 2012 10:40:43 -0700, Glenn Lindermanv+pyt...@g.nevcal.com wrote: On 4/27/2012 12:34 AM, Eric Snow wrote: On Thu, Apr 26, 2012 at 8:31 AM, Barry Warsawba...@python.org wrote: It's somewhat of a corner case, but I think a PEP

Re: [Python-Dev] package imports, sys.path and os.chdir()

2012-04-27 Thread Glenn Linderman
On 4/27/2012 1:00 PM, Brett Cannon wrote: I'm personally in favour of changing the insertion of '' to sys.path to inserting the cwd when the interpreter is launched. +1 ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] path joining on Windows and imp.cache_from_source()

2012-04-21 Thread Glenn Linderman
On 4/21/2012 8:53 PM, Brett Cannon wrote: imp.cache_from_source() (and thus also imp.source_from_cache()) has special semantics compared to how os.path.join() works. For instance, if you look at test_imp you will notice it tries to use the same path separator as is the farthest right in the

Re: [Python-Dev] an alternative to embedding policy in PEP 418

2012-04-06 Thread Glenn Linderman
On 4/6/2012 4:11 PM, Cameron Simpson wrote: Another alternative is the public lists-of-clocks. After watching this thread with amusement and frustration, amusement because it is so big, and so many people have so many different opinions, frustration, because it seems that few of the clocks

Re: [Python-Dev] an alternative to embedding policy in PEP 418

2012-04-02 Thread Glenn Linderman
On 4/2/2012 4:37 AM, Victor Stinner wrote: The API looks much more complex than the API proposed in PEP 418 just to get the time. You have to call a function to get a function, and then call the function, instead of just calling a function directly. Instead of returning an object with a now()

Re: [Python-Dev] an alternative to embedding policy in PEP 418

2012-04-02 Thread Glenn Linderman
On 4/2/2012 2:40 PM, Nick Coghlan wrote: On Tue, Apr 3, 2012 at 3:44 AM, Glenn Lindermanv+pyt...@g.nevcal.com wrote: One thing I don't like about the idea of fallback being buried under some API is that the efficiency of that API on each call must be less than the efficiency of directly

Re: [Python-Dev] Integrating the PEP 397 launcher

2012-03-29 Thread Glenn Linderman
On 3/29/2012 3:50 PM, Brian Curtin wrote: On Thu, Mar 29, 2012 at 17:45, Benjamin Petersonbenja...@python.org wrote: 2012/3/29 Brian Curtinbr...@python.org: After talking with Martin and several others during the language summit and elsewhere around PyCon, PEP 397 should be accepted. I

Re: [Python-Dev] Playing with a new theme for the docs

2012-03-26 Thread Glenn Linderman
On 3/26/2012 10:19 AM, R. David Murray wrote: Like Philip, I have*one* window. My window manager (ratpoison) is more like 'screen' for X: you*can* split the window up, but it is*much* more useful to have only one window visible at a time, most of the time. I'm amazed at the number of

Re: [Python-Dev] Playing with a new theme for the docs

2012-03-26 Thread Glenn Linderman
On 3/26/2012 10:58 AM, Ethan Furman wrote: Glenn Linderman wrote: On 3/26/2012 10:19 AM, R. David Murray wrote: Like Philip, I have *one* window. My window manager (ratpoison) is more like 'screen' for X: you *can* split the window up, but it is *much* more useful to have only one window

Re: [Python-Dev] Python install layout and the PATH on win32 (Rationale part 1: Regularizing the layout)

2012-03-26 Thread Glenn Linderman
On 3/26/2012 12:27 PM, PJ Eby wrote: On Mon, Mar 26, 2012 at 12:58 PM, Carl Meyer c...@oddbird.net mailto:c...@oddbird.net wrote: No disagreement here. I think virtualenv's sweet spot is as a convenient tool for development environments (used in virtualenvwrapper fashion, where

Re: [Python-Dev] Python install layout and the PATH on win32 (Rationale part 1: Regularizing the layout)

2012-03-26 Thread Glenn Linderman
On 3/26/2012 1:21 PM, Glenn Linderman wrote: Hmm. And here's something else that might be missing: integration of the launcher with .py files that are actually ZIP archives... where does it find the #! line? (probably it can't, currently -- I couldn't figure out how to make it do

Re: [Python-Dev] Playing with a new theme for the docs, iteration 2

2012-03-25 Thread Glenn Linderman
On 3/24/2012 11:34 PM, Georg Brandl wrote: I've also added a little questionable gimmick to the sidebar (when you collapse it and expand it again, the content is shown at your current scroll location). It would be educational to see how you pulled that trick! I will look if I get time.

Re: [Python-Dev] Playing with a new theme for the docs

2012-03-24 Thread Glenn Linderman
On 3/24/2012 5:41 PM, Ben Finney wrote: It's madness to expect web designers to hobble the flexibility of a web page to cater preferentially for one minority over others. But largely, the 99% that makes the rest of them look bad, do, in fact, do exactly that.

Re: [Python-Dev] Playing with a new theme for the docs

2012-03-22 Thread Glenn Linderman
On 3/22/2012 10:02 AM, Steven D'Aprano wrote: As they say, the 99% who are lousy designers give the rest a bad name. *wink* :) My first impression of this page: http://www.python.org/~gbrandl/build/html/index.html was that the grey side-bar gives the page a somber, perhaps even dreary,

Re: [Python-Dev] Python install layout and the PATH on win32

2012-03-20 Thread Glenn Linderman
On 3/20/2012 11:50 AM, Merlijn van Deen wrote: As this is being considered an 'incompatible change' on the bug tracker item [1] in any case, I'd like to mention that this might also be a convenient moment to re-think the default install location. After all, software is supposed to be installed

Re: [Python-Dev] Python install layout and the PATH on win32

2012-03-20 Thread Glenn Linderman
On 3/20/2012 4:25 PM, Mark Hammond wrote: I think it does. Consider I've installed Python as a system install. Now I want to install some other package - ideally that installer will request elevation - all well and good - the .py files are installed. However, next time I want to run Python,

Re: [Python-Dev] PEP 405 (built-in virtualenv) status

2012-03-19 Thread Glenn Linderman
On 3/19/2012 2:26 AM, Kristján Valur Jónsson wrote: Hi Carl. I'm very interested in this work. At CCP we work heavily with virtual environments. Except that we don't use virtualenv because it is just a pain in the neck. We like to be able to run virtual python environments of various types

Re: [Python-Dev] regarding HTML mail

2012-03-19 Thread Glenn Linderman
On 3/19/2012 11:52 AM, Jesse Noller wrote: I'd like to discuss top-posting. Somewhere else, please. Oh, that was your point :) ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe:

<    1   2   3   4   5   6   7   >