Skip to content

Commit

Permalink
DAGSTER_PG to BAG3D_PG in tiles.py
Browse files Browse the repository at this point in the history
  • Loading branch information
GinaStavropoulou committed Aug 5, 2024
1 parent 6ab6f6e commit ec85398
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions packages/core/src/bag3d/core/assets/input/tile.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,16 +72,16 @@ def get_tile_ids(schema: str, table_tiles: str, logger, wkt: str = None):
query = SQL(f"select tile_id from {schema}.{table_tiles}")
try:
conn = PostgresConnection(
port=int(os.environ.get("DAGSTER_DB_CONNECTION_PORT", 5432)),
user=os.environ.get("DAGSTER_DB_CONNECTION_USER"),
password=os.environ.get("DAGSTER_DB_CONNECTION_PASSWORD"),
dbname=os.environ.get("DAGSTER_DB_CONNECTION_DBNAME"),
host=os.environ.get("DAGSTER_DB_CONNECTION_HOST"),
port=int(os.environ.get("BAG3D_PG_PORT", 5432)),
user=os.environ.get("BAG3D_PG_USER"),
password=os.environ.get("BAG3D_PG_PASSWORD"),
dbname=os.environ.get("BAG3D_PG_DATABASE"),
host=os.environ.get("BAG3D_PG_HOST"),
)
tile_ids = [row[0] for row in conn.get_query(query)]
except OperationalError:
logger.error(
f"cannot establish database connection from the environment variables DAGSTER_DB_*")
f"cannot establish database connection from the environment variables BAG3D_PG_*")
tile_ids = []
except UndefinedTable:
logger.error(f"tiles table {schema}.{table_tiles} does not exist")
Expand Down

0 comments on commit ec85398

Please sign in to comment.