Skip to content

Commit

Permalink
[HOTFIX] Alterar constante materialização ordem pagamento validação /…
Browse files Browse the repository at this point in the history
… corrigir verificação de tipo daterange materialização (#555)

* alterar nome da coluna date

* corrigir bug date_range
  • Loading branch information
pixuimpou authored Nov 9, 2023
1 parent ae01c67 commit 11b8878
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pipelines/rj_smtr/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ class constants(Enum): # pylint: disable=c0103
"exclude": f"+{BILHETAGEM_MATERIALIZACAO_TRANSACAO_PARAMS['table_id']}",
"dbt_vars": {
"date_range": {
"table_run_datetime_column_name": "data",
"table_run_datetime_column_name": "data_ordem",
"delay_hours": 0,
},
"version": {},
Expand Down
2 changes: 1 addition & 1 deletion pipelines/rj_smtr/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -1088,7 +1088,7 @@ def get_materialization_date_range( # pylint: disable=R0913
else:
last_run = datetime.strptime(last_run, timestr)

if isinstance(last_run, date):
if (not isinstance(last_run, datetime)) and (isinstance(last_run, date)):
last_run = datetime(last_run.year, last_run.month, last_run.day)

# set start to last run hour (H)
Expand Down

0 comments on commit 11b8878

Please sign in to comment.