feat(farmer_demo): seed large commercial farm with idle land for CEL demo (#1119)#323
Open
emjay0921 wants to merge 1 commit into
Open
feat(farmer_demo): seed large commercial farm with idle land for CEL demo (#1119)#323emjay0921 wants to merge 1 commit into
emjay0921 wants to merge 1 commit into
Conversation
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 19.0 #323 +/- ##
==========================================
- Coverage 74.28% 66.77% -7.51%
==========================================
Files 372 100 -272
Lines 25385 9794 -15591
==========================================
- Hits 18857 6540 -12317
+ Misses 6528 3254 -3274
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
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.
Why is this change needed?
Docs Scenario 5 (Climate Resilience) STEP 4 contrasts the qualifying smallholder against EC1 — a large commercial farm (50 ha, idle) to show the CEL
r.is_group == true and is_smallholder and farm_size_idle > 0rejecting it onis_smallholdereven though it has idle land. No demo farm had bothis_smallholder = False(size above the 5 ha threshold) andfarm_size_idle > 0, so this exclusion couldn't be demonstrated (OP#1119).How was the change implemented?
bp_22_ec1_large_commercial_idletoFARMER_BLUEPRINTS: a 50 ha crop farm (count: 1) withidle_pct: 0.1(≈5 ha fallow) and all program eligibilityFalse(it's the deliberate rejection example). 50 ha > 5 ha threshold ⇒is_smallholder = False, andfarm_size_idle > 0.idle_pct, so no generator changes were needed. EC1 is volume-generated, matching the docs (USE_CASES Story 9 / EC1).New unit tests
test_1119_ec1_large_commercial_not_smallholder_with_idle— generates the EC1 blueprint and assertsfarm_total_size> smallholder threshold,is_smallholder == False, andfarm_size_idle > 0.Unit tests executed by the author
spp_farmer_registry_demosuite: 0 failed, 0 error(s) of 133 tests (fresh DB,--stop-after-init). The~730farm-count range tests remain green with the +1 farm.How to test manually
is_smallholder), while a smallholder with idle land qualifies.Related links
https://projects.acn.fr/work_packages/1119