[Python-Dev] Re: [python-committers] [IMPORTANT] Preparations for 3.11.0 beta 1

2022-04-06 Thread Inada Naoki
Hi, Pablo.

I just submitted the PEP 686 to the SC.
https://github.com/python/steering-council/issues/118

In this PEP, I am proposing:

a. Small improvement for UTF-8 mode in Python 3.11
b. Make UTF-8 mode default in Python 3.13.

(a) is an important change for (b) so I included it in the PEP.
More precisely, (a) contains two changes:

* Making `open(path, encoding="locale")` use locale encoding in UTF-8
mode (Python 3.10 used UTF-8)
* Add `locale.getencoding()` that is same to
`locale.getpreferredencoding(False)` but returns locale encoding even
in UTF-8 mode.

These changes are important for (b).
But they are not a big change needing PEP.

What should I do?

* Do not merge anything until PEP accepted.
* Merge (a) without waiting PEP accepted.
* Merge (a) and remove it from the PEP.

FWI, I and Victor are implementing `locale.getencoding()` for now.

https://bugs.python.org/issue47000
https://github.com/python/cpython/pull/32068

Regards,
-- 
Inada Naoki  
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/7E4QEKZ6HNDDPDL76LP3TBBKLAUQ7AHB/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Finn Mason
For whatever reason, the links for two PEPs wouldn't work, so here are
working ones:

