[BUGFIX] Process US regions without border countries - #297
Conversation
|
Maybe you can help @Mirochill ... even with your fix, why does this work: python -m wahoomc cli -nbc -v -co "us/texas"but this doesn't: python -m wahoomc cli -nbc -v -co "canada/ontario"I get the error:
Is the US the only region that can be filtered by subregion? |
|
Nevermind ... |
Local test resultTested PR #297 in isolation on branch Test run: 9/10 pass. The one failure ( The fix itself ( |
Follow-up fix pushed:
|
calc_border_countries already replaced '/' with '_' for the -nbc path, but calc_country_name still used raw wanted_maps entries, meaning inputs like 'us/texas' would produce a country_name of 'us/texas' and break output folder creation. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
060c5b2 to
f490f60
Compare
|
thanks for your PR @Mirochill |
This PR...
-nbccountry runs for Geofabrik IDs likeus/texasaligned with the tile names generated byCountryGeofabrik.us/texasso no-border processing usesus_texas, matching the split tile filenames.Considerations and implementations
When border-country processing is disabled,
CountryOsmDatapreviously kept the raw wanted map id inborder_countries. For US regions this meantus/texas, whileCountryGeofabrik.find_needed_countries()normalizes tile country names tous_texas. The later split and merge stages compare those names, so no country split files were added to the Osmosis merge command.This normalizes the no-border country key in the same way as the tile list and downloaded map filenames.
Fixes #288
How to test
git diff --checkPull Request Checklist