Re: [Python-Dev] Is adding support for os.PathLike an enhancement or bugfix?

2017-05-05 Thread Nick Coghlan
entially even just "str") to instead accepting "os.PathLike" doesn't count as fixing a genuine bug in the earlier releases - it just means we made the API more permissive in a maintenance release. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-05-05 Thread Nick Coghlan
nouncement yet. Antoine's request was for me to update PEP *538* to eliminate the "this will need to change if PEP 540 is accepted" aspects, and I think your suggestion to make the "C.UTF-8 -> surrogateescape on standard streams by default" behaviour independent of the

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-05-05 Thread Nick Coghlan
hat it isn't unusual for related PEPs to have non-sequential PEP numbers) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/pyth

Re: [Python-Dev] "make touch" replaced with "make regen-all"

2017-05-05 Thread Nick Coghlan
On 5 May 2017 at 16:01, Victor Stinner <victor.stin...@gmail.com> wrote: > Le 5 mai 2017 6:31 AM, "Nick Coghlan" <ncogh...@gmail.com> a écrit : > > The note just needs to say that folks that care about doing "complete" > builds need to adjust their co

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-05-04 Thread Nick Coghlan
nguishable at runtime (aside from the stderr warning in the latter case). It will then be up to Victor to state in PEP 540 how locale coercion will interact with Python UTF-8 mode (with my recommendation being the one currently in PEP 538: it should implicitly set the environment variable, so the

Re: [Python-Dev] Is adding support for os.PathLike an enhancement or bugfix?

2017-05-04 Thread Nick Coghlan
ike shutil that I put into the same category as third party libraries for now: Python 3.6 users shouldn't expect implicit use of the fspath protocol to be universal yet, so they may still need some explicit calls to os.fspath() in their own code to get different APIs to work well together. Cheers, Nick

Re: [Python-Dev] "make touch" replaced with "make regen-all"

2017-05-04 Thread Nick Coghlan
s should also make bootstrapping easier, since bootstrap builds can skip the "make regen-all" step and instead rely on the checked in pre-generated files. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] Is adding support for os.PathLike an enhancement or bugfix?

2017-05-04 Thread Nick Coghlan
nt that we could have deferred to the next feature release. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-de

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-05-04 Thread Nick Coghlan
e. That makes me more confident in making that change, as it would be rather counterproductive if our changes gave base image developers an incentive *not* to set C.UTF-8 as their default locale. > Anyway, I think https://bugs.python.org/issue15216 should be fixed in > Python 3

Re: [Python-Dev] __getattribute__'s error is not available in __getattr__

2017-05-01 Thread Nick Coghlan
's a docs limitation which should be addressed. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.pyth

Re: [Python-Dev] Guarantee the success of some object creation C API functions

2017-05-01 Thread Nick Coghlan
pointer to a pre-allocated instance" cases can then be documented on the affected public API functions. So +1 from me for making pre-allocation a CPython C API guarantee, -1 for making it a language level singleton commitment. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisban

Re: [Python-Dev] Escaping docs markup in NEWS entries?

2017-05-01 Thread Nick Coghlan
On 1 May 2017 at 17:13, Martin Panter <vadmium...@gmail.com> wrote: > On 1 May 2017 at 06:37, Nick Coghlan <ncogh...@gmail.com> wrote: >> Hi folks, >> >> I'm trying to write a NEWS entry that explains that the >> ":func:`bytes`" cross-references

[Python-Dev] Escaping docs markup in NEWS entries?

