Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Execute Query" caches too much about the state of the project and doesn't realize when external issues have been fixed #1453

Open
1 task done
rmargarint-nydig opened this issue Oct 8, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@rmargarint-nydig
Copy link

Expected behavior

When I hit Execute Query, and there is a bug in the DBT project outside of that query, the query will fail as expected. Eg "Some other model has a ref on a model that doesn't exist". All as expected. But then you go and you fix that issue, come back to the query you were were trying to run, tell it to execute again, Power DBT seems to not realize that I fixed the underlying issue. Sometimes it will take several seconds, or forever until it realizes that and decides to actually rererun the whole query again.

Actual behavior

Every time I hit execute query it should just try to execute the query.

Steps To Reproduce

  • create model A

  • create model B, that has a ref on model A

  • create model C, make all valid sqls (model C has no need for refs on anything)

  • try to execute model C, see all good

  • go to model B, make that ref be on model foobar (nonexistent) instead of model A

  • go back to model C try to execute SQL. (It will fail because model B has a non existent ref, kinda weird since model C doesn't care aabout model, but ok)

  • go and just straight up delete the model B file, the graph should all be good.

  • go back to model C. Tell it to execute query. It will continue to keep saying model B has a failure, even though model B doesn't even exist anymore. It will stay in this state until you restart VSCode.

Log output/Screenshots

No response

Operating System

mac

dbt version

1.8

dbt Adapter

snowflake

dbt Power User version

latest

Are you willing to submit PR?

  • Yes I am willing to submit a PR!
@rmargarint-nydig rmargarint-nydig added the bug Something isn't working label Oct 8, 2024
@kacarmichael
Copy link

I've run into this issue many times. Some sort of way to clear whatever underlying cache is being used or to force a rescan/recompile of the full dbt project would be useful.

@AWaleczek
Copy link

I think that might be related to my issue.
I installed a package and with the next build it built all the tables in the package.
Then I decided to remove the package again.
When building the project through Power Tools, the tables from the deleted package are still being built. When running "dbt build" through the terminal, those tables are not being build, as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants