[Python-Dev] Re: Tool to search in the source code of PyPI top 5000 projects

2021-12-02 Thread Michał Górny
On Fri, 2021-12-03 at 00:44 +0100, Victor Stinner wrote: > I wrote two scripts based on the work of INADA-san's work to (1) > download the source code of the PyPI top 5000 projects (2) search for > a regex in these projects (compressed source archives). > > You can use these tools if you work on a

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Christopher Barker
On Thu, Dec 2, 2021 at 6:57 PM Stephan Richter wrote: > So maybe this is my time to chime in. I have used annotations for runtime > behavior. My primary use case is an injection library that I wrote. Does it work with __future__ annotations? -CHB > It allows > something along the lines of

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Stephan Richter
So maybe this is my time to chime in. I have used annotations for runtime behavior. My primary use case is an injection library that I wrote. It allows something along the lines of: class IMyService(IService): pass @inject def call_something(arg1: str, arg2: int, svc: IMyService = None):

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Christopher Barker
On Thu, Dec 2, 2021 at 3:35 PM Rob Cliffe via Python-Dev < python-dev@python.org> wrote: > I assume you accidentally pressed Send prematurely. > Actually, it was my phone making the text white -- what the heck? why is it so hard to send plain text email? resent now. -CHB > Still, maybe you

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Christopher Barker
resent -- damn iPhone! On Thu, Dec 2, 2021 at 3:20 PM Christopher Barker wrote: > >for library authors. > > > > Providing high quality stubs and the best user experience is not easy. > > But I believe that referring people to typeshed can help. > > > This is actually very helpful. It provides an

[Python-Dev] Re: Expectations of typing (was: The current state of typing PEPs)

2021-12-02 Thread Christopher Barker
On Thu, Dec 2, 2021 at 9:48 AM Eric Fahlgren wrote: > wait, what? It seems so clear to me that "PathLike" (as a type specifier) > would mean: anything that can be passed into os.fspath to give me a path. > (or, of course to the stdlib functions that take paths) >> >> >> Isn't the entire purpose o

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Shantanu Jain
@Paul > ... missing resource is a central set of typing documentation that includes examples, FAQs and best practices as well as reference materials Like Sebastian, I agree, and this is something we're making progress on. > ... easy way of testing that the stubs are correct mypy ships with a to

[Python-Dev] Tool to search in the source code of PyPI top 5000 projects

2021-12-02 Thread Victor Stinner
Hi, I wrote two scripts based on the work of INADA-san's work to (1) download the source code of the PyPI top 5000 projects (2) search for a regex in these projects (compressed source archives). You can use these tools if you work on an incompatible Python or C API change to estimate how many pro

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Rob Cliffe via Python-Dev
I assume you accidentally pressed Send prematurely. Still, maybe you have inadvertently listed everything that is agreed about typing PEPs. 😂 Rob Cliffe On 02/12/2021 23:20, Christopher Barker wrote: >for library authors. Providing high quality stubs and the best user experience is not

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Christopher Barker
>for library authors. > Providing high quality stubs and the best user experience is not easy. > But I believe that referring people to typeshed can help. This is actually very helpful. It provides an answer for open source projects for which do users want typing. One can say to the users that

[Python-Dev] Re: Expectations of typing (was: The current state of typing PEPs)

2021-12-02 Thread Brett Cannon
On Wed, Dec 1, 2021 at 10:40 PM Christopher Barker wrote: > I know this isn't really the place for this conversation, but: > > >> which is what `os.PathLike` represents, hence why `str` isn't covered by >> it); >> > > wait, what? It seems so clear to me that "PathLike" (as a type specifier) > wou

[Python-Dev] bpo-41544: Add missing parameters to dummy.DummyProcess and dummy.Pool

2021-12-02 Thread Martin Schröder
Hi, could someone please review my pull request? https://github.com/python/cpython/pull/21869 It adds missing parameters to multiprocessing.dummy.DummyProcess in order to match the API of multiprocessing.Process. Best regards, Martin Schröder ___

[Python-Dev] Re: Expectations of typing (was: The current state of typing PEPs)

2021-12-02 Thread Eric Fahlgren
On Wed, Dec 1, 2021 at 10:50 PM Christopher Barker wrote: > I know this isn't really the place for this conversation, but: > > >> which is what `os.PathLike` represents, hence why `str` isn't covered by >> it); >> > > wait, what? It seems so clear to me that "PathLike" (as a type specifier) > wou

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Sebastian Rittau
Am 01.12.21 um 13:36 schrieb Paul Moore: On Wed, 1 Dec 2021 at 12:08, Sebastian Rittau wrote: Please note that users of you library usually won't care that the library uses type hints. It's more important that there are type hints for the API, which can also be supplied using a stub file. I

[Python-Dev] Re: The current state of typing PEPs

2021-12-02 Thread Steve Holden
On Tue, Nov 30, 2021 at 5:05 PM Steven D'Aprano wrote: > On Tue, Nov 30, 2021 at 02:30:18PM +, Paul Moore wrote: > [...] > Aside: I'm a little disappointed in the way the typing ecosystem has > developed. What I understood was that we'd get type inference like ML or > Haskell use, so we would

[Python-Dev] Re: Oh look, I've been subscribed to python/issues-test-2 notifications again

2021-12-02 Thread Victor Stinner
Hi Ezio, What is the status of migrating Python issues to GitHub? Is it done? If not, what are remaining issues? Victor ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.