Skip to content

Pyscopg3 port #38

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 19 commits into from
Apr 14, 2025
Merged

Pyscopg3 port #38

merged 19 commits into from
Apr 14, 2025

Conversation

danidee10
Copy link
Owner

@danidee10 danidee10 commented Apr 7, 2025

TODO

  • Replace aiopg with pyscopg3
  • Replace setup.py with pyproject.toml
  • Standardize code with pylint and mypy
  • Fix reported issues from pylint and mypy
  • Update documentation

@danidee10 danidee10 marked this pull request as draft April 7, 2025 09:42
@codecov-commenter
Copy link

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

Thanks for integrating Codecov - We've got you covered ☂️

@danidee10 danidee10 marked this pull request as ready for review April 14, 2025 22:24
@danidee10 danidee10 requested a review from Copilot April 14, 2025 22:25
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 17 out of 19 changed files in this pull request and generated 1 comment.

Files not reviewed (2)
  • setup.cfg: Language not supported
  • tox.ini: Language not supported

Comment on lines 224 to 227
message = (base64.b64decode(base64_message),)
if float(timestamp) < time.time():
continue
message = (base64.b64decode(base64_message),)
Copy link
Preview

Copilot AI Apr 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The base64 decoding of 'base64_message' is performed twice consecutively in the '_get_message_from_channel' method. Consider decoding once and reusing the result to improve efficiency.

Suggested change
message = (base64.b64decode(base64_message),)
if float(timestamp) < time.time():
continue
message = (base64.b64decode(base64_message),)
decoded_message = base64.b64decode(base64_message)
message = (decoded_message,)
if float(timestamp) < time.time():
continue
message = (decoded_message,)

Copilot uses AI. Check for mistakes.

@danidee10 danidee10 merged commit 967d7cf into main Apr 14, 2025
6 checks passed
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.

2 participants