types-PyMySQL 1.2.0.20260807__tar.gz → 1.2.4.20261111__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/CHANGELOG.md +8 -0
  2. {types_pymysql-1.2.0.20260807/types_PyMySQL.egg-info → types_pymysql-1.2.4.20261111}/PKG-INFO +7 -6
  3. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/README.md +6 -5
  4. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/METADATA.toml +1 -1
  5. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/connections.pyi +7 -12
  6. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/ER.pyi +2 -1
  7. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/converters.pyi +5 -6
  8. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/cursors.pyi +16 -4
  9. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pyproject.toml +7 -6
  10. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111/types_PyMySQL.egg-info}/PKG-INFO +7 -6
  11. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/LICENSE +0 -0
  12. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/MANIFEST.in +0 -0
  13. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/__init__.pyi +0 -0
  14. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/_auth.pyi +0 -0
  15. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/charset.pyi +0 -0
  16. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/CLIENT.pyi +0 -0
  17. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/COMMAND.pyi +0 -0
  18. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/CR.pyi +0 -0
  19. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/FIELD_TYPE.pyi +0 -0
  20. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/FLAG.pyi +0 -0
  21. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/SERVER_STATUS.pyi +0 -0
  22. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/constants/__init__.pyi +0 -0
  23. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/err.pyi +0 -0
  24. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/optionfile.pyi +0 -0
  25. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/protocol.pyi +0 -0
  26. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/py.typed +0 -0
  27. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/pymysql-stubs/times.pyi +0 -0
  28. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/setup.cfg +0 -0
  29. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/types_PyMySQL.egg-info/SOURCES.txt +0 -0
  30. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/types_PyMySQL.egg-info/dependency_links.txt +0 -0
  31. {types_pymysql-1.2.0.20260807 → types_pymysql-1.2.4.20261111}/types_PyMySQL.egg-info/top_level.txt +0 -0
