Skip to content

Commit

Permalink
refactor: remove scheduler_py and resolve imports
Browse files Browse the repository at this point in the history
  • Loading branch information
gilsondev committed Dec 20, 2023
1 parent 484e0df commit e01d16f
Show file tree
Hide file tree
Showing 13 changed files with 12 additions and 1,245 deletions.
8 changes: 4 additions & 4 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ services:

alembic:
build:
context: ./api
dockerfile: Dockerfile
context: .
dockerfile: Dockerfile.api
image: checkstatusgovbr/db-migration
ports:
- "8000:8000"
Expand Down Expand Up @@ -58,8 +58,8 @@ services:

alembic-test:
build:
context: ./api
dockerfile: Dockerfile
context: .
dockerfile: Dockerfile.api
image: checkstatusgovbr/db-migration
ports:
- "8000:8000"
Expand Down
File renamed without changes.
7 changes: 5 additions & 2 deletions pipeline/src/main.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import sentry_sdk
from cancelled_domains import update_domains as update_cancelled_domains
from collect_csv import prepare_dataset
from collect_rdap import collect_domain_rdap_data
from ingestion import ingestion_data
from normalize import normalize_data
from sentry_sdk import set_tag

from shared.database_py import create_connection
from shared.database_py import create_cursor
from shared.database_py.database import create_connection
from shared.database_py.database import create_cursor

sentry_sdk.init(
dsn="https://011f53de8eea0a53cb44e163d0453eb5@o4506032925900800.ingest.sentry.io/4506032926031872",
Expand All @@ -27,6 +28,8 @@

ingestion_data(df, cursor)

update_cancelled_domains(cursor)

conn.commit()
conn.close()
cursor.close()
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from unittest.mock import MagicMock
from unittest.mock import patch

from src.cancelled_domains import CANCELLED_DOMAINS_CSV
from src.cancelled_domains import get_cancelled_domains
from src.cancelled_domains import update_domains
from pipeline.src.cancelled_domains import CANCELLED_DOMAINS_CSV
from pipeline.src.cancelled_domains import get_cancelled_domains
from pipeline.src.cancelled_domains import update_domains


@patch("src.cancelled_domains.get_cancelled_domains")
Expand Down
24 changes: 0 additions & 24 deletions scheduler_py/Dockerfile

This file was deleted.

927 changes: 0 additions & 927 deletions scheduler_py/poetry.lock

This file was deleted.

27 changes: 0 additions & 27 deletions scheduler_py/pyproject.toml

This file was deleted.

67 changes: 0 additions & 67 deletions scheduler_py/setup.cfg

This file was deleted.

Empty file removed scheduler_py/src/__init__.py
Empty file.
37 changes: 0 additions & 37 deletions scheduler_py/src/main.py

This file was deleted.

45 changes: 0 additions & 45 deletions scheduler_py/src/ping.py

This file was deleted.

Empty file removed scheduler_py/tests/__init__.py
Empty file.
109 changes: 0 additions & 109 deletions scheduler_py/tests/test_ping.py

This file was deleted.

0 comments on commit e01d16f

Please sign in to comment.