]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge pull request #1758 from krahulreddy/advanced-installations
authorSarah Hoffmann <lonvia@denofr.de>
Wed, 22 Apr 2020 07:59:44 +0000 (09:59 +0200)
committerGitHub <noreply@github.com>
Wed, 22 Apr 2020 07:59:44 +0000 (09:59 +0200)
Advanced installations

VAGRANT.md
docs/api/Search.md
lib/ClassTypes.php
nominatim/nominatim.py
settings/address-levels.json
test/bdd/api/reverse/addressdetails.feature [new file with mode: 0644]
utils/update.php

index 0cab24faa26250836bb12f1ff24697478d76d22d..4c8eb724e5fbad5c227b2aad111562cae22db1e7 100644 (file)
@@ -141,7 +141,7 @@ No. Long running Nominatim installations will differ once new import features (o
 bug fixes) get added since those usually only get applied to new/changed data.
 
 Also this document skips the optional Wikipedia data import which affects ranking
-of search results. See [Nominatim installation](http://nominatim.org/release-docs/latest/Installation) for details.
+of search results. See [Nominatim installation](https://nominatim.org/release-docs/latest/admin/Installation) for details.
 
 ##### Why Ubuntu? Can I test CentOS/Fedora/CoreOS/FreeBSD?
 
index 688d7e0c522f04eb93210677be09c0b2b2c20047..c18655dcc03f570b866af1d94ed5d049423db633 100644 (file)
@@ -92,8 +92,12 @@ comma-separated list of language codes.
 * `countrycodes=<countrycode>[,<countrycode>][,<countrycode>]...`
 
 Limit search results to one or more countries. `<countrycode>` must be the
-ISO 3166-1alpha2 code, e.g. `gb` for the United Kingdom, `de` for Germany.
+[ISO 3166-1alpha2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) code,
+e.g. `gb` for the United Kingdom, `de` for Germany.
 
+Each place in Nominatim is assigned to one country code based
+on `admin_level=2` tags, in rare cases to none (for example in
+international waters outside any country).
 
 * `exclude_place_ids=<place_id,[place_id],[place_id]`
 
index 60f18d959aca35252d6851529da36cb0f4991cb3..a7c2cd4f8e25159d1d9a15a31d76511ef55202ab 100644 (file)
@@ -268,7 +268,7 @@ function getList()
             'tourism:caravan_site' => array('label' => 'Caravan Site', 'frequency' => 183, 'icon' => 'accommodation_caravan_park'),
             'amenity:bus_station' => array('label' => 'Bus Station', 'frequency' => 181, 'icon' => 'transport_bus_station'),
             'amenity:kindergarten' => array('label' => 'Kindergarten', 'frequency' => 179),
-            'highway:construction' => array('label' => 'Construction', 'frequency' => 176),
+            'highway:construction' => array('label' => 'Construction', 'frequency' => 176, 'simplelabel' => 'road'),
             'amenity:atm' => array('label' => 'Atm', 'frequency' => 172, 'icon' => 'money_atm2'),
             'amenity:emergency_phone' => array('label' => 'Emergency Phone', 'frequency' => 164),
             'waterway:lock' => array('label' => 'Lock', 'frequency' => 146),
index 14643770a6642662be283b0d21b3d36b556ac407..0db0777dc17d20b87413a2bf55d08432dc55de24 100755 (executable)
@@ -304,7 +304,7 @@ class Indexer(object):
             else:
                 ready, _, _ = select.select(self.threads, [], [])
 
-        assert(False, "Unreachable code")
+        assert False, "Unreachable code"
 
 
 def nominatim_arg_parser():
index 9f32fc985696cc96cc593ec4752eb4a1b8d056bf..10cbf307464f46aeb0ef255614e8afedeeafc27b 100644 (file)
           "sea" : [4, 0]
       },
       "waterway" : {
-          "" : [17, 0]
+          "river" : [19, 0],
+          "stream" : [22, 0],
+          "ditch" : [22, 0],
+          "drain" : [22, 0],
+          "" : [20, 0]
       },
       "highway" : {
           "" : 26,
diff --git a/test/bdd/api/reverse/addressdetails.feature b/test/bdd/api/reverse/addressdetails.feature
new file mode 100644 (file)
index 0000000..5aa3846
--- /dev/null
@@ -0,0 +1,10 @@
+@APIDB
+Feature: Reverse addressdetails
+    Tests for addressdetails in reverse queries
+
+    #github #1763
+    Scenario: Correct translation of highways under construction
+        When sending jsonv2 reverse coordinates -34.0290514,-53.5832235
+        Then result addresses contain
+        | road |
+        | Ruta 9 Coronel Leonardo Olivera |
index c1dc2ab938c33886cf5cb8be6cd39b1b2c857e54..6965cd57e2dbceed20ee00a8b9edcd1f5d2076c3 100644 (file)
@@ -354,7 +354,7 @@ if ($aResult['import-osmosis'] || $aResult['import-osmosis-all']) {
     //
     if (strpos(CONST_Replication_Url, 'download.geofabrik.de') !== false && CONST_Replication_Update_Interval < 86400) {
         fail('Error: Update interval too low for download.geofabrik.de. ' .
-             "Please check install documentation (http://nominatim.org/release-docs/latest/Import-and-Update#setting-up-the-update-process)\n");
+             "Please check install documentation (https://nominatim.org/release-docs/latest/admin/Import-and-Update#setting-up-the-update-process)\n");
     }
 
     $sImportFile = CONST_InstallPath.'/osmosischange.osc';