Skip to content

Conversation

@MichelleArk
Copy link
Contributor

@MichelleArk MichelleArk commented Feb 8, 2023

Resolves: #6957

Fixes log_path setting in flags to respect project_dir, if available

On before_click_merge branch

❯ dbt run --project-dir ~/src/jaffle_shop
...
❯ ls logs
ls: logs: No such file or directory
❯ ls ~/src/jaffle_shop/logs
dbt.log

currently, on main

❯ dbt run --project-dir ~/src/jaffle_shop
...
❯ ls logs
dbt.log #bad!
❯ ls ~/src/jaffle_shop/logs
ls: /Users/michelleark/src/jaffle_shop/logs: No such file or directory #also bad!

🎩 after fix:

❯ dbt run --project-dir ~/src/jaffle_shop
...
❯ ls logs
ls: logs: No such file or directory
❯ ls ~/src/jaffle_shop/logs
dbt.log

Description

Checklist

@cla-bot cla-bot bot added the cla:yes label Feb 8, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Feb 8, 2023

Thank you for your pull request! We could not find a changelog entry for this change. For details on how to document a change, see the contributing guide.

@MichelleArk MichelleArk added the Skip Changelog Skips GHA to check for changelog file label Feb 8, 2023
@MichelleArk MichelleArk marked this pull request as ready for review February 8, 2023 20:55
@MichelleArk MichelleArk requested a review from a team as a code owner February 8, 2023 20:55
@MichelleArk MichelleArk requested review from Mathyoub and stu-k February 8, 2023 20:55
@MichelleArk MichelleArk requested a review from gshank February 8, 2023 21:48
@MichelleArk MichelleArk changed the title write logs to test project in test dbt_project.yml log-path respects project directory Feb 9, 2023
@MichelleArk
Copy link
Contributor Author

Removing the fix to tests/functional/partial_parsing/test_pp_vars.py::TestProfileEnvVars in favor of #6916. Scope of this PR is now just the difference in behaviour with log-path between click and legacy cli.

@MichelleArk MichelleArk changed the base branch from feature/click-cli to main February 13, 2023 18:57
Copy link
Contributor

@aranke aranke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, resolved questions offline.

@MichelleArk MichelleArk reopened this Feb 14, 2023
@MichelleArk MichelleArk merged commit e5c468b into main Feb 14, 2023
@MichelleArk MichelleArk deleted the arky/fix-log-path-test branch February 14, 2023 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla:yes regression Skip Changelog Skips GHA to check for changelog file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[CT-2108] [Regression] log path does not respect --project-dir

5 participants