Skip to content

Commit

Permalink
Few changes to the codebase
Browse files Browse the repository at this point in the history
  • Loading branch information
ADIMANV committed Sep 24, 2024
1 parent 18449f1 commit e70c0c6
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
4 changes: 2 additions & 2 deletions database-cleanup/database_cleanup/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
traces_sample_rate=1
)

sentry_sdk.set_tag("app_name", "pv-site-production")
sentry_sdk.set_tag("version", pvsite_datamodel.__version__)
sentry_sdk.set_tag("app_name", "pv-site-production_database_cleanup")
sentry_sdk.set_tag("version", pv_site_api.__version__)



Expand Down
10 changes: 10 additions & 0 deletions forecast-inference/forecast_inference/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import os
import pathlib
from uuid import UUID
import sentry_sdk

import click
import dotenv
Expand All @@ -23,6 +24,15 @@

_log = logging.getLogger(__name__)

sentry_sdk.init(
dsn=os.getenv("SENTRY_DSN"),
environment=os.getenv("ENVIRONMENT", "local"),
traces_sample_rate=1
)

sentry_sdk.set_tag("app_name", "pv-site-production_forecast_inferance")
sentry_sdk.set_tag("version", pv_site_api.__version__)


def _run_model_and_save_for_one_pv(
database_connection: DatabaseConnection,
Expand Down
2 changes: 1 addition & 1 deletion forecast-inference/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ python-dotenv = "^0.21.1"
sqlalchemy = ">=2.0"
pv-site-prediction = ">=0.1.19"
pvsite-datamodel = "^1.0.28"

sentry-sdk = "^2.1.1"

[tool.poetry.group.dev.dependencies]
pytest-cov = "^4.0.0"
Expand Down

0 comments on commit e70c0c6

Please sign in to comment.