Skip to content

Conversation

@palm002
Copy link
Contributor

@palm002 palm002 commented Jun 19, 2024

Fixes #1173


Addresses the issue of UnboundLocalError which occurs when MySQLResult class fails to initialize due to a SystemExit exception by initialising the MySQLResult object before try/except block.

@palm002 palm002 marked this pull request as ready for review June 19, 2024 06:18
@codecov
Copy link

codecov bot commented Jun 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.47%. Comparing base (1e28be8) to head (c6d455b).
Report is 13 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1174      +/-   ##
==========================================
+ Coverage   86.24%   86.47%   +0.22%     
==========================================
  Files          17       17              
  Lines        2436     2425      -11     
  Branches      258      257       -1     
==========================================
- Hits         2101     2097       -4     
+ Misses        249      242       -7     
  Partials       86       86              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@methane methane merged commit 95635f5 into PyMySQL:main Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

UnboundLocalError occurs when MySQLResult fails to initialize due to SystemExit exception

2 participants