feat(geo): extract country from geo locations and add world map#822
Open
vcnainala wants to merge 6 commits into
Open
feat(geo): extract country from geo locations and add world map#822vcnainala wants to merge 6 commits into
vcnainala wants to merge 6 commits into
Conversation
Relax unique-name validation in the request-changes organism repeater so users can link organisms that already exist in the database. Reject names already attached to the target molecule instead. Fixes #772
Align Filament v4 Select option keys with stored state for existing synonyms, CAS, geo locations, organisms, and citations. Resolve the target molecule from form state and report records so options remain valid on Livewire submit requests. Fixes #775
Use explicit null checks for molecule synonyms/CAS options and remove unreachable is_string handling for mol_ids array cast.
Introduce rule-based country parsing from geo location names with Nominatim fallback, backed by config-driven aliases and unit tests. Refs #695
Centralize geo location creation in GeoLocationService and add coconut:enrich-geo-locations for backfilling country metadata. Refs #695
Add a public /globe page with country-level molecule, organism, and geo-location stats using globe.gl choropleth visualization. Refs #695
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## development #822 +/- ##
================================================
+ Coverage 6.13% 7.93% +1.79%
- Complexity 1737 1831 +94
================================================
Files 227 234 +7
Lines 8961 9276 +315
================================================
+ Hits 550 736 +186
- Misses 8411 8540 +129 ☔ View full report in Codecov by Harness. 🚀 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.
Summary
geo_locations.namewith configurable aliases, Mexican state heuristics, and Nominatim geocoding fallbackGeoLocationServiceand enrich country metadata during importscoconut:enrich-geo-locationsartisan command for backfilling existing records/globechoropleth page visualizing molecule, organism, and geo-location counts by countryCloses #695
Implementation notes
rinvex/countries(already in the project) for ISO codes and flag emojiTest plan
./vendor/bin/sail test tests/Unit/GeoLocationCountryExtractorTest.php tests/Unit/NominatimGeocoderTest.php./vendor/bin/sail artisan coconut:enrich-geo-locations --dry-run --rules-only./vendor/bin/sail artisan coconut:enrich-geo-locations --rules-only/globeand verify choropleth, metric toggles, and hover panelcountry_codeviaGeoLocationService