-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix non deterministic facet ranking (#1513)
Update facet ranking to take import name into account because some facets differ by only the import name. This non-deterministic ranking of facets causes flaky NL tests in the website repository because NL chooses the top ranked facet.
- Loading branch information
1 parent
4730ce9
commit 771193a
Showing
3 changed files
with
62 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
54 changes: 54 additions & 0 deletions
54
internal/server/v2/facet/golden/series_facet/series_facet_test_ranking.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{ | ||
"by_variable": { | ||
"Count_Death_AgeAdjusted_AsAFractionOf_Count_Person": { | ||
"by_entity": { | ||
"geoId/01": { | ||
"ordered_facets": [ | ||
{ | ||
"facet_id": "1151455814", | ||
"obs_count": 18, | ||
"earliest_date": "2001", | ||
"latest_date": "2020" | ||
}, | ||
{ | ||
"facet_id": "1123266408", | ||
"obs_count": 18, | ||
"earliest_date": "2001", | ||
"latest_date": "2020" | ||
} | ||
] | ||
}, | ||
"geoId/02": { | ||
"ordered_facets": [ | ||
{ | ||
"facet_id": "1151455814", | ||
"obs_count": 18, | ||
"earliest_date": "2001", | ||
"latest_date": "2020" | ||
}, | ||
{ | ||
"facet_id": "1123266408", | ||
"obs_count": 18, | ||
"earliest_date": "2001", | ||
"latest_date": "2020" | ||
} | ||
] | ||
} | ||
} | ||
} | ||
}, | ||
"facets": { | ||
"1123266408": { | ||
"import_name": "OECDRegionalDemography_Mortality", | ||
"provenance_url": "https://stats.oecd.org/Index.aspx?DataSetCode=REGION_DEMOGR#", | ||
"measurement_method": "OECDRegionalStatistics", | ||
"observation_period": "P1Y" | ||
}, | ||
"1151455814": { | ||
"import_name": "OECDRegionalDemography", | ||
"provenance_url": "https://stats.oecd.org/Index.aspx?DataSetCode=REGION_DEMOGR#", | ||
"measurement_method": "OECDRegionalStatistics", | ||
"observation_period": "P1Y" | ||
} | ||
} | ||
} |
This file contains 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