* [PEP 646](https://peps.python.org/pep-0646/)
* [PEP 675](https://peps.python.org/pep-0675)

--
Finn (Mobile)

On Wed, Apr 6, 2022, 4:31 AM Pablo Galindo Salgado 
wrote:

> Br. do you feel that? That's the chill of *beta freeze* coming
> closer. Meanwhile, your friendly CPython release team doesn’t
> rest and we have prepared a shiny new release for you: Python 3.11.0a7.
>
>
> 
> Dear fellow core developer:
> This alpha is the last release before feature freeze (Friday, 2022-05-06),
> so make sure that all new features and PEPs are landed in the master branch
> before we
> release the first beta. Please, be specially mindfully to check the CI and
> the buildbots, maybe even using the test-with-buildbots label in GitHub
> before
> merging so the release team don’t need to fix a bunch of reference leaks
> or platform-specific problems on the first beta release.
>
> 
>
>
> *Go get the new alpha here:*
> https://www.python.org/downloads/release/python-3110a7/
>
> **This is an early developer preview of Python 3.11**
>
> # Major new features of the 3.11 series, compared to 3.10
>
> Python 3.11 is still in development.  This release, 3.11.0a7 is the last
> of seven planned alpha releases.
>
> Alpha releases are intended to make it easier to test the current state of
> new features and bug fixes and to test the release process.
>
> During the alpha phase, features may be added up until the start of the
> beta phase (2022-05-06) and, if necessary, may be modified or deleted up
> until the release candidate phase (2022-08-01).  Please keep in mind that
> this is a preview release and its use is **not** recommended for production
> environments.
>
> Many new features for Python 3.11 are still being planned and written.
> Among the new major new features and changes so far:
>
> * [PEP 657](https://www.python.org/dev/peps/pep-0657/) -- Include
> Fine-Grained Error Locations in Tracebacks
> * [PEP 654](https://www.python.org/dev/peps/pep-0654/) -- Exception
> Groups and except*
> * [PEP 673](https://www.python.org/dev/peps/pep-0673/)  -- Self Type
> * [PEP 646](https://www.python.org/dev/peps/pep-0646/)-- Variadic Generics
> * [PEP 680](https://www.python.org/dev/peps/pep-0680/)-- tomllib: Support
> for Parsing TOML in the Standard Library
> * [PEP 675](https://www.python.org/dev/peps/pep-0675/)-- Arbitrary
> Literal String Type
> * [PEP 655](https://www.python.org/dev/peps/pep-0655/)-- Marking
> individual TypedDict items as required or potentially-missing
> * [bpo-46752](https://bugs.python.org/issue46752)-- Introduce task groups
> to asyncio
> * The [Faster Cpython Project](https://github.com/faster-cpython) is
> already yielding some exciting results: this version of CPython 3.11 is
> ~12% faster on the geometric mean of the [PyPerformance benchmarks](
> speed.python.org), compared to 3.10.0.
>  * Hey, **fellow core developer,** if a feature you find important is
> missing from this list, let me know.
>
> The next pre-release of Python 3.11 will be 3.11.0b1, currently scheduled
> for Friday, 2022-05-06.
>
> # More resources
>
> * [Online Documentation](https://docs.python.org/3.11/)
> * [PEP 664](https://www.python.org/dev/peps/pep-0664/), 3.11 Release
> Schedule
> * Report bugs at [https://bugs.python.org](https://bugs.python.org).
> * [Help fund Python and its community](/psf/donations/).
>
> # And now for something completely different
>
> In mathematics, the Dirac delta distribution (δ distribution) is a
> generalized function or distribution over the real numbers, whose value is
> zero everywhere except at zero, and whose integral over the entire real
> line is equal to one. The current understanding of the impulse is as a
> linear functional that maps every continuous function to its value at zero.
> The delta function was introduced by physicist Paul Dirac as a tool for the
> normalization of state vectors. It also has uses in probability theory and
> signal processing. Its validity was disputed until Laurent Schwartz
> developed the theory of distributions where it is defined as a linear form
> acting on functions. Defining this distribution as a "function" as many
> physicist do is known to be one of the easier ways to annoy mathematicians
> :)
>
> # We hope you enjoy those new releases!
>
> Thanks to all of the many volunteers who help make Python Development and
> these releases possible! Please consider supporting our efforts by
> volunteering yourself or through organization contributions to the Python
> Software Foundation.
>
> Your friendly release team,
> Pablo Galindo @pablogsal
> Ned Deily @nad
> 

[Python-Dev] Re: C API: Move PEP 523 "Adding a frame evaluation API to CPython" private C API to the internal C API

2022-04-06 Thread Nick Coghlan
On Wed, 6 Apr 2022, 7:05 am Victor Stinner,  wrote:

> On Sun, Apr 3, 2022 at 3:29 PM Nick Coghlan  wrote:
> > The changes you've made have been excellent, and the existing 3
> categories (stable public ABI, stable public API, unstable internal API)
> cover the vast majority of cases.
> >
> > The final case that isn't quite covered yet is to offer a "semi-stable"
> API category for use cases that are intrinsically coupled to implementation
> details that may change between feature releases, but should remain stable
> within a release series.
> >
> > The concrete motivating example for the new category is the extra APIs
> you need in order to provide an alternative eval loop implementation.
> >
> > The internal API category doesn't properly cover that case, as the APIs
> there are free to change even in maintenance releases, and setting
> Py_BUILD_CORE exposes a lot more than what an alternative eval loop would
> need.
> >
> > Regular public functions may work in some cases, but aren't necessarily
> practical in others (such as exposing the internal frame details for use in
> alternative eval loops).
> >
> > From an implementation PoV, my own suggestion would be to define a new
> API tier with an opt-in macro rather than relying solely on documentation
> or naming conventions.
> >
> > For example, define "Py_SEMI_STABLE_API" to opt in, with the headers
> under "Include/cpython/semi_stable/" (I don't like "unstable" as potential
> terminology here, since the internal API is already unstable - we're
> splitting the difference between that and the long term stability of the
> full public API)
>
> For me an API is either stable (remains the same forever) or unstable
> (change time to time).
>
> Public API means: stable, documented, tested.
>
> Internal API means: unstable, not documented, not tested.
>
> I'm not convinced that it's worth it to create something in the
> middle. If you want to add doc and tests, it should become a public
> stable API.
>

The middle semi-stable tier formalises a concept that we already have: no
guarantees across feature releases, but both API and ABI stable within a
release series.

It's useful for tightly coupled projects like Cython, as it means they can
get core level performance without the risk of API compatibility breaks in
maintenance releases.

Without defining this tier, effectively the *entire* internal API becomes
semi-stable, as any changes made will risk breaking the third party
projects that we've told to define Py_BUILD_CORE when compiling.

Cheers,
Nick.



>
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/7P3ENW56DFR5BOUFSOQUSXPFQNQ5MF56/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Pablo Galindo Salgado
I will consider adding it, but I am not sure it qualifies as a "major
feature". I will think about it :)

On Wed, 6 Apr 2022 at 13:38, Jeremiah Vivian 
wrote:

> > Can you provide a bpo number, please?
> bpo-433030
> ___
> Python-Dev mailing list -- python-dev@python.org
> To unsubscribe send an email to python-dev-le...@python.org
> https://mail.python.org/mailman3/lists/python-dev.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-dev@python.org/message/M46P53HIT54YIJWJGE65P6CSWOBNDVYB/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/NIMY6CJBIFCQL4SZMTEF2VEOQ2CUGZDU/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Jeremiah Vivian
> Can you provide a bpo number, please?
bpo-433030
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/M46P53HIT54YIJWJGE65P6CSWOBNDVYB/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Jeremiah Vivian
> Among the new major new features and changes so far:
This section of major new features should've included the addition of atomic 
groups/possessive matching into the `re` module. This is a boost in regex 
matching performance when the pattern doesn't need any backtracking.
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/RQLG4LHKRALHERZKARFXUDTYCRBFV6ST/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Pablo Galindo Salgado
> This section of major new features should've included the addition of
atomic groups/possessive matching into the `re` module. This is a boost in
regex matching performance when the pattern doesn't need any backtracking.

Can you provide a bpo number, please?

On Wed, 6 Apr 2022 at 13:15, Jeremiah Vivian 
wrote:

> > Among the new major new features and changes so far:
> This section of major new features should've included the addition of
> atomic groups/possessive matching into the `re` module. This is a boost in
> regex matching performance when the pattern doesn't need any backtracking.
> ___
> Python-Dev mailing list -- python-dev@python.org
> To unsubscribe send an email to python-dev-le...@python.org
> https://mail.python.org/mailman3/lists/python-dev.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-dev@python.org/message/RQLG4LHKRALHERZKARFXUDTYCRBFV6ST/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/TOPYFQCA67CJ6NRFT7BTUIQIVTCMDO6I/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] [IMPORTANT] Preparations for 3.11.0 beta 1

2022-04-06 Thread Pablo Galindo Salgado
Hi everyone,

We have approximately one month until feature freeze and for 3.11.0b1 to be
released. I wanted to take this time to share some planning
and considerations with you. Please, read carefully these points as they
are important.

* 3.11.0b1 is scheduled for Friday, 2022-05-06, which is after the PyCon US
sprints. As the sprints normally end with a considerable
amount of PRs getting merged and the buildbots having a hard time, I may
need to move the release before or after to accommodate
for this and to prevent the release from going haywire. I will share
updates with you as they become available.

* The latest alpha releases have been quite challenging. We had a
considerable number of release blockers and issues that were raised
just a couple of days before the release. Please, check the release
blockers on bpo/Github as much as you can and make sure these are resolved
before the release date. Any release blockers for 3.11 will block feature
freeze. If this happens, the main branch will be blocked and only
PRs fixing the blockers will be allowed in that time.

* Important!! Please, if you are planning to commit a big chunk of code/ a
new big refactor/ a new big feature/ a PEP implementation within this month,
please let me know (an email works) so we can be on top of things in the
release team and so I can keep an eye on regressions.

* Any regression at the time of beta freeze will potentially result in the
release team being forced to revert commits and PRs. This means that if we
need
to revert a new feature or similar it may be delayed to 3.12, so be sure to
not commit unstable code as much as is humanly possible.

Please, reach out to me if you have any questions, comments or if you want
to discuss anything.

I want to thank you all for your understanding and collaboration :)

Kind regards from rainy London,
Your friendly release team
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/NCAQXXV6MYP24V6WO4BUC4Y7BZK4FM7D/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: C API: Move PEP 523 "Adding a frame evaluation API to CPython" private C API to the internal C API

2022-04-06 Thread Steve Dower

On 4/5/2022 11:52 PM, Victor Stinner wrote:

On Fri, Apr 1, 2022 at 12:36 PM Steve Dower  wrote:

I don't see any additional discussion on the bug, and the prevailing
opinion from actual users of this API is that it probably shouldn't
change,


 From what I understood my change basically only impacts "pydevd"
users. Fabio who works on that project said that he was fine with
that change ("I'm ok with changes"):
https://mail.python.org/archives/list/python-dev@python.org/message/XPDT55ANVKHGG74D62HDBOFLC4EXWJ26/


"I'm okay with" isn't really a sign of support, particularly in this 
kind of relationship where *we* have all the power. Fabio doesn't have a 
choice but to be okay with whatever we decide, and he obviously accepts 
that.


I'm still going to strongly advocate for not going out of our way to 
break users like Fabio. Just because we have a reputation for doing it 
doesn't mean we should keep doing it.



For me, all impacted users were made aware and joined the discussion.
It's very rare to be able to reach *all* users impacted by an
incompatible C API change!


There's no way we reached all the users :) But we did reach more than usual.


On Fri, Apr 1, 2022 at 12:36 PM Steve Dower  wrote:

and certainly shouldn't become internal without additional
guarantees about stability.


The discussed API is not stable, Brett repeated that. The internal API
is not stable on purpose. I missed the discussion proposing to design
a stable API for PEP 523.


I can't tell whether you missed the discussion or if you're deliberately 
misrepresenting it as a persuasive technique.


The API may not be "stable" according to our typical rules around public 
C APIs, but it has explicit rules about its own stability (well, had, 
though once the revert goes in it will have them again).


Nobody suggested making it *more* stable than it already was. We just 
want to treat its existing stability rules with respect and either 
transition out of them slowly, or leave them as they are.


Cheers,
Steve
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/226B54YXCYX4JNYTVGNSOVN6ONJZX7PC/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Pablo Galindo Salgado
A small correction (is fixed in other announcement pages):

The Faster Cpython Project is already yielding some exciting results: this
> version of CPython 3.11 is *~ 19%* faster on the geometric mean of the
> performance benchmarks, compared to 3.10.0.


That is, is not 12% faster but 19% faster. More updated benchmarks will be
published on beta 1.

Apologies for the confusion.

Pablo Galindo Salgado

On Wed, 6 Apr 2022 at 11:29, Pablo Galindo Salgado 
wrote:

> Br. do you feel that? That's the chill of *beta freeze* coming
> closer. Meanwhile, your friendly CPython release team doesn’t
> rest and we have prepared a shiny new release for you: Python 3.11.0a7.
>
>
> 
> Dear fellow core developer:
> This alpha is the last release before feature freeze (Friday, 2022-05-06),
> so make sure that all new features and PEPs are landed in the master branch
> before we
> release the first beta. Please, be specially mindfully to check the CI and
> the buildbots, maybe even using the test-with-buildbots label in GitHub
> before
> merging so the release team don’t need to fix a bunch of reference leaks
> or platform-specific problems on the first beta release.
>
> 
>
>
> *Go get the new alpha here:*
> https://www.python.org/downloads/release/python-3110a7/
>
> **This is an early developer preview of Python 3.11**
>
> # Major new features of the 3.11 series, compared to 3.10
>
> Python 3.11 is still in development.  This release, 3.11.0a7 is the last
> of seven planned alpha releases.
>
> Alpha releases are intended to make it easier to test the current state of
> new features and bug fixes and to test the release process.
>
> During the alpha phase, features may be added up until the start of the
> beta phase (2022-05-06) and, if necessary, may be modified or deleted up
> until the release candidate phase (2022-08-01).  Please keep in mind that
> this is a preview release and its use is **not** recommended for production
> environments.
>
> Many new features for Python 3.11 are still being planned and written.
> Among the new major new features and changes so far:
>
> * [PEP 657](https://www.python.org/dev/peps/pep-0657/) -- Include
> Fine-Grained Error Locations in Tracebacks
> * [PEP 654](https://www.python.org/dev/peps/pep-0654/) -- Exception
> Groups and except*
> * [PEP 673](https://www.python.org/dev/peps/pep-0673/)  -- Self Type
> * [PEP 646](https://www.python.org/dev/peps/pep-0646/)-- Variadic Generics
> * [PEP 680](https://www.python.org/dev/peps/pep-0680/)-- tomllib: Support
> for Parsing TOML in the Standard Library
> * [PEP 675](https://www.python.org/dev/peps/pep-0675/)-- Arbitrary
> Literal String Type
> * [PEP 655](https://www.python.org/dev/peps/pep-0655/)-- Marking
> individual TypedDict items as required or potentially-missing
> * [bpo-46752](https://bugs.python.org/issue46752)-- Introduce task groups
> to asyncio
> * The [Faster Cpython Project](https://github.com/faster-cpython) is
> already yielding some exciting results: this version of CPython 3.11 is
> ~12% faster on the geometric mean of the [PyPerformance benchmarks](
> speed.python.org), compared to 3.10.0.
>  * Hey, **fellow core developer,** if a feature you find important is
> missing from this list, let me know.
>
> The next pre-release of Python 3.11 will be 3.11.0b1, currently scheduled
> for Friday, 2022-05-06.
>
> # More resources
>
> * [Online Documentation](https://docs.python.org/3.11/)
> * [PEP 664](https://www.python.org/dev/peps/pep-0664/), 3.11 Release
> Schedule
> * Report bugs at [https://bugs.python.org](https://bugs.python.org).
> * [Help fund Python and its community](/psf/donations/).
>
> # And now for something completely different
>
> In mathematics, the Dirac delta distribution (δ distribution) is a
> generalized function or distribution over the real numbers, whose value is
> zero everywhere except at zero, and whose integral over the entire real
> line is equal to one. The current understanding of the impulse is as a
> linear functional that maps every continuous function to its value at zero.
> The delta function was introduced by physicist Paul Dirac as a tool for the
> normalization of state vectors. It also has uses in probability theory and
> signal processing. Its validity was disputed until Laurent Schwartz
> developed the theory of distributions where it is defined as a linear form
> acting on functions. Defining this distribution as a "function" as many
> physicist do is known to be one of the easier ways to annoy mathematicians
> :)
>
> # We hope you enjoy those new releases!
>
> Thanks to all of the many volunteers who help make Python Development and
> these releases possible! Please 

[Python-Dev] [RELEASE] The last Python 3.11 alpha (3.11.0a7) is available - Prepare for beta freeze

2022-04-06 Thread Pablo Galindo Salgado
Br. do you feel that? That's the chill of *beta freeze* coming
closer. Meanwhile, your friendly CPython release team doesn’t
rest and we have prepared a shiny new release for you: Python 3.11.0a7.


Dear fellow core developer:
This alpha is the last release before feature freeze (Friday, 2022-05-06),
so make sure that all new features and PEPs are landed in the master branch
before we
release the first beta. Please, be specially mindfully to check the CI and
the buildbots, maybe even using the test-with-buildbots label in GitHub
before
merging so the release team don’t need to fix a bunch of reference leaks or
platform-specific problems on the first beta release.



*Go get the new alpha here:*
https://www.python.org/downloads/release/python-3110a7/

**This is an early developer preview of Python 3.11**

# Major new features of the 3.11 series, compared to 3.10

Python 3.11 is still in development.  This release, 3.11.0a7 is the last of
seven planned alpha releases.

Alpha releases are intended to make it easier to test the current state of
new features and bug fixes and to test the release process.

During the alpha phase, features may be added up until the start of the
beta phase (2022-05-06) and, if necessary, may be modified or deleted up
until the release candidate phase (2022-08-01).  Please keep in mind that
this is a preview release and its use is **not** recommended for production
environments.

Many new features for Python 3.11 are still being planned and written.
Among the new major new features and changes so far:

* [PEP 657](https://www.python.org/dev/peps/pep-0657/) -- Include
Fine-Grained Error Locations in Tracebacks
* [PEP 654](https://www.python.org/dev/peps/pep-0654/) -- Exception Groups
and except*
* [PEP 673](https://www.python.org/dev/peps/pep-0673/)  -- Self Type
* [PEP 646](https://www.python.org/dev/peps/pep-0646/)-- Variadic Generics
* [PEP 680](https://www.python.org/dev/peps/pep-0680/)-- tomllib: Support
for Parsing TOML in the Standard Library
* [PEP 675](https://www.python.org/dev/peps/pep-0675/)-- Arbitrary Literal
String Type
* [PEP 655](https://www.python.org/dev/peps/pep-0655/)-- Marking individual
TypedDict items as required or potentially-missing
* [bpo-46752](https://bugs.python.org/issue46752)-- Introduce task groups
to asyncio
* The [Faster Cpython Project](https://github.com/faster-cpython) is
already yielding some exciting results: this version of CPython 3.11 is
~12% faster on the geometric mean of the [PyPerformance benchmarks](
speed.python.org), compared to 3.10.0.
 * Hey, **fellow core developer,** if a feature you find important is
missing from this list, let me know.

The next pre-release of Python 3.11 will be 3.11.0b1, currently scheduled
for Friday, 2022-05-06.

# More resources

* [Online Documentation](https://docs.python.org/3.11/)
* [PEP 664](https://www.python.org/dev/peps/pep-0664/), 3.11 Release
Schedule
* Report bugs at [https://bugs.python.org](https://bugs.python.org).
* [Help fund Python and its community](/psf/donations/).

# And now for something completely different

In mathematics, the Dirac delta distribution (δ distribution) is a
generalized function or distribution over the real numbers, whose value is
zero everywhere except at zero, and whose integral over the entire real
line is equal to one. The current understanding of the impulse is as a
linear functional that maps every continuous function to its value at zero.
The delta function was introduced by physicist Paul Dirac as a tool for the
normalization of state vectors. It also has uses in probability theory and
signal processing. Its validity was disputed until Laurent Schwartz
developed the theory of distributions where it is defined as a linear form
acting on functions. Defining this distribution as a "function" as many
physicist do is known to be one of the easier ways to annoy mathematicians
:)

# We hope you enjoy those new releases!

Thanks to all of the many volunteers who help make Python Development and
these releases possible! Please consider supporting our efforts by
volunteering yourself or through organization contributions to the Python
Software Foundation.

Your friendly release team,
Pablo Galindo @pablogsal
Ned Deily @nad
Steve Dower @steve.dower
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/L42CSIJJBZRDC5UTXI4BXBT2KQ2HHPCI/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: [External] : Re: Slowly bend the C API towards the limited API to get a stable ABI for everyone

2022-04-06 Thread Tim Felgentreff
Hi,

(I briefly commented also on the doc regarding this)

I’m probably misinterpreting the exact goals. I read “stable ABI for everyone” 
and I’m thinking “what needs to happen to stay binary compatible and working 
for a couple of decades at least”. If that were the goal, I think the ideas 
around HPy’s handles and it’s usage of a context to get access to function 
pointers are most important, since that will ensure that new APIs can be added 
and old ones removed without breaking ABI. (This is very similar to how e.g. 
libraries like SDL deal with the problem that distributors want to update the 
SDL library and have it still work with 10 year old proprietary games).

In particular, even things like slots in types need to be opaque. An optimizing 
runtime may want to use varying layouts for both types and objects - allowing 
direct access into any runtime structures prevents that. Exposed structures 
should not be used for any runtime objects, only as specs for construction of 
those runtime objects.

Best,
Tim

From: Victor Stinner
Sent: Tuesday, April 5, 2022 10:54 PM
To: Petr Viktorin
Cc: Python Dev
Subject: [External] : [Python-Dev] Re: Slowly bend the C API towards the 
limited API to get a stable ABI for everyone

IMO it would be better to keep the HPy design as the long term goal:

* Refer to Python objects with opaque handles
* All structures are opaque (with a few exceptions, like PyType_Spec)

It will likely take multiple iterations (Python releases) to reach
this goal, and incompatible C API changes may need a PEP (like PEP
674), but IMO it's good to keep this goal in mind.

Otherwise, it's not easy to understand the rationale for changes like
https://urldefense.com/v3/__https://peps.python.org/pep-0674/__;!!ACWV5N9M2RV99hQ!eClvPBBrluADcw7qiB1sfyVPEAyTXoolnPkf_c9MLV-1Ns5roXVSrOKLBqaRmzmIsF1a$
  "PEP 674 – Disallow using macros as
l-values".

Victor
--
Night gathers, and now my watch begins. It shall not end until my death.
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://urldefense.com/v3/__https://mail.python.org/mailman3/lists/python-dev.python.org/__;!!ACWV5N9M2RV99hQ!eClvPBBrluADcw7qiB1sfyVPEAyTXoolnPkf_c9MLV-1Ns5roXVSrOKLBqaRm7Y1wy1v$
Message archived at 
https://urldefense.com/v3/__https://mail.python.org/archives/list/python-dev@python.org/message/3FYHB74CF6XBADFRLUVFV6NUZKXRSBSY/__;!!ACWV5N9M2RV99hQ!eClvPBBrluADcw7qiB1sfyVPEAyTXoolnPkf_c9MLV-1Ns5roXVSrOKLBqaRm9YsYkeW$
Code of Conduct: 
https://urldefense.com/v3/__http://python.org/psf/codeofconduct/__;!!ACWV5N9M2RV99hQ!eClvPBBrluADcw7qiB1sfyVPEAyTXoolnPkf_c9MLV-1Ns5roXVSrOKLBqaRm9jKqd_2$

___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/PLZF35WCRCD37HVNQYVRHD5DCVNZKRGN/
Code of Conduct: http://python.org/psf/codeofconduct/


[Python-Dev] Re: Descriptions in unittest and avoiding confusion

2022-04-06 Thread Steve Holden
On Mon, Apr 4, 2022 at 4:13 PM Coyot Linden (Glenn Glazer) <
co...@lindenlab.com> wrote:

> I would like to point out another use case of triple quotes outside of
> docstrings. We do a lot of SQL here and so doing a parameterized query
> like:
>
> """SELECT foo
> FROM bar
> WHERE baz = %s"""
>
> is a whole lot cleaner and more natural than
>
> ("SELECT foo" +
> "FROM bar" +
> "WHERE baz = %s")
>
[...]

In the interests of fairness I should point out that the concatenation
operators are redundant in the second example, and without them (thanks to
the parentheses) the literals will be concatenated at compile time. I often
use

  (code of some sort)'''\
SELECT foo
FROM bar
WHERE baz = %s"""

to ensure the multiline string literal is correctly aligned, making
indentation issues easier to diagnose.

regards
 Steve
___
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/JL4TUDTSSSNSSFB7WJZTPXDUK6CPZDTG/
Code of Conduct: http://python.org/psf/codeofconduct/