Skip to content

Conversation

@rhunwicks
Copy link
Contributor

No description provided.

@rhunwicks rhunwicks self-assigned this Oct 15, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR relaxes data completeness constraints in the HEA database development pipeline by introducing a configurable strictness mode and updating the Python target version to 3.12.

  • Adds configurable strict mode to handle validation errors as warnings instead of exceptions when strictness is disabled
  • Updates Python target version from 3.10 to 3.12 across configuration files
  • Refactors asset functions to use consistent return patterns and improved error handling

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
pyproject.toml Updates Python version requirements and tool configurations to target Python 3.12
pipelines_tests/test_assets/test_livelihood_activity_regexes.json Adds new test cases for wild food and fish gathering activities
pipelines/assets/wild_foods.py Refactors asset functions to use config parameter and simplified return patterns
pipelines/assets/wealth_characteristic.py Updates validation function call to include config parameter
pipelines/assets/other_cash_income.py Refactors asset functions similar to wild_foods.py with config support
pipelines/assets/livelihood_activity_regexes.json Adds new regex patterns for wild food and fish gathering with numeric support
pipelines/assets/livelihood_activity.py Major refactoring to support configurable strictness and improved error handling
pipelines/assets/fixtures.py Complete rewrite of validation logic to support per-instance validation and configurable strictness

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

record_reference += f"{instance['bss_column']}:{instance['bss_column']}: "
elif "bss_row" in instance:
record_reference += f"{instance['bss_row']}:{instance['bss_row']}: "
record_reference += f"{str({k: v for k,v in instance.items()})}"
Copy link

Copilot AI Oct 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The dictionary comprehension and str() conversion creates verbose error messages. Consider limiting the keys shown or formatting the output more readably.

Copilot uses AI. Check for mistakes.
@FEWS-NET FEWS-NET deleted a comment from Copilot AI Oct 15, 2025
@FEWS-NET FEWS-NET deleted a comment from Copilot AI Oct 15, 2025
@FEWS-NET FEWS-NET deleted a comment from Copilot AI Oct 15, 2025
@rhunwicks rhunwicks merged commit 73eace5 into main Oct 15, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants