* [ ] increase versions in
* `src/nominatim_api/version.py`
* `src/nominatim_db/version.py`
- * CMakeLists.txt
* [ ] update `ChangeLog` (copy information from patch releases from release branch)
* [ ] complete `docs/admin/Migration.md`
* [ ] update EOL dates in `SECURITY.md`
+5.0.0
+ * increase required versions for PostgreSQL (12+), PostGIS (3.0+)
+ * remove installation via cmake and debundle osm2pgsql
+ * remove deprecated PHP frontend
+ * remove deprecated legacy tokenizer
+ * add configurable pre-processing of queries
+ * add query pre-processor to split up Japanese addresses
+ * rewrite of osm2pgsql style implementation
+ (also adds support for osm2pgsql-themepark)
+ * reduce the number of SQL queries needed to complete a 'lookup' call
+ * improve computation of centroid for lines with only two points
+ * improve bbox output for postcode areas
+ * improve result order by returning the largest object when other things are
+ equal
+ * add fallback for reverse geocoding to default country tables
+ * exclude postcode areas from reverse geocoding
+ * disable search endpoint when database is reverse-only (regression)
+ * minor performance improvements to area split algorithm
+ * switch table and index creation to use autocommit mode to avoid deadlocks
+ * drop overly long ways during import
+ * restrict automatic migrations to versions 4.3+
+ * switch linting from pylint to flake8
+ * switch tests to use a wikimedia test file in the new CSV style
+ * various fixes and improvements to documentation
+
4.5.0
* allow building Nominatim as a pip package
* make osm2pgsql building optional
| Version | End of support for security updates |
| ------- | ----------------------------------- |
+| 5.0.x | 2027-02-06
| 4.5.x | 2026-09-12 |
| 4.4.x | 2026-03-07 |
| 4.3.x | 2025-09-07 |
-| 4.2.x | 2024-11-24 |
## Reporting a Vulnerability
* Update the frontend: `pip install -U nominatim-api`
* (optionally) Restart updates
-If you are still using CMake for the installation of Nominatim, then you
-need to update the software in one step before migrating the database.
-It is not recommended to do this while the machine is serving requests.
-
Below you find additional migrations and hints about other structural and
breaking changes. **Please read them before running the migration.**
!!! note
If you are migrating from a version <4.3, you need to install 4.3
- first and migrate to 4.3 first. Then you can migrate to the current
+ and migrate to 4.3 first. Then you can migrate to the current
version. It is strongly recommended to do a reimport instead.
-## 4.5.0 -> master
+## 4.5.0 -> 5.0.0
### PHP frontend removed
removed in later versions of Nominatim. So make sure you remove it from your
scripts.
+### CMake building removed
+
+Nominatim can now only be installed via pip. Please follow the installation
+instructions for the current version to change to pip.
+
+### osm2pgsql no longer vendored in
+
+Nominatim no longer ships its own version of osm2pgsql. Please install a
+stock version of osm2pgsql from your distribution. See the
+[installation instruction for osm2pgsql](https://osm2pgsql.org/doc/install.html)
+for details. A minimum version of 1.8 is required. The current stable versions
+of Ubuntu and Debian already ship with an appropriate versions. For older
+installation, you may have to compile a newer osm2pgsql yourself.
+
+### Legacy tokenizer removed
+
+The `legacy` tokenizer is no longer enabled. This tokenizer has been superseded
+by the `ICU` tokenizer a long time ago. In the unlikely case that your database
+still uses the `legacy` tokenizer, you must reimport your database.
+
+### osm2pgsql style overhauled
+
+There are some fundamental changes to how customized osm2pgsql styles should
+be written. The changes are mostly backwards compatible, i.e. custom styles
+should still work with the new implementation. The only exception is a
+customization of the `process_tags()` function. This function is no longer
+considered public and neither are the helper functions used in it.
+They currently still work but will be removed at some point. If you have
+been making changes to `process_tags`, please review your style and try
+to switch to the new convenience functions.
+
+For more information on the changes, see the
+[pull request](https://github.com/osm-search/Nominatim/pull/3615)
+and read the new
+[customization documentation](https://nominatim.org/release-docs/latest/customize/Import-Styles/).
+
## 4.4.0 -> 4.5.0
### New structure for Python packages
Version information for the Nominatim API.
"""
-NOMINATIM_API_VERSION = '4.5.0'
+NOMINATIM_API_VERSION = '5.0.0'
return NominatimVersion(*[int(x) for x in parts[:2] + parts[2].split('-')])
-NOMINATIM_VERSION = parse_version('4.5.0-0')
+NOMINATIM_VERSION = parse_version('5.0.0-0')
POSTGRESQL_REQUIRED_VERSION = (12, 0)
POSTGIS_REQUIRED_VERSION = (3, 0)
def test_refresh_import_secondary_importance_testdb(dsn, src_dir, temp_db_conn, temp_db_cursor):
temp_db_cursor.execute('CREATE EXTENSION postgis')
+ temp_db_cursor.execute('CREATE EXTENSION postgis_raster')
+ assert refresh.import_secondary_importance(dsn, src_dir / 'test' / 'testdb') == 0
- if postgis_version_tuple(temp_db_conn)[0] < 3:
- assert refresh.import_secondary_importance(dsn, src_dir / 'test' / 'testdb') > 0
- else:
- temp_db_cursor.execute('CREATE EXTENSION postgis_raster')
- assert refresh.import_secondary_importance(dsn, src_dir / 'test' / 'testdb') == 0
-
- assert temp_db_cursor.table_exists('secondary_importance')
+ assert temp_db_cursor.table_exists('secondary_importance')
@pytest.mark.parametrize("replace", (True, False))
# use the small wikipedia file for the API testdb
assert refresh.import_wikipedia_articles(dsn, src_dir / 'test' / 'testdb') == 0
- assert temp_db_cursor.table_rows('wikipedia_article') > 0
- assert temp_db_cursor.table_rows('wikipedia_redirect') > 0
+ assert temp_db_cursor.table_rows('wikimedia_importance') > 0
def test_recompute_importance(placex_table, table_factory, temp_db_conn, temp_db_cursor):