Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work with openstreetmap-carto @ b86de31 anymore (psycopg2 incompatibility) #2

Closed
gy-mate opened this issue Oct 26, 2024 · 0 comments · Fixed by #3
Closed

Doesn't work with openstreetmap-carto @ b86de31 anymore (psycopg2 incompatibility) #2

gy-mate opened this issue Oct 26, 2024 · 0 comments · Fixed by #3

Comments

@gy-mate
Copy link
Contributor

gy-mate commented Oct 26, 2024

Due to gravitystorm/openstreetmap-carto#4447 that was resolved after commit b86de31.

I get the following error when I run make.sh:

[...]
Downloading external datasets...
INFO:root:Checking table simplified_water_polygons
Traceback (most recent call last):
  File "/Users/███/Downloads/osm-mapping-party-before-after/openstreetmap-carto/./scripts/get-external-data.py", line 108, in index
    cur.execute('''VACUUM ANALYZE "{temp_schema}"."{name}";'''
    ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                .format(name=self._name, temp_schema=self._temp_schema))
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
psycopg2.errors.ActiveSqlTransaction: VACUUM cannot run inside a transaction block


During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/███/Downloads/osm-mapping-party-before-after/openstreetmap-carto/./scripts/get-external-data.py", line 294, in <module>
    main()
    ~~~~^^
  File "/Users/███/Downloads/osm-mapping-party-before-after/openstreetmap-carto/./scripts/get-external-data.py", line 284, in main
    this_table.index()
    ~~~~~~~~~~~~~~~~^^
  File "/Users/███/Downloads/osm-mapping-party-before-after/openstreetmap-carto/./scripts/get-external-data.py", line 111, in index
    self._conn.autocommit = old_autocommit
    ^^^^^^^^^^^^^^^^^^^^^
psycopg2.ProgrammingError: set_session cannot be used inside a transaction

I have the latest version of psycopg2 installed (2.9.10).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant