Repository navigation
Switch to using new materialized tables for Athena queries and ignore Positron config files - #152
Merged
jeancochrane merged 4 commits intoDec 9, 2025
Conversation
jeancochrane
marked this pull request as ready for review
December 9, 2025 18:41
wagnerlmichael
approved these changes
Dec 9, 2025
jeancochrane
deleted the
jeancochrane/140-reduce-resource-use-of-athena-queries-in-report-generation-script
branch
December 9, 2025 23:16
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR updates the HomeVal report generation script to match the changes we made in ccao-data/data-architecture#936, which tweaked the materialization for the HomeVal data tables in our Athena data lake, and in the process renamed the tables to remove the
vw_prefix that we use to mark Athena views.Luckily, we factored out the table names to a centralized constants module in #141, so changing the
generate_homeval.pyscript is very simple. In addition updating the constant variables, we only need to tweak one comment and the analytics dashboard script, which is a separate R project and so doesn't use the constants file. The only tricky part of the change is that we have to alter one small part of thegenerate_homeval.pycode where we previously assumed that all columns starting withshap_*represented numeric SHAP values, an assumption that breaks down now that we includeshap_run_idas a column in thepinval.assessment_cardtable.Since I was messing around with the Positron/VSCode Python debugger while debugging the
shap_run_idissue, I also took a minute to fold in a quick tweak to the.gitignorefile for the project to ignore all local VSCode config files. This was relevant because I created alaunch.jsonconfig file in order to debug thegenerate_homeval.pyscript execution.See here for a
generate-homevalworkflow run that deploys a sample PIN (01011000040000) to the staging site: https://github.com/ccao-data/homeval/actions/runs/20070650417I also reran the analytics dashboard locally and it worked as expected.
Evidence that these are the only blocks of code across all of our repos that reference the HomeVal Athena models: https://github.com/search?q=org%3Accao-data%20pinval.vw_&type=code