Skip to content

Commit c02781c

Browse files
Update asyncpg/connect_utils.py
Co-authored-by: Elvis Pranskevichus <elvis@magic.io>
1 parent 93347b0 commit c02781c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

asyncpg/connect_utils.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,8 @@ def _parse_connect_dsn_and_args(*, dsn, host, port, user,
528528
val = service_params.pop('gsslib')
529529
if gsslib is None:
530530
gsslib = val
531-
531+
if not service:
532+
service = os.environ.get('PGSERVICE')
532533
if not host:
533534
hostspec = os.environ.get('PGHOST')
534535
if hostspec:

0 commit comments

Comments
 (0)