Skip to content
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

Move errata record creation in dramatiq task #1042

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Kwaizer
Copy link
Contributor

@Kwaizer Kwaizer commented Nov 6, 2024

Resolves: AlmaLinux/build-system#318

  • Moved both create_errata_record and create_new_errata_record to dramatiq task
  • Switched to accessing AsyncSession via context manager rather than sending it as a parameter

@Kwaizer Kwaizer force-pushed the errata_creation branch 10 times, most recently from cfaef03 to 204f1c4 Compare November 11, 2024 09:17
Copy link
Contributor

@Korulag Korulag left a comment

Choose a reason for hiding this comment

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

Please fix tests

@Kwaizer Kwaizer force-pushed the errata_creation branch 18 times, most recently from 7bcd132 to 25510db Compare November 12, 2024 01:24
@Kwaizer Kwaizer force-pushed the errata_creation branch 4 times, most recently from 3856279 to f999ba1 Compare November 12, 2024 02:28
@Kwaizer Kwaizer requested a review from Korulag November 12, 2024 08:45
Copy link
Contributor

@anfimovdm anfimovdm left a comment

Choose a reason for hiding this comment

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

Also, please fix the following warnings from the pylint report:

alws/routers/errata.py:1:0: R0401: Cyclic import (alws.dramatiq -> alws.dramatiq.errata) (cyclic-import)
alws/dramatiq/errata.py:22:0: W0311: Bad indentation. Found 5 spaces, expected 4 (bad-indentation)

alws/crud/errata.py Outdated Show resolved Hide resolved
alws/crud/errata.py Outdated Show resolved Hide resolved
alws/crud/errata.py Outdated Show resolved Hide resolved
alws/routers/errata.py Show resolved Hide resolved
alws/routers/errata.py Show resolved Hide resolved
tests/fixtures/errata.py Outdated Show resolved Hide resolved
import pytest

from alws.dramatiq.errata import create_new_errata
Copy link
Member

Choose a reason for hiding this comment

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

Is this import really required here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh, not anymore

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.

Move errata record creation in dramatiq task
4 participants