Postgres port set as string in profiles.yml
jannekeskitalo opened this issue · comments
Version 0.3.0 creates an invalid dbt profile for postgres. Port value in the target config is set as string which fails dbt cli run. Profile is correct with version 0.2.7.
Example from invalid profile:
port: '5432'
Should be:
port: 5432
I'm using following function to run DBT commands:
def dbt_command(
dbt_project_name: str,
dbt_project_dir: str,
database_credentials: DatabaseCredentials,
command: str,
threads=1,
):
dbt_cli_profile = DbtCliProfile(
name=dbt_project_name,
target="dbt-runner-database",
target_configs=PostgresTargetConfigs(
credentials=database_credentials, schema="public", threads=threads
),
)
result = trigger_dbt_cli_command(
command,
profiles_dir=".",
project_dir=dbt_project_dir,
overwrite_profiles=True,
dbt_cli_profile=dbt_cli_profile,
)
return result