GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — Connection to Postgres fails when password contains special characters · Issue #4393 · feast-dev/feast Closed Labels DescriptionWith the release of this PR, this method was added to construct the connection string for the connection to Postgres with psycopg3. However, when a password contains special characters, they are not properly escaped, which leads to connection errors. Expected BehaviorThe special characters are escaped properly. Current BehaviorThe special characters are not escaped properly, leading to connection errors. Steps to reproduceIn the setup file for the postgres integration tests, update all occurrences of the password Then run all postgres online store integration tests by running: make test-python-universal-postgres-online SpecificationsVersion: 0.36.0 Possible SolutionThe potential solution is to use update these lines of code to the following: from psycopg.conninfo import make_conninfo def _get_conninfo(config: PostgreSQLConfig) -> str: """Get the `conninfo` argument required for connection objects.""" psycopg_config = { "user": config.user, "password": config.password, "host": config.host, "port": int(config.port), "dbname": config.database, } return make_conninfo(**psycopg_config) Instead of using a connection string, this passes the config in key-value pairs. When passing it as key-value pairs the special characters are escaped properly. More info here. Activity
MetadataMetadataAssigneesLabelsTypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |