mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-03-12 13:54:07 +00:00
port address level computation to Python
Also adds simple tests for correct table creation.
This commit is contained in:
@@ -24,6 +24,13 @@ class Configuration:
|
||||
if project_dir is not None:
|
||||
self._config.update(dotenv_values(str((project_dir / '.env').resolve())))
|
||||
|
||||
# Add defaults for variables that are left empty to set the default.
|
||||
# They may still be overwritten by environment variables.
|
||||
if not self._config['NOMINATIM_ADDRESS_LEVEL_CONFIG']:
|
||||
self._config['NOMINATIM_ADDRESS_LEVEL_CONFIG'] = \
|
||||
str(config_dir / 'address-levels.json')
|
||||
|
||||
|
||||
def __getattr__(self, name):
|
||||
name = 'NOMINATIM_' + name
|
||||
|
||||
|
||||
Reference in New Issue
Block a user