Skip to content

FR: connect_timeout in Connection URIs #516

@Andrei-Pozolotin

Description

@Andrei-Pozolotin
  1. the following snippet:
import asyncpg
await asyncpg.connect(dsn=data_conn)
  1. works with application_name:
data_conn="postgresql://postgres:postgres@data-serv-0:5432/postgres?application_name=simple"
  1. and fails with connect_timeout:
data_conn="postgresql://postgres:postgres@data-serv-0:5432/postgres?application_name=simple&connect_timeout=3"
asyncpg.exceptions.UndefinedObjectError: unrecognized configuration parameter "connect_timeout"

despite both application_name and connect_timeout should be valid options:
https://www.postgresql.org/docs/12/libpq-connect.html#LIBPQ-CONNSTRING

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions