LewisDavies / upstream-prod

A dbt package for easily using production data in a development environment.
32 stars 4 forks source link

Dict object has no attribute `file_key_name` on Singular tests #29

Open alittlesliceoftom opened 7 months ago

alittlesliceoftom commented 7 months ago
image

Fairly confident that this is only an issue on 'singular data tests' configured in the tests/ folder.

I assume this is because the file is not directly referenced.

Doesn't happen in targets where upstream prod disabled.

upstream-prod Version 0.5.1

DBT: Core:

Plugins:

LewisDavies commented 7 months ago

Just spotted this after replying to your other issue. This explains the both errors - file_key_name isn't available for singular tests, so the package breaks when trying to redirect them to prod. This will happen for any dbt command.

It would be great if you're able to try the fix recommended in #23 - if that works I could probably backport the changes and release a new official version soon.