julien-duponchelle / python-mysql-replication

Pure Python Implementation of MySQL replication protocol build on top of PyMYSQL
2.31k stars 678 forks source link

fix log statement for BinLogStreamReader.fetchone #608

Closed bentsku closed 7 months ago

bentsku commented 7 months ago

Description

This PR fix the log statement in BinLogStreamReader.fetchone using logging.WARN, which triggers an exception. I've copied the same logic as the logging statement above, using logging.log(logging.WARN, <statement>) to fix this issue.

Type of Change

Checklist

Tests

Additional Information

bentsku commented 7 months ago

Apologies for the linting issue, forgot a trailing comma 😬

bentsku commented 7 months ago

Ah, I see. The step in the GitHub Action is running pip install black ruff and those are not versioned, but the pre-commit hook uses pinned versions. Installed the latest versions and called it manually and that fixed it. Running the lint script manually was using my global ruff install 😅

Anyway, finally now it should be fixed! Sorry for that 😬

sean-k1 commented 7 months ago

@bentsku Hello I was also checking to see if there was something wrong with LINT, thanks for explaining it so well. Thanks for the contribution