psycopg2: Fix missing Protocol base class in file protocols (#10943)

This is an error I introduced in #10630 because I didn't know protocols
need to be explicitly inherited from in other protocol subclasses.

The added test shows the change. Basically these protocols were unusable.
This commit is contained in:
Ali Hamdan
2023-10-28 16:09:39 +02:00
committed by GitHub
parent 5643362a1e
commit 306c30a0c7
2 changed files with 8 additions and 2 deletions
+2 -2
View File
@@ -83,8 +83,8 @@ threadsafety: int
__libpq_version__: int
class _SupportsReadAndReadline(SupportsRead[str], SupportsReadline[str]): ...
class _SupportsReadAndReadlineAndWrite(_SupportsReadAndReadline, SupportsWrite[str]): ...
class _SupportsReadAndReadline(SupportsRead[str], SupportsReadline[str], Protocol): ...
class _SupportsReadAndReadlineAndWrite(_SupportsReadAndReadline, SupportsWrite[str], Protocol): ...
class cursor:
arraysize: int