Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix lint error
  • Loading branch information
methane committed Feb 2, 2024
commit dc0a4b5b577343bc7d68bf0622f752d39aec64b1
1 change: 0 additions & 1 deletion pymysql/err.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,6 @@ def _map_error(exc, *errors):

def raise_mysql_exception(data):
errno = struct.unpack("<h", data[1:3])[0]
sqlstate = None
# https://dev.mysql.com/doc/dev/mysql-server/latest/page_protocol_basic_err_packet.html
# Error packet has optional sqlstate that is 5 bytes and starts with '#'.
if data[3] == 0x23: # '#'
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ version = {attr = "pymysql.VERSION_STRING"}
exclude = [
"pymysql/tests/thirdparty",
]

[tool.ruff.lint]
ignore = ["E721"]

[tool.pdm.dev-dependencies]
Expand Down