Sarah Hoffmann
93d5be097a
bdd: do not expect legacy word table to be without empty tokens
...
It can happen for bogus names and this will not get fixed anymore.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
6eb9044353
adapt search algorithm to new postcode format in word
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
612d34930b
handle postcodes properly on word table updates
...
update_postcodes_from_db() needs to do the full postcode treatment
in order to derive the correct word table entries.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
5be320368c
add documentation for postcode customization
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
7f2ad4ac7e
fix linting issue
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
0f00f4968c
fix up BDD tests for postcode changes
...
Includes smaller code fixes found by the tests.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
37b2c6a830
port legacy tokenizer to new postcode handling
...
Also documents the changes to the SQL functions of the tokenizer.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
e86db3001f
fix postcode pattern for Mozambique
...
Optional groups are not implemented yet.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
7b6ec4fc6c
add tests for discarding bad postcodes
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
67dfa38e60
fix liniting problems
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
2eca9fc8af
cache postcode normalization
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
b5e5efc131
only add well-formatted postcodes to location table
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
80ea13437d
move postcode matcher in a separate file
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
bf86b45178
move postcode centroid computation to Python
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
4885fdf0f9
add class for online centroid computation
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
b7704833e4
icu: switch postcodes to using the pre-formatted one
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
ca7b46511d
introduce and use analyzer for postcodes
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
18864afa8a
postcodes: introduce a default pattern for countries without postcodes
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
5ba75df507
postcode: generate a generic form
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
9cf700e85d
add postcodes for most of the remaining countries
...
Now includes all postcodes that have optional parts.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
9172696324
postcodes: add support for optional spaces
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
49626ba709
add postcode formats with optional country code
...
If the country code is not part of the mandatory output, the
country code filter will do the correct handling.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
baee6f3de0
postcodes: strip leading country codes
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
28ab2f6048
add postcodes patterns without optional spaces
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
90d4d339db
initial postcode cleaner for simple patterns
...
Moves postcodes that are either in countries without a postcode
system or don't correspond to the local pattern for postcodes into
a field for a normal address part. Makes them searchable but not as
a special address. This has two consequences: they are no longer a
skippable part of the address and the postcodes cannot be searched
on their own.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
6e0014e138
add postcode patterns for numeric postcodes
...
Adds patterns for countries that have simple numeric-only postcodes.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
8080625747
remove postcodes from countries that don't have them
...
The postcodes will only be removed as a 'computed postcode' they
are still searchable for the given object.
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
21fb501699
add info about countries without a postcode
2022-06-23 23:42:31 +02:00
Sarah Hoffmann
0cd3a1b9bd
avoid near searches in very large areas
...
At some point the contains call becomes too expensive.
2022-06-23 23:42:09 +02:00
Sarah Hoffmann
8de483a45b
Merge pull request #2755 from Luflosi/fix-typo
...
Fix typo
2022-06-20 22:23:36 +02:00
Luflosi
3ea87169ac
Fix typo
2022-06-20 20:41:00 +02:00
Sarah Hoffmann
42d16d8296
Merge pull request #2751 from mtmail/issue-2750
...
Documentation fix: should be "nominatim refresh"
2022-06-20 10:21:06 +02:00
marc tobias
adf3ae004f
Documentation fix: should be "nominatim refresh"
2022-06-20 02:32:23 +02:00
Sarah Hoffmann
fced1172c4
Merge pull request #2746 from bgo-eiu/patch-2
...
Added additional languages for Pakistan in country settings
2022-06-18 09:40:47 +02:00
Sarah Hoffmann
299e98776e
Merge pull request #2749 from stefkiourk/patch-1
...
Typos and syntax on Reverse.md
2022-06-17 22:11:55 +02:00
Stef Ki
b803505402
Typos and syntax on Reverse.md
2022-06-17 21:01:38 +02:00
Sarah Hoffmann
8fb9795d04
Merge pull request #2748 from lonvia/bdd-grid-origin
...
BDD tests: remove support for scenes
2022-06-17 15:25:29 +02:00
Sarah Hoffmann
d8623d6818
bdd: remove support for scenes
...
Only keep support for the special point geometry 'country:xx'.
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
6c58a4c46c
bdd: move query tests from scene to grid description
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
19f67e167c
bdd: remove step for scene setup
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
00d8df6fc3
bdd: move update tests from scenes to grid descriptions
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
02068aec7f
bdd: move import tests from scenes to grid descriptions
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
3493d317e4
bdd: clear lof buffer after a successful import run
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
a2b486a5b0
bdd: allow to set an origin of the grid
2022-06-17 11:54:18 +02:00
Sarah Hoffmann
3d0f8bdc39
Merge pull request #2745 from lonvia/city-in-city-fix
...
Improve hierarchy computation for place areas
2022-06-16 15:36:39 +02:00
bgo-eiu
04644102f2
added additional languages for pakistan in country settings
2022-06-16 06:26:44 -04:00
Sarah Hoffmann
f833cc80df
use default ranks when reorganising rank_address
...
When shifting address ranks, the evaluation is always done against
unshifted address ranks on import because the objects we compare against
have not been indexed yet. This changes for updates when the object have
been touched in the meantime. To ensure consistent behaviour across
imports and updates, always use the unshifted address ranks.
2022-06-16 11:20:23 +02:00
Sarah Hoffmann
df0142678a
improve address ordering with mixes of place and admin areas
...
Resolves a couple of situations where a mixed use of places areas and
administrative boundaries would result in a hierarchy that did not
properly respect the contains relation.
2022-06-16 10:44:16 +02:00
Sarah Hoffmann
800240550b
Merge pull request #2737 from lonvia/reset-linking-ranks
...
Fix rank inheritance from linked places
2022-06-06 09:29:32 +02:00
Sarah Hoffmann
15cf7dd416
add testcase for #2551
...
This test proves that places that are linked need to be reindexed.
2022-06-05 21:39:17 +02:00