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

Postgres session role not used when listing layers #57761

Open
2 tasks done
felnne opened this issue Jun 14, 2024 · 0 comments
Open
2 tasks done

Postgres session role not used when listing layers #57761

felnne opened this issue Jun 14, 2024 · 0 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers

Comments

@felnne
Copy link

felnne commented Jun 14, 2024

What is the bug or the crash?

When a session role is set in a Postgres connection, this role is not set when connecting to the database to list available layers - meaning layers that require that role to be seen can't be.

Steps to reproduce the issue

  1. add a Postgres connection with a session role (e.g. 'admin')
  2. test the connection - note that a SET ROLE statement is visible in the DB debugger
  3. use the new connection to list available layers - note that a SET ROLE statement is not visible in the DB debugger

In both cases other connection setup statements such as SET extra_float_digits are visible for both connections, suggesting there is a bug in that SET ROLE should be set in subsequent connections as well.

See also this log (the second set of requests starts at '2024-06-14T11:02:02.007'): db_log.json.

Versions

QGIS version
3.36.3-Maidenhead
QGIS code revision
2df9655469b
Qt version
5.15.2
Python version
3.9.5
GDAL/OGR version
3.3.2
PROJ version
8.1.1
EPSG Registry database version
v10.028 (2021-07-07)
GEOS version
3.9.1-CAPI-1.14.2
SQLite version
3.35.2
PDAL version
2.3.0
PostgreSQL client version
unknown
SpatiaLite version
5.0.1
QWT version
6.1.6
QScintilla2 version
2.11.5
OS version
macOS 14.5

Active Python plugins
processing
2.12.99
grassprovider
2.12.99
db_manager
0.1.20
MetaSearch
0.3.6
CustomToolBar
1.1

Supported QGIS version

  • I'm running a supported QGIS version according to the roadmap.

New profile

Additional context

No response

@felnne felnne added the Bug Either a bug report, or a bug fix. Let's hope for the latter! label Jun 14, 2024
@agiudiceandrea agiudiceandrea added the Data Provider Related to specific vector, raster or mesh data providers label Jun 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers
Projects
None yet
Development

No branches or pull requests

2 participants