[Python-Dev] Re: Descriptors in dataclasses fields

2021-01-04 Thread Josue Balandrano Coronel
Then this is more of an issue with type hints rather than dataclasses. Interesting. On Mon, Jan 4, 2021, at 16:01, Josue Balandrano Coronel wrote: > Ah, very interesting. > > Just tried this and it worked. That's awesome, thanks! > > On Mon, Jan 4, 2021, at 15:45, Joao S. O. Bueno wrote: > > I

[Python-Dev] Re: Descriptors in dataclasses fields

2021-01-04 Thread Josue Balandrano Coronel
Ah, very interesting. Just tried this and it worked. That's awesome, thanks! On Mon, Jan 4, 2021, at 15:45, Joao S. O. Bueno wrote: > I think you are complicating things just because there is no easy way > to tell mypy > that although you are assigning a descriptor to a class variable > in the

[Python-Dev] Re: Where is the SQLite module maintainer

2021-01-04 Thread Erlend Aasland
> On 4 Jan 2021, at 17:34, Steve Dower wrote: > On 12/28/2020 11:32 AM, Erlend Aasland wrote: >>> On 27 Dec 2020, at 22:38, Christian Heimes >> > wrote: >>> How about you put your name in the expert index instead of him? :) >> Thanks for your confidence, but I'm far

[Python-Dev] Re: Descriptors in dataclasses fields

2021-01-04 Thread Joao S. O. Bueno
I think you are complicating things just because there is no easy way to tell mypy that although you are assigning a descriptor to a class variable in the class body, it will be used as a normal instance attribute afterwards - and it is the type used in the instance attribute that mypy should care

[Python-Dev] Re: Where is the SQLite module maintainer

2021-01-04 Thread Erlend Aasland
> On 4 Jan 2021, at 18:24, Guido van Rossum wrote: > > OTOH if you just want to have the PR merged I can do that -- it seems > unobjectionable. I'm eager to get it merged, so I'll appreciate it if you could help with that. Erlend ___ Python-Dev

[Python-Dev] [RELEASE] Python 3.10.0a4 is now available

2021-01-04 Thread Pablo Galindo Salgado
Happy new year to all of you. I hope you all have a great start of the year! And how to best celebrate that we have left 2020 behind that with a new Python alpha release? :) Go get it here: https://www.python.org/downloads/release/python-3100a4/ *Major new features of the 3.10 series, compared

[Python-Dev] Re: Enhancement request for PyUnicode proxies

2021-01-04 Thread Nelson, Karl E. via Python-Dev
I would like to second Steve's suggestion. The requirements for JPype for this to work are pretty minimal. If there were a bit flag for string like that was checked by PyString_Check and then a call to the PyObject_Str() which would be guaranteed to return a concrete Unicode which is then

[Python-Dev] Re: [Python-ideas] Re: Add venv activate command to the venv modules

2021-01-04 Thread Paul Sokolovsky
Hello, On Mon, 4 Jan 2021 21:07:23 +0400 Abdur-Rahmaan Janhangeer wrote: > @Christopher Barker > > You nailed it! I've used the conda activate command many times. > It should in theory be possible in Python > > @Chris Angelico > > Yes mere shell commands passing via Py does not work, >

[Python-Dev] Re: Where is the SQLite module maintainer

2021-01-04 Thread Guido van Rossum
OTOH if you just want to have the PR merged I can do that -- it seems unobjectionable. On Mon, Jan 4, 2021 at 8:41 AM Steve Dower wrote: > On 12/28/2020 11:32 AM, Erlend Aasland wrote: > >> On 27 Dec 2020, at 22:38, Christian Heimes >> > wrote: > >> How about you

[Python-Dev] Re: Enhancement request for PyUnicode proxies

2021-01-04 Thread Guido van Rossum
Do you want to be a champion for this development? Or does anyone else want to volunteer? On Mon, Jan 4, 2021 at 8:54 AM Steve Dower wrote: > On 12/29/2020 5:23 PM, Antoine Pitrou wrote: > > The third option is to add a distinct "string view" protocol. There > > are peculiarities (such as the

[Python-Dev] Re: Enhancement request for PyUnicode proxies

2021-01-04 Thread Steve Dower
On 12/29/2020 5:23 PM, Antoine Pitrou wrote: The third option is to add a distinct "string view" protocol. There are peculiarities (such as the fact that different objects may have different internal representations - some utf8, some utf16...) that make the buffer protocol suboptimal for this.

[Python-Dev] Re: Where is the SQLite module maintainer

2021-01-04 Thread Steve Dower
On 12/28/2020 11:32 AM, Erlend Aasland wrote: On 27 Dec 2020, at 22:38, Christian Heimes > wrote: How about you put your name in the expert index instead of him? :) Thanks for your confidence, but I'm far from an expert :) Neither is anyone else :) I'm not

[Python-Dev] Re: PEP 642 v3: Explicit patterns for structured pattern matching

2021-01-04 Thread Paul Moore
On Sun, 3 Jan 2021 at 23:38, Nick Coghlan wrote: > > The instance attribute syntax arose from trying to deal with two problems > from class patterns in PEP 634: > > * "ATTR=TARGET" using "=" to bind to the right instead of to the left > * no subsequent path to ever offering a syntax for