Hello all! When creating new tests / running local...
# community-support
r
Hello all! When creating new tests / running locally, how can I see what exactly the failures are? e.g. I added a new test and it's returning 3 failures. It gives the link to the compiled code. But if I run that compiled code, it fails -- it uses a temp table that has already been deleted, and refers to that temp table. I tried edr report, but that comes back empty -- "no test results" What is the recommended way to debug test failures? Thanks!
The edr report is failing because:
Copy code
2024-01-24 08:39:32 — ERROR — Could not generate the report - Error: Failed to run dbt command.
Encountered an error while running operation: Runtime Error
  404 Not found: Table REDACTED_PROJECT_ID:sandbox_dbt_transform_monitor.dbt_exposures was not found in location us-east4

  Location: us-east4
  Job ID: -------

Please reach out to our community for help with this issue.
NoneType: None
I think it's that I need to use
--profile-target
on the edr report for the local run. I'm still going to poke at how I can run the code to see better what's going on; for this stage of the process we are tweaking the parameters to ensure it's checking what we think it's checking, so it's helpful to be able to run the SQL and look at output of the various stages.
n
Hey @Renee Cooper You mentioned here a few different things: •
can I see what exactly the failures are?
◦ In the dbt project, you can set
test_sample_row_count
var (by default should save 4) to save information on X rows that failed. Then you will be able to see this is the report as well (in test results). • edr report error ◦ did you manage to solve the issue? This may be an issue with the profile as you mentioned. • it’s helpful to be able to run the SQL ◦ You won’t be able to do it In case of tests that are using temp tables to calculate the results. The reason is storage - the calculations generate a lot of data.
thankyou 1