2017-05-01 Thread Nick Coghlan
entries. Use ``\:ref\:\`func-bytes\``` and ``\:ref\:\`func-bytes\``` to reference the latter. My fallback plan is to just include the unescaped markup in the NEWS entry (rather than trying to make it readable even in rendered form), but I figured I'd ask for advice here first. Cheers, Nick.

Re: [Python-Dev] Request review of cProfile/profile series issue

2017-04-23 Thread Nick Coghlan
en reviewing them so far, and they look sensible to me, but I don't personally know the profile code base at all, so there's a strong chance I'll miss subtle details. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] API for bugs.python.org or some statistic about lib/module merge rate?

2017-04-23 Thread Nick Coghlan
e upstream Roundup project is also interested in offering that capability by default: http://issues.roundup-tracker.org/issue2550734 -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https

[Python-Dev] Proposed BDFL Delegate update for PEPs 538 & 540 (assuming UTF-8 for *nix system boundaries)

2017-04-23 Thread Nick Coghlan
update the headers on both PEPs accordingly. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https

Re: [Python-Dev] why _PyGen_Finalize(gen) propagates close() to _PyGen_yf() ?

2017-04-02 Thread Nick Coghlan
What are they hiding?"), but that's OK - different services are provided for different audiences. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org

Re: [Python-Dev] What version is an extension module binary compatible with

2017-03-29 Thread Nick Coghlan
tenance releases, and add some automated testing to avoid accidental changes and oversights (similar to the pending test to ensure magic number stability for cached bytecode files) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia __

Re: [Python-Dev] Exact date of Python 2 EOL?

2017-03-24 Thread Nick Coghlan
ish before 2020, with Canonical being a "maybe" on 2023 (depending on what happens in Ubuntu 18.04). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.

Re: [Python-Dev] Exact date of Python 2 EOL?

2017-03-24 Thread Nick Coghlan
release-end-of-life > As far as I'm aware, Samba is the main remaining challenge for Fedora Server on that front, but at least all of the libraries it depends on have received the necessary updates to make them Python 2/3 compatible: http://fedora.portingdb.xyz/pkg/samba/ Cheers, Nic

Re: [Python-Dev] Set program name through exec -a

2017-03-19 Thread Nick Coghlan
ibute like "sys._raw_argv" to get the full details of how Python was invoked. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailma

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-15 Thread Nick Coghlan
On 16 March 2017 at 00:30, Barry Warsaw <ba...@python.org> wrote: > On Mar 15, 2017, at 12:29 PM, Nick Coghlan wrote: > > >From a mainstream Linux point of view, it's not common - on > systemd-managed > >systems, for example, the only way to get the C locale these d

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-14 Thread Nick Coghlan
alent to sorting the decoded text by the Unicode code point values, which means that "LC_COLLATE=C" sorting by byte value, and "LC_COLLATE=C.UTF-8" sorting by "Unicode code point value" give the same results. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Bris

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-14 Thread Nick Coghlan
On 15 March 2017 at 00:17, Nick Coghlan <ncogh...@gmail.com> wrote: > On 13 March 2017 at 23:31, Random832 <random...@fastmail.com> wrote: > >> On Mon, Mar 13, 2017, at 04:37, INADA Naoki wrote: >> > But locale coercing works nice on platforms like android. >

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-14 Thread Nick Coghlan
on Android also show up when you do either "LANG=C python2" or "LANG=C python3" on traditional Linux and attempt to *edit* lines containing multi-byte characters), so you really need to know what you're doing in order to operate under those constraints. Chee

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-13 Thread Nick Coghlan
ose with a more conventional use case (i.e. running an up to date \*nix OS using UTF-8 or another universal encoding for both local and remote interfaces). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-12 Thread Nick Coghlan
On 12 March 2017 at 22:57, Nick Coghlan <ncogh...@gmail.com> wrote: > However, I'm also open to having [PYTHONCOERCECLOCALE=0] also disable the > runtime warning from the shared library. > Considering this a little further, I think this is going to be necessary in order to

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-12 Thread Nick Coghlan
none of the above seems possible to correctly > implement in Python. > The first case remains unchanged, the other two will need to use Python 2.7 or Tauthon. I'm fine with that. > * Nick Coghlan <ncogh...@gmail.com>, 2017-03-05, 17:50: > > While this PEP ensures that develo

Re: [Python-Dev] Can I revoke PEP 103 (info about git)?

2017-03-09 Thread Nick Coghlan
an informational PEP, why withdraw it? The PEP Index organises itself by status, so withdrawing it moves it down into the historical PEPs section, and out of the active section. (We're probably due for a PEP "spring clean" in general, but doing that is about as exciting as actual spri

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-09 Thread Nick Coghlan
On 9 March 2017 at 07:58, Guido van Rossum <gu...@python.org> wrote: > On Wed, Mar 8, 2017 at 4:35 AM, Nick Coghlan <ncogh...@gmail.com> wrote: > >> >> On 5 March 2017 at 17:50, Nick Coghlan <ncogh...@gmail.com> wrote: >> >>> Late last ye

Re: [Python-Dev] Can I revoke PEP 103 (info about git)?

2017-03-08 Thread Nick Coghlan
te to Withdrawn, so it doesn't actually break any links. It's helpful to add a short "PEP Withdrawal" section to say why it's withdrawn though, and you'd be able to link to the wiki.python.org page from there. Cheers, Nick. -- Nick Coghlan | ncog

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-08 Thread Nick Coghlan
On 5 March 2017 at 17:50, Nick Coghlan <ncogh...@gmail.com> wrote: > Hi folks, > > Late last year I started working on a change to the CPython CLI (*not* the > shared library) to get it to coerce the legacy C locale to something based > on UTF-8 when a suitable locale is

Re: [Python-Dev] 3.6.1 release status and plans

2017-03-08 Thread Nick Coghlan
ws is unexpectedly leaving the parent directory of the given directory or archive on sys.path when running directories and zip archives on other platforms). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev maili

Re: [Python-Dev] API design: where to add async variants of existing stdlib APIs?

2017-03-07 Thread Nick Coghlan
work everywhere" approach, where the async protocol methods use "await obj.aclose()" if the latter is defined, and a synchronous "obj.close()" otherwise. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia __

Re: [Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-06 Thread Nick Coghlan
zations. I *think* it will be universally positive (because the status quo really is broken), but it also wouldn't be the first time I've learned something new and confusing about the locale subsystem only after releasing software that relied on an incorrect assumption about it :) Cheers, Nick. -- N

[Python-Dev] PEP 538: Coercing the legacy C locale to a UTF-8 based locale

2017-03-04 Thread Nick Coghlan
you still need to be consistent with the platform settings). Cheers, Nick. == PEP: 538 Title: Coercing the legacy C locale to a UTF-8 based locale Version: $Revision$ Last-Modified: $Date$ Author: Nick Coghlan <ncogh...@gmail.com> Status: Draft Type: Standards Tr

Re: [Python-Dev] Help requested with Python 2.7 performance regression

2017-03-02 Thread Nick Coghlan
sions, but this would be more about using Python's benchmark suite to investigate the performance of *gcc*, since it appears that may be the culprit here. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev ma

Re: [Python-Dev] API design: where to add async variants of existing stdlib APIs?

2017-03-01 Thread Nick Coghlan
cedent for any other modules like itertools - the trade-offs there are going to be different, and there are already third party modules like https://github.com/asyncdef/aitertools that provide equivalent APIs for the asynchronous programming model. Cheers, Nick. -- Nic

[Python-Dev] API design: where to add async variants of existing stdlib APIs?

2017-02-28 Thread Nick Coghlan
r (with a cross-reference from the synchronous contextlib docs), rather than the current approach of adding it directly to contextlib? Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@pyth

Re: [Python-Dev] Translated Python documentation

2017-02-26 Thread Nick Coghlan
readers will have *some* ability to read English, they just prefer to read their native language. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.or

Re: [Python-Dev] attributes of Python code objects

2017-02-26 Thread Nick Coghlan
etails, like the internal structure of co_code and co_lnotab, where they may change arbitrarily between CPython feature releases. The generator and coroutine ABCs were also specifically added so they could be replaced with objects that don't have __code__.co_flags attributes (e.g. by Cython) with

[Python-Dev] Handling PR branches in "make patchcheck"

2017-02-25 Thread Nick Coghlan
n" refers to the upstream repo), but it would be good if folks could try it out with other configurations before we merge it (in particular, it *should* handle the case where the upstream remote is called "upstream", but I don't use that arrangement myself). Cheers, Nick. -

Re: [Python-Dev] Translated Python documentation

2017-02-25 Thread Nick Coghlan
going to be better handled inline (e.g. "On versions older than 3.x, ") rather than by maintaining multiple distinct versions of the document. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Pytho

Re: [Python-Dev] Translated Python documentation

2017-02-24 Thread Nick Coghlan
ntroduction to programming workshop). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.p

Re: [Python-Dev] Translated Python documentation

2017-02-24 Thread Nick Coghlan
d credible potential customers (i.e. folks that have the ability to affect redistributor revenue directly) rather than from redistributor staff or community volunteers (as we're pretty much limited to using risk management and hiring pipeline based lines of argument, rather than being able to push the &qu

Re: [Python-Dev] Translated Python documentation

2017-02-24 Thread Nick Coghlan
. In addition to the case of folks that struggle to read the English documentation at all, I'd assume that there are also folks that would appreciate the chance to check their own understanding against someone else's translation of various topics. Cheers, Nick. -- Nick Coghlan | ncogh

Re: [Python-Dev] PEP 543: A Unified TLS API for Python

2017-02-24 Thread Nick Coghlan
the PEP process, so your planned approach makes a lot of sense to me. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python

Re: [Python-Dev] Report on Python vulnerabilities

2017-02-24 Thread Nick Coghlan
add a "Fixed In" column to the summary table to get a quick overview of which versions were affected. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://ma

Re: [Python-Dev] Translated Python documentation

2017-02-24 Thread Nick Coghlan
Python *before* they learn English (even if learning English remains a pre-requisite for tapping into the full capabilities of both the language and its ecosystem). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev m

Re: [Python-Dev] PEP 543: A Unified TLS API for Python

2017-02-24 Thread Nick Coghlan
ming the latter case, I think it may make sense for Christian to handle the BDFL-Delegate responsibilities as well - I know he's a co-author of the PEP, but I also think he's the most qualified to make the final decision on the suitability of this design. Cheers, Nick. -- Nick Coghlan | ncogh...@

Re: [Python-Dev] re performance

2017-01-31 Thread Nick Coghlan
On 30 January 2017 at 15:26, Barry Warsaw <ba...@python.org> wrote: > On Jan 30, 2017, at 12:38 PM, Nick Coghlan wrote: > >>I think there are 3 main candidates that could fit that bill: >> >>- requests >>- setuptools >>- regex > > Actually, I think

Re: [Python-Dev] Generator objects and list comprehensions?

2017-01-31 Thread Nick Coghlan
rning in 3.7 - Py3k warning in 2.7.x - SyntaxError in 3.8 Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: htt

Re: [Python-Dev] re performance

2017-01-30 Thread Nick Coghlan
On 28 January 2017 at 18:07, Barry Warsaw <ba...@python.org> wrote: > On Jan 28, 2017, at 03:43 PM, Nick Coghlan wrote: > >>I still think it could be a good candidate for a first "bundled" >>module, where we don't migrate it fully into the CPython development &g

Re: [Python-Dev] re performance

2017-01-28 Thread Nick Coghlan
, which are available for a range of Python versions. I still think it could be a good candidate for a first "bundled" module, where we don't migrate it fully into the CPython development process, but *do* officially bless it and provid

Re: [Python-Dev] ctypes, memory mapped files and context manager

2017-01-04 Thread Nick Coghlan
ar as I can tell, wrapt doesn't currently support "closing" a proxy by replacing the reference to the internal object with a reference to None (adding that might be possible, but I don't personally know wrapt well enough to guess the feasibility of doing so). Cheers, Nick. -- Nick

Re: [Python-Dev] --with-fpectl changes the CPython ABI

2017-01-02 Thread Nick Coghlan
houldn't be difficult, and it's a nice courtesy for anyone that *is* somehow currently getting it to work. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python

Re: [Python-Dev] Document C API that is not part of the limited API

2016-12-30 Thread Nick Coghlan
That suggests the tests would need to check the headers with all stable ABI versions from 3.2 up to the current release and ensure they match the current C API documentation) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia __

Re: [Python-Dev] --with-fpectl changes the CPython ABI

2016-12-25 Thread Nick Coghlan
ideas/2012-October/016768.html -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/

Re: [Python-Dev] Constifying C API

2016-12-18 Thread Nick Coghlan
rectly declare the destination storage as a const pointer will still compile against the old API variants that return a mutable pointer, so any problems this finds in third party code are likely to be resolved for older 3.x releases as well. Cheers, Nick. -- Nick C

Re: [Python-Dev] Deprecate `from __future__ import unicode_literals`?

2016-12-17 Thread Nick Coghlan
structure as soon as possible (the fact that Django is structured primarily as an object oriented framework likely helped with that, as it has a lot of control over the data types user applications end up encountering). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Au

Re: [Python-Dev] Someons's put a "Python 2.8" on GitHub

2016-12-12 Thread Nick Coghlan
On 13 December 2016 at 02:12, Chris Angelico <ros...@gmail.com> wrote: > On Tue, Dec 13, 2016 at 12:18 AM, Nick Coghlan <ncogh...@gmail.com> wrote: >> It absolutely *is* relevant, as is how diligent the redistributors are >> in differentiating between the

Re: [Python-Dev] Someons's put a "Python 2.8" on GitHub

2016-12-12 Thread Nick Coghlan
d the PSF Board rather than python-dev), so if you'd like to learn more about trademark law and how it applies to open source projects in general, I'd suggest taking advantage of the extensive material available online rather than posting further here (the history of the Firefox/Iceweasel disagreement betw

Re: [Python-Dev] Someons's put a "Python 2.8" on GitHub

2016-12-11 Thread Nick Coghlan
superset"), which is always OK. In this particular case, there just happened to be an obvious name for the project (courtesy of PEP 404) that was nevertheless problematic on the "potential for confusion" trademark front. Fortunately, there have been a few interesting alternative

Re: [Python-Dev] Someons's put a "Python 2.8" on GitHub

2016-12-10 Thread Nick Coghlan
t its a fork, >>like Stackless. > > Yes, exactly right. It's not sanctioned by the PSF and should not be called > "Python" anything. NorwegianBlue would be thematically appropriate ;) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] Someons's put a "Python 2.8" on GitHub

2016-12-09 Thread Nick Coghlan
rcGIS, Maya, etc) that already build their own Python from source with the same C/C++ compiler that they use to build the rest of the application (so arbitrary Python C extensions aren't supported). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] PyPy progress: list of CPython 3.5 crashers and bugs

2016-12-05 Thread Nick Coghlan
efault/Lib/test/crashers/ (if any of the crashers can't be readily resolved). Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-de

Re: [Python-Dev] Recent changes to PyCodeObject

2016-11-16 Thread Nick Coghlan
d give folks a few weeks to start preparing launch binaries if they want to do so, rather than the single week planned between the rc and the final release. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mai

Re: [Python-Dev] Parsing f-strings from PEP 498 -- Literal String Interpolation

2016-11-05 Thread Nick Coghlan
maybe_pyexpr: (atom | TEXT)+ That isn't quite right, since it doesn't properly account for brace nesting, but it gives the general idea - there's an initial really simple tokenising pass that picks out the potential Python expressions, and then those are run through the AST parser's equivalent of

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-25 Thread Nick Coghlan
On 25 October 2016 at 17:25, Nick Coghlan <ncogh...@gmail.com> wrote: > as well as Yury's new > libuv-based ``uvloop`` asyncio event loop implementation. Oops, I phrased that badly - the default asyncio event loop implementation is still pure Python, but uvloop is a drop-in

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-25 Thread Nick Coghlan
r level buffer manipulation library between now and the Python 3.7 feature freeze in 12+ months, as I think that will have longer term pay-offs well beyond the scope of the original use cases :) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia

Re: [Python-Dev] Is there any remaining reason why weakref callbacks shouldn't be able to access the referenced object?

2016-10-22 Thread Nick Coghlan
On 22 October 2016 at 16:05, Nathaniel Smith <n...@pobox.com> wrote: > On Fri, Oct 21, 2016 at 8:32 PM, Nick Coghlan <ncogh...@gmail.com> wrote: > But PEP 442 already broke all that :-). Now weakref callbacks can > happen before __del__, and they can happen on o

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-22 Thread Nick Coghlan
fically here, as Armin Ronacher recently wrote an excellent post about that in relation to some performance improvement work they were doing at Sentry: https://blog.sentry.io/2016/10/19/fixing-python-performance-with-rust.html -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia __

Re: [Python-Dev] Is there any remaining reason why weakref callbacks shouldn't be able to access the referenced object?

2016-10-21 Thread Nick Coghlan
ng a strong reference means losing the main "reasoning about software" benefit that weakref callbacks offer: they currently can't resurrect the object they relate to (since they never receive a strong reference to it), so it nominally doesn't matter

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-21 Thread Nick Coghlan
?" By contrast, if we instead say "We want Python to natively support efficient. readily discoverable, IO buffer manipulation", then folks can ask "What's preventing us from providing an `iobuffers` module today?" and start working towards that end goal (just as the&

Re: [Python-Dev] [Python-ideas] Show more info when `python -vV`

2016-10-17 Thread Nick Coghlan
start being useful for troubleshooting - the SSL/TLS changes mean that some redistributed versions of Python 2.7 are starting to accumulate significant backports that aren't indicated in the nominal upstream version number, but are conveyed in the full REPL header (which has redistributor b

Re: [Python-Dev] Update to PEP 1 re: content type

2016-10-14 Thread Nick Coghlan
Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Python ROCKS! Thanks guys! [anecdote]

2016-10-12 Thread Nick Coghlan
www.curiousefficiency.org/posts/2015/10/languages-to-improve-your-python.html which looks at some other ways in which dismissing ecosystems out of hand can inhibit our ability to learn from both their mistakes and their successes. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia _

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-12 Thread Nick Coghlan
On 13 October 2016 at 12:54, Nick Coghlan <ncogh...@gmail.com> wrote: > Method proliferation on builtins is a Big Deal(TM) I wanted to quantify this concept, so here's a quick metric that helps convey how every time we add a new builtin method we're immediately making Python harder to c

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-12 Thread Nick Coghlan
. The notion of "we shouldn't need to define our own domain specific helper libraries" isn't a given for standard library modules any more than it is for 3rd party ones. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___

Re: [Python-Dev] Adding bytes.frombuffer() constructor to PEP 467 (was: [Python-ideas] Adding bytes.frombuffer() constructor

2016-10-11 Thread Nick Coghlan
/offset API design is also problematic due to the way it differs from range() & slice(), but I don't think it makes sense to get into that kind of detail before discussing the larger question of adding a new helper module for working efficiently with memory buffers vs further widening the method AP

Re: [Python-Dev] PyWeakref_GetObject() borrows its reference from... whom?

2016-10-10 Thread Nick Coghlan
ics, and the rules for GIL-independent source code would become: - new references must be decref'ed using the normal APIs - borrowed references must be decref'ed using the PyBorrowed* APIs (with a no-op compatibility shim for older GIL-only CPython versions) Regards, Nic

Re: [Python-Dev] Check dict implementation details

2016-10-08 Thread Nick Coghlan
hurn and improving cross-version and cross-implementation compatibility, doing that also lets the *reader* of the code know that the key iteration order matters. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Pytho

Re: [Python-Dev] __future__ and eval()

2016-10-02 Thread Nick Coghlan
*is* documented under __future__, but not under > exec/eval. I'm just suggesting adding another cross-reference. The most appropriate cross-reference would probably be to the compile() docs rather than the language reference though: https://docs.python.org/2/library/functions.html#comp

Re: [Python-Dev] TextIO seek and tell cookies

2016-09-25 Thread Nick Coghlan
? >> > An alternative might be a subclass of int. It could make sense to use a subclass of int that emitted deprecation warnings for integer arithmetic, and then eventually disallowed it entirely. Cheers, Nick. -- Nick Coghlan | ncogh...

Re: [Python-Dev] cpython (3.6): replace usage of Py_VA_COPY with the (C99) standard va_copy

2016-09-25 Thread Nick Coghlan
r how trivial the specific change needed is if getting it resolved and a new version published turns out to require a transfer of project ownership - the cost is in the ownership change rather than the software change itself. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Aust

Re: [Python-Dev] Python 3.6 dict becomes compact and gets a private version; and keywords become ordered

2016-09-13 Thread Nick Coghlan
o *3.5* (or Python 3 at all in the case of Jython and IronPython), I think we still have a good few years to ponder the question before this particular concern starts cropping up in practise :) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia

Re: [Python-Dev] Python 3.6 dict becomes compact and gets a private version; and keywords become ordered

2016-09-13 Thread Nick Coghlan
mework developers, and application developers that support "bring your own Python runtime" deployments, *not* on interpreter implementers. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list P

Re: [Python-Dev] PEP520 and absence of __definition_order__

2016-09-11 Thread Nick Coghlan
On 11 September 2016 at 13:05, Nick Coghlan <ncogh...@gmail.com> wrote: > VOC & Batavia *should* be OK (worst case, they return > collections.OrderedDict from __prepare__ and also use it for __dict__ > attributes), but I'm less certain about MicroPython (since I don't > kno

Re: [Python-Dev] Python 3.6 dict becomes compact and gets a private version; and keywords become ordered

2016-09-10 Thread Nick Coghlan
de for cross-version and cross-implementation compatibility - the popularity of explicit context management being one of the most significant examples of that, as it's far more necessary on implementations that don't use automatic reference counting the way CPython does. Cheers, Nick. -- Nick Coghlan | ncog

Re: [Python-Dev] PEP520 and absence of __definition_order__

2016-09-10 Thread Nick Coghlan
On 11 September 2016 at 07:26, Guido van Rossum <gu...@python.org> wrote: > On Sat, Sep 10, 2016 at 10:57 AM, Nick Coghlan <ncogh...@gmail.com> wrote: >> On 11 September 2016 at 03:08, Guido van Rossum <gu...@python.org> wrote: >>> So I'm happy to contin

Re: [Python-Dev] Let's make the SSL module sane

2016-09-10 Thread Nick Coghlan
On 11 September 2016 at 05:20, Christian Heimes <christ...@python.org> wrote: > On 2016-09-10 17:24, Nick Coghlan wrote: >> On 11 September 2016 at 00:22, Christian Heimes <christ...@python.org> wrote: >>> First I like to deprecated some old APIs and favor of SSLCot

Re: [Python-Dev] PEP520 and absence of __definition_order__

2016-09-10 Thread Nick Coghlan
st time around in thinking it would still be necessary even if class namespaces became order preserving :) -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mail

Re: [Python-Dev] [Webmaster] A broken link!

2016-09-10 Thread Nick Coghlan
Nick. P.S. Although in this case, it may have just been a direct link to the 3.2 version of the 3.2 What's New - there isn't a lot we can do about that, as when a branch goes unsupported, we usually stop updating the docs as well (even when external links break) -- Nick Coghlan | ncogh...@gm

Re: [Python-Dev] Let's make the SSL module sane

2016-09-10 Thread Nick Coghlan
cular goal is from a broader industry perspective, people don't tend to react to API breaks by fixing their code - they react by not upgrading at all. Regards, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev maili

Re: [Python-Dev] PEP520 and absence of __definition_order__

2016-09-10 Thread Nick Coghlan
On 10 September 2016 at 19:27, Nick Coghlan <ncogh...@gmail.com> wrote: > On 10 September 2016 at 17:49, Ethan Furman <et...@stoneleaf.us> wrote: >> The "mostly" is what concerns me. Much like having a custom __dir__ lets >> a class fine-tune what is of in

Re: [Python-Dev] sys.path file feature

2016-09-10 Thread Nick Coghlan
st as well for config files as it does for module and attribute names. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsu

Re: [Python-Dev] PEP520 and absence of __definition_order__

2016-09-10 Thread Nick Coghlan
ulty - __definition_order__ wasn't just there as a CPython implementation detail, it was there as a way to allow class and metaclass developers to hide their *own* irrelevant implementation details. Since __definition_order__ was already accepted, and the rationale for removing it is incor

Re: [Python-Dev] PEP 529: Change Windows filesystem encoding to UTF-8

2016-09-07 Thread Nick Coghlan
On 8 September 2016 at 03:37, Guido van Rossum <gu...@python.org> wrote: > On Sun, Sep 4, 2016 at 11:58 PM, Nick Coghlan <ncogh...@gmail.com> wrote: >> While calling system native apps that way will still have many >> portability challenges, there are also plen

Re: [Python-Dev] Making PEP 3156 (asyncio) non-provisional

2016-09-07 Thread Nick Coghlan
of access to asyncio internals are currently needed to implement 3rd party Transport classes, and perhaps lead to related future additions to the public API. Pending Amber's response, a definite thumbs up from me for removing the provisional caveat, and congratulations on a provisional experiment pro

Re: [Python-Dev] PEP 526 (variable annotations) accepted provisionally

2016-09-07 Thread Nick Coghlan
more automated refactorings that simplify their code. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://

<    4   5   6   7   8   9   10   11   12   13   >