Comments (4)
Hello,
I confirm this bug which is a bit annoying. When we run models in parallel then we end up with duplicates in the tables.
As workaround I need to run those queries periodically.
create or replace table elementary.dbt_tests as (
select * from elementary.dbt_tests qualify row_number() over (partition by unique_id order by generated_at) = 1
);
create or replace table elementary.dbt_models as (
select * from elementary.dbt_models qualify row_number() over (partition by unique_id order by generated_at) = 1
);
create or replace table elementary.dbt_sources as (
select * from elementary.dbt_sources qualify row_number() over (partition by unique_id order by generated_at) = 1
);
create or replace table elementary.dbt_exposures as (
select * from elementary.dbt_exposures qualify row_number() over (partition by unique_id order by generated_at) = 1
);
create or replace table elementary.dbt_columns as (
select * from elementary.dbt_columns qualify row_number() over (partition by unique_id order by generated_at) = 1
);
from elementary.
Hi @annav00 and @MICHM137 ,
Sorry for the delay in responding here, can you please confirm if this issue is still relevant to you?
Also - which databases are you using?
I'll mark this as high priority on our end.
In the meantime, a workaround you can consider setting the var cache_artifacts = False
- this will force a full replace of the artifacts on every run, which I think should actually prevent duplicates (though it can increase on_run_end duration).
(When caching is enabled we only insert a diff - and I think there's probably a race there)
from elementary.
Hey (it is MICHM137),
I would avoid adding cache_artifacts False because the on_run_end duration takes already a lot of time and make our pipelines way longer than without elementary.
Do you plan optimizing the on_run_end hook?
Thanks for your answer
from elementary.
Hi @mattxxi ,
Yeah makes sense. We implemented the cache due to performance reasons, just pointed out the alternative.
I think the duplicate entries when the cache is enabled results from a race in the delete_and_insert
macro, which we need to fix.
I don't have an immediate time frame for it but I'm guessing we'll prioritize it in the near future.
from elementary.
Related Issues (20)
- Extend test description with anomaly_score and training_stddev HOT 7
- [FEATURE] - Add possibility to alert top n heaviest models from "Model Duration" HOT 1
- Cannot generate observability report HOT 7
- Add project name and environment to slack notification HOT 2
- elementary column anomalies tests fail on redshift with error 'Relation name is longer than 127 characters' HOT 1
- [BUG] Teams alerts spam 5x of the same failure with suppression set. HOT 6
- 0.15 / BigQuery EDR monitor fails HOT 3
- Temporary tables for volume and freshness tests are not properly cleaned on Athena HOT 8
- detection_period propery works wrong HOT 6
- Clicking on dbt tests link from dashboard redirects to tests page but with source freshness NOT excluded HOT 2
- --disable-samples should only hide the results of generic and singular tests, not graphs of freshness or volume tests HOT 1
- Elementary model information_schema_columns fails with error: Unity Catalog is not enabled HOT 1
- `UNRESOLVED_COLUMN` exception when upgrading to elementary 0.15.1 HOT 1
- Getting Redshift syntax errors on volume and column anomaly tests configured without timestamp parameter HOT 2
- Issue on docs: link redirects to main page HOT 1
- detection_delay for volume anomalies tests with month scale HOT 1
- ignore_small_changes on BigQuery
- elementary in combination with sql server throws error
- Add --hours-back CLI option for edr monitor HOT 3
- If you loose connection to redshift the temp table disapears and cannot be loaded. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from elementary.