]> git.openstreetmap.org Git - nominatim.git/commitdiff
fix dependencies and adapt documentation for psycopg3
authorSarah Hoffmann <lonvia@denofr.de>
Sat, 13 Jul 2024 20:34:16 +0000 (22:34 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Mon, 29 Jul 2024 06:54:09 +0000 (08:54 +0200)
.github/actions/build-nominatim/action.yml
docs/admin/Installation.md
packaging/nominatim-db/pyproject.toml
vagrant/Install-on-Ubuntu-22.sh

index 17ff0ccfc14d391958309bae4020e598523b69e5..d601fc7b7880534eec5934e4bb0e7ab57a2c03c1 100644 (file)
@@ -27,9 +27,9 @@ runs:
           run: |
             sudo apt-get install -y -qq libboost-system-dev libboost-filesystem-dev libexpat1-dev zlib1g-dev libbz2-dev libpq-dev libproj-dev libicu-dev liblua${LUA_VERSION}-dev lua${LUA_VERSION} lua-dkjson nlohmann-json3-dev libspatialite7 libsqlite3-mod-spatialite
             if [ "$FLAVOUR" == "oldstuff" ]; then
-                pip3 install MarkupSafe==2.0.1 python-dotenv psycopg2==2.7.7 jinja2==2.8 psutil==5.4.2 pyicu==2.9 osmium PyYAML==5.1 sqlalchemy==1.4.31 datrie asyncpg aiosqlite
+                pip3 install MarkupSafe==2.0.1 python-dotenv jinja2==2.8 psutil==5.4.2 pyicu==2.9 osmium PyYAML==5.1 sqlalchemy==1.4.31 psycopg==3.1.7 datrie asyncpg aiosqlite
             else
-                sudo apt-get install -y -qq python3-icu python3-datrie python3-pyosmium python3-jinja2 python3-psutil python3-psycopg2 python3-dotenv python3-yaml
+                sudo apt-get install -y -qq python3-icu python3-datrie python3-pyosmium python3-jinja2 python3-psutil python3-dotenv python3-yaml
                 pip3 install sqlalchemy psycopg aiosqlite
             fi
           shell: bash
index a2f1a084c5678a0d997dc02e4abf2a3298f364d4..9159ac62666287b81f70b754a8b2caf985917065 100644 (file)
@@ -36,19 +36,15 @@ For running Nominatim:
 
 Furthermore the following Python libraries are required:
 
-  * [Psycopg2](https://www.psycopg.org) (2.7+)
+  * [Psycopg3](https://www.psycopg.org)
   * [Python Dotenv](https://github.com/theskumar/python-dotenv)
   * [psutil](https://github.com/giampaolo/psutil)
   * [Jinja2](https://palletsprojects.com/p/jinja/)
-  * [SQLAlchemy](https://www.sqlalchemy.org/) (1.4.31+ with greenlet support)
-  * one of
-    * [psycopg3](https://www.psycopg.org)
-    * [asyncpg](https://magicstack.github.io/asyncpg) (0.8+)
   * [PyICU](https://pypi.org/project/PyICU/)
   * [PyYaml](https://pyyaml.org/) (5.1+)
   * [datrie](https://github.com/pytries/datrie)
 
-These will be installed automatically, when using pip installation.
+These will be installed automatically when using pip installation.
 
 When using legacy CMake-based installation:
 
@@ -69,6 +65,8 @@ For running continuous updates:
 
 For running the Python frontend:
 
+  * [SQLAlchemy](https://www.sqlalchemy.org/) (1.4.31+ with greenlet support)
+  * [asyncpg](https://magicstack.github.io/asyncpg) (0.8+, only when using SQLAlchemy < 2.0)
   * one of the following web frameworks:
     * [falcon](https://falconframework.org/) (3.0+)
     * [starlette](https://www.starlette.io/)
index 112f5a297002f2fc72ace65c58f9bcf39fcc191b..841845f036f20e3ad5db19ba9f8c62fcfe44b4c4 100644 (file)
@@ -15,7 +15,7 @@ classifiers = [
     "Operating System :: OS Independent",
 ]
 dependencies = [
-    "psycopg[pool]",
+    "psycopg",
     "python-dotenv",
     "jinja2",
     "pyYAML>=5.1",
index 9d8642a69de397f34b3ee4a4dd7add593b6342df..aa23128aef4f7400bd855f4daf2e58fd4ca4d6c9 100755 (executable)
@@ -26,7 +26,7 @@ export DEBIAN_FRONTEND=noninteractive #DOCS:
                         nlohmann-json3-dev postgresql-14-postgis-3 \
                         postgresql-contrib-14 postgresql-14-postgis-3-scripts \
                         libicu-dev python3-dotenv \
-                        python3-psycopg2 python3-psutil python3-jinja2 \
+                        python3-psycopg python3-psutil python3-jinja2 \
                         python3-sqlalchemy python3-asyncpg \
                         python3-icu python3-datrie python3-yaml git