From: Robbe Haesendonck Date: Mon, 25 Sep 2023 09:14:14 +0000 (+0200) Subject: Fixed ci-tests, osm-file flag X-Git-Tag: v4.4.0~62 X-Git-Url: https://git.openstreetmap.org./nominatim.git/commitdiff_plain/e7b8e1a2c2d82f3f31f033df17adc5d14bbc5374 Fixed ci-tests, osm-file flag Preparing database should work without osm-file --- diff --git a/.github/workflows/ci-tests.yml b/.github/workflows/ci-tests.yml index aac2141d..767b5bfc 100644 --- a/.github/workflows/ci-tests.yml +++ b/.github/workflows/ci-tests.yml @@ -307,7 +307,7 @@ jobs: - name: Import run: | - nominatim import --prepare-database --osm-file ../test.pbf + nominatim import --prepare-database nominatim import --no-superuser --osm-file ../test.pbf working-directory: /home/nominatim/nominatim-project diff --git a/nominatim/clicmd/setup.py b/nominatim/clicmd/setup.py index 61552b3d..4df14bc5 100644 --- a/nominatim/clicmd/setup.py +++ b/nominatim/clicmd/setup.py @@ -82,11 +82,13 @@ class SetupAll: if args.continue_at is None: files = args.get_osm_file_list() - if not files: + if not files and not args.only_prepare_database: raise UsageError("No input files (use --osm-file).") if args.only_import_data and args.only_prepare_database: - raise UsageError("Cannot use --no-superuser and --prepare-database together.") + raise UsageError( + "Cannot use --only-import-data and --only-prepare-database together." + ) if args.only_prepare_database or self._is_complete_import(args): LOG.warning('Creating database')