@@ -1,3 +1,11 @@
1
+ ## [1.2.4.20261111](https://pypi.org/project/types-PyMySQL/1.2.4.20261111/) (2026-11-11)
2
+
3
+ * Sync ER constants with PyMySQL 1.2.4 ([#16753](https://github.com/python/typeshed/pull/16753))
4
+
5
+ ## [1.2.0.20260923](https://pypi.org/project/types-PyMySQL/1.2.0.20260923/) (2026-09-23)
6
+
7
+ * Update to 1.2.3 ([#16426](https://github.com/python/typeshed/pull/16426))
8
+
1
9
  ## [1.2.0.20260807](https://pypi.org/project/types-PyMySQL/1.2.0.20260807/) (2026-08-07)
2
10
 
3
11
  * Run Pyrefly on typeshed stubs in CI ([#16155](https://github.com/python/typeshed/pull/16155))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: types-PyMySQL
3
- Version: 1.2.0.20260807
3
+ Version: 1.2.4.20261111
4
4
  Summary: Typing stubs for PyMySQL
5
5
  License-Expression: Apache-2.0
6
6
  Project-URL: Homepage, https://github.com/python/typeshed
@@ -21,7 +21,7 @@ This is a [type stub package](https://typing.python.org/en/latest/tutorials/exte
21
21
  for the [`PyMySQL`](https://github.com/PyMySQL/PyMySQL) package. It can be used by type checkers
22
22
  to check code that uses `PyMySQL`. This version of
23
23
  `types-PyMySQL` aims to provide accurate annotations for
24
- `PyMySQL==1.2.*`.
24
+ `PyMySQL~=1.2.4`.
25
25
 
26
26
  This package is part of the [typeshed project](https://github.com/python/typeshed).
27
27
  All fixes for types and metadata should be contributed there.
@@ -31,9 +31,10 @@ for more details. The source for this package can be found in the
31
31
  directory.
32
32
 
33
33
  This package was tested with the following type checkers:
34
- * [mypy](https://github.com/python/mypy/) 2.3.0
35
- * [pyright](https://github.com/microsoft/pyright) 1.1.411
36
- * [ty](https://docs.astral.sh/ty/) 0.0.59
34
+ * [mypy](https://www.mypy-lang.org/) 2.4.1
35
+ * [pyrefly](https://pyrefly.org/) 1.4.0
36
+ * [pyright](https://microsoft.github.io/pyright/) 1.1.414
37
+ * [ty](https://docs.astral.sh/ty/) 0.0.95
37
38
 
38
39
  It was generated from typeshed commit
39
- [`e0efbeef901e9b6998d016e1ab9352678f09ae77`](https://github.com/python/typeshed/commit/e0efbeef901e9b6998d016e1ab9352678f09ae77).
40
+ [`7f0dcd5e88baf0d30047bda21f5954ca10235c19`](https://github.com/python/typeshed/commit/7f0dcd5e88baf0d30047bda21f5954ca10235c19).
@@ -4,7 +4,7 @@ This is a [type stub package](https://typing.python.org/en/latest/tutorials/exte
4
4
  for the [`PyMySQL`](https://github.com/PyMySQL/PyMySQL) package. It can be used by type checkers
5
5
  to check code that uses `PyMySQL`. This version of
6
6
  `types-PyMySQL` aims to provide accurate annotations for
7
- `PyMySQL==1.2.*`.
7
+ `PyMySQL~=1.2.4`.
8
8
 
9
9
  This package is part of the [typeshed project](https://github.com/python/typeshed).
10
10
  All fixes for types and metadata should be contributed there.
@@ -14,9 +14,10 @@ for more details. The source for this package can be found in the
14
14
  directory.
15
15
 
16
16
  This package was tested with the following type checkers:
17
- * [mypy](https://github.com/python/mypy/) 2.3.0
18
- * [pyright](https://github.com/microsoft/pyright) 1.1.411
19
- * [ty](https://docs.astral.sh/ty/) 0.0.59
17
+ * [mypy](https://www.mypy-lang.org/) 2.4.1
18
+ * [pyrefly](https://pyrefly.org/) 1.4.0
19
+ * [pyright](https://microsoft.github.io/pyright/) 1.1.414
20
+ * [ty](https://docs.astral.sh/ty/) 0.0.95
20
21
 
21
22
  It was generated from typeshed commit
22
- [`e0efbeef901e9b6998d016e1ab9352678f09ae77`](https://github.com/python/typeshed/commit/e0efbeef901e9b6998d016e1ab9352678f09ae77).
23
+ [`7f0dcd5e88baf0d30047bda21f5954ca10235c19`](https://github.com/python/typeshed/commit/7f0dcd5e88baf0d30047bda21f5954ca10235c19).
@@ -1,2 +1,2 @@
1
- version = "1.2.*"
1
+ version = "~=1.2.4"
2
2
  upstream-repository = "https://github.com/PyMySQL/PyMySQL"
@@ -1,12 +1,13 @@
1
- from _typeshed import FileDescriptorOrPath, Incomplete, Unused
2
- from collections.abc import Callable, Mapping
1
+ from _typeshed import Incomplete, Unused
2
+ from collections.abc import Callable
3
3
  from socket import _Address, socket as _socket
4
4
  from ssl import SSLContext, _PasswordType
5
- from typing import Any, AnyStr, Generic, Literal, overload
5
+ from typing import Any, Generic, Literal, overload
6
6
  from typing_extensions import Self, TypeVar, deprecated
7
7
 
8
8
  from .charset import charset_by_id as charset_by_id, charset_by_name as charset_by_name
9
9
  from .constants import CLIENT as CLIENT, COMMAND as COMMAND, FIELD_TYPE as FIELD_TYPE, SERVER_STATUS as SERVER_STATUS
10
+ from .converters import _EscaperMapping
10
11
  from .cursors import Cursor
11
12
  from .err import (
12
13
  DatabaseError,
@@ -210,9 +211,9 @@ class Connection(Generic[_C]):
210
211
  def begin(self) -> None: ...
211
212
  def rollback(self) -> None: ...
212
213
  def select_db(self, db) -> None: ...
213
- def escape(self, obj, mapping: Mapping[str, Incomplete] | None = None): ...
214
- def literal(self, obj): ...
215
- def escape_string(self, s: AnyStr) -> AnyStr: ...
214
+ def escape(self, obj: object, mapping: _EscaperMapping = None) -> str: ...
215
+ @deprecated("literal() is deprecated and will be removed in the next version.")
216
+ def literal(self, obj: object) -> str: ...
216
217
 
217
218
  @overload
218
219
  def cursor(self, cursor: None = None) -> _C: ...
@@ -273,9 +274,3 @@ class MySQLResult:
273
274
  first_packet: Incomplete
274
275
  def read(self) -> None: ...
275
276
  def init_unbuffered_query(self) -> None: ...
276
-
277
- class LoadLocalFile:
278
- filename: FileDescriptorOrPath
279
- connection: Connection[Any]
280
- def __init__(self, filename: FileDescriptorOrPath, connection: Connection[Any]) -> None: ...
281
- def send_data(self) -> None: ...
@@ -470,7 +470,8 @@ NO_TRIGGERS_ON_SYSTEM_SCHEMA: Final = 1465
470
470
  USERNAME: Final = 1466
471
471
  HOSTNAME: Final = 1467
472
472
  WRONG_STRING_LENGTH: Final = 1468
473
- ERROR_LAST: Final = 1468
473
+ MUST_CHANGE_PASSWORD: Final = 1820
474
+ MUST_CHANGE_PASSWORD_LOGIN: Final = 1862
474
475
  STATEMENT_TIMEOUT: Final = 1969
475
476
  QUERY_TIMEOUT: Final = 3024
476
477
  CONSTRAINT_FAILED: Final = 4025
@@ -10,16 +10,15 @@ from typing_extensions import Never, deprecated
10
10
  _EscaperMapping: TypeAlias = Mapping[type[object], Callable[..., str]] | None
11
11
  _T = TypeVar("_T")
12
12
 
13
- def escape_item(val: object, charset: object, mapping: _EscaperMapping = None) -> str: ...
14
- @deprecated("dict cannot be used as parameter. It didn't produce valid SQL and might cause SQL injection.")
15
- def escape_dict(val: Mapping[str, object], charset: object, mapping: _EscaperMapping = None) -> Never: ...
16
- def escape_sequence(val: Sequence[object], charset: object, mapping: _EscaperMapping = None) -> str: ...
17
- def escape_set(val: set[object], charset: object, mapping: _EscaperMapping = None) -> str: ...
13
+ def escape_item(val: object, charset: object = None, mapping: _EscaperMapping = None) -> str: ...
14
+ def escape_not_supported(val: object, charset: object = None, mapping: _EscaperMapping = None) -> Never: ...
15
+ def escape_sequence(val: Sequence[object], charset: object = None, mapping: _EscaperMapping = None) -> str: ...
16
+ @deprecated("escape_set is deprecated")
17
+ def escape_set(val: set[object], charset: object = None, mapping: _EscaperMapping = None) -> str: ...
18
18
  def escape_bool(value: bool, mapping: _EscaperMapping = None) -> str: ...
19
19
  def escape_int(value: int, mapping: _EscaperMapping = None) -> str: ...
20
20
  def escape_float(value: float, mapping: _EscaperMapping = None) -> str: ...
21
21
  def escape_string(value: str, mapping: _EscaperMapping = None) -> str: ...
22
- def escape_bytes_prefixed(value: bytes, mapping: _EscaperMapping = None) -> str: ...
23
22
  def escape_bytes(value: bytes, mapping: _EscaperMapping = None) -> str: ...
24
23
  def escape_str(value: str, mapping: _EscaperMapping = None) -> str: ...
25
24
  def escape_None(value: None, mapping: _EscaperMapping = None) -> str: ...
@@ -1,11 +1,12 @@
1
1
  import re
2
2
  from collections.abc import Iterable, Iterator
3
- from typing import Any, ClassVar
4
- from typing_extensions import Self
3
+ from typing import Any, ClassVar, TypeAlias, overload
4
+ from typing_extensions import Self, deprecated
5
5
 
6
6
  from .connections import Connection
7
7
 
8
8
  RE_INSERT_VALUES: re.Pattern[str]
9
+ _Args: TypeAlias = list[Any] | tuple[Any, ...] | dict[str, Any]
9
10
 
10
11
  class Cursor:
11
12
  max_stmt_length: ClassVar[int]
@@ -23,8 +24,19 @@ class Cursor:
23
24
  def setinputsizes(self, *args) -> None: ...
24
25
  def setoutputsizes(self, *args) -> None: ...
25
26
  def nextset(self) -> bool | None: ...
26
- def mogrify(self, query: str, args: object = None) -> str: ...
27
- def execute(self, query: str, args: object = None) -> int: ...
27
+
28
+ @overload
29
+ def mogrify(self, query: str, args: _Args | None = None) -> str: ...
30
+ @overload
31
+ @deprecated("single argument is deprecated and will be removed in the next version.")
32
+ def mogrify(self, query: str, args: object) -> str: ...
33
+
34
+ @overload
35
+ def execute(self, query: str, args: _Args | None = None) -> int: ...
36
+ @overload
37
+ @deprecated("single argument is deprecated and will be removed in the next version.")
38
+ def execute(self, query: str, args: object) -> int: ...
39
+
28
40
  def executemany(self, query: str, args: Iterable[object]) -> int | None: ...
29
41
  def callproc(self, procname: str, args: Iterable[Any] = ()) -> Any: ...
30
42
  def scroll(self, value: int, mode: str = "relative") -> None: ...
@@ -4,7 +4,7 @@ requires = ["setuptools>=82.0.1"]
4
4
 
5
5
  [project]
6
6
  name = "types-PyMySQL"
7
- version = "1.2.0.20260807"
7
+ version = "1.2.4.20261111"
8
8
  license = "Apache-2.0"
9
9
  license-files = ["LICENSE"]
10
10
  description = "Typing stubs for PyMySQL"
@@ -15,7 +15,7 @@ This is a [type stub package](https://typing.python.org/en/latest/tutorials/exte
15
15
  for the [`PyMySQL`](https://github.com/PyMySQL/PyMySQL) package. It can be used by type checkers
16
16
  to check code that uses `PyMySQL`. This version of
17
17
  `types-PyMySQL` aims to provide accurate annotations for
18
- `PyMySQL==1.2.*`.
18
+ `PyMySQL~=1.2.4`.
19
19
 
20
20
  This package is part of the [typeshed project](https://github.com/python/typeshed).
21
21
  All fixes for types and metadata should be contributed there.
@@ -25,12 +25,13 @@ for more details. The source for this package can be found in the
25
25
  directory.
26
26
 
27
27
  This package was tested with the following type checkers:
28
- * [mypy](https://github.com/python/mypy/) 2.3.0
29
- * [pyright](https://github.com/microsoft/pyright) 1.1.411
30
- * [ty](https://docs.astral.sh/ty/) 0.0.59
28
+ * [mypy](https://www.mypy-lang.org/) 2.4.1
29
+ * [pyrefly](https://pyrefly.org/) 1.4.0
30
+ * [pyright](https://microsoft.github.io/pyright/) 1.1.414
31
+ * [ty](https://docs.astral.sh/ty/) 0.0.95
31
32
 
32
33
  It was generated from typeshed commit
33
- [`e0efbeef901e9b6998d016e1ab9352678f09ae77`](https://github.com/python/typeshed/commit/e0efbeef901e9b6998d016e1ab9352678f09ae77).
34
+ [`7f0dcd5e88baf0d30047bda21f5954ca10235c19`](https://github.com/python/typeshed/commit/7f0dcd5e88baf0d30047bda21f5954ca10235c19).
34
35
  """, content-type = "text/markdown" }
35
36
  classifiers = [
36
37
  "Programming Language :: Python :: 3",
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: types-PyMySQL
3
- Version: 1.2.0.20260807
3
+ Version: 1.2.4.20261111
4
4
  Summary: Typing stubs for PyMySQL
5
5
  License-Expression: Apache-2.0
6
6
  Project-URL: Homepage, https://github.com/python/typeshed
@@ -21,7 +21,7 @@ This is a [type stub package](https://typing.python.org/en/latest/tutorials/exte
21
21
  for the [`PyMySQL`](https://github.com/PyMySQL/PyMySQL) package. It can be used by type checkers
22
22
  to check code that uses `PyMySQL`. This version of
23
23
  `types-PyMySQL` aims to provide accurate annotations for
24
- `PyMySQL==1.2.*`.
24
+ `PyMySQL~=1.2.4`.
25
25
 
26
26
  This package is part of the [typeshed project](https://github.com/python/typeshed).
27
27
  All fixes for types and metadata should be contributed there.
@@ -31,9 +31,10 @@ for more details. The source for this package can be found in the
31
31
  directory.
32
32
 
33
33
  This package was tested with the following type checkers:
34
- * [mypy](https://github.com/python/mypy/) 2.3.0
35
- * [pyright](https://github.com/microsoft/pyright) 1.1.411
36
- * [ty](https://docs.astral.sh/ty/) 0.0.59
34
+ * [mypy](https://www.mypy-lang.org/) 2.4.1
35
+ * [pyrefly](https://pyrefly.org/) 1.4.0
36
+ * [pyright](https://microsoft.github.io/pyright/) 1.1.414
37
+ * [ty](https://docs.astral.sh/ty/) 0.0.95
37
38
 
38
39
  It was generated from typeshed commit
39
- [`e0efbeef901e9b6998d016e1ab9352678f09ae77`](https://github.com/python/typeshed/commit/e0efbeef901e9b6998d016e1ab9352678f09ae77).
40
+ [`7f0dcd5e88baf0d30047bda21f5954ca10235c19`](https://github.com/python/typeshed/commit/7f0dcd5e88baf0d30047bda21f5954ca10235c19).