Madrid air quality & weather pipeline
Does the weather drive air pollution in Madrid? A daily ELT pipeline that joins hourly readings from Madrid’s 24 air-quality stations with Open-Meteo weather for each station: about 3 million hourly measurements since January 2024, published as a live dashboard.
Python extractors land raw files untouched; dbt models them on DuckDB; Airflow (with Cosmos, one task per dbt model) runs it all in Docker. 72 automated tests run in CI on every push, including dbt unit tests for the missing and repeated hours of daylight-saving changes. Every non-obvious choice is written down in 34 design decisions.
One finding: on weekdays NO₂ peaks around 8:00 and 21:00, and the morning peak mostly disappears at weekends — the traffic signature.
Live dashboard Code Design decisions