File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -90,8 +90,9 @@ def get_python_sql_connector_auth_provider(hostname: str, **kwargs):
90
90
tls_client_cert_file = kwargs .get ("_tls_client_cert_file" ),
91
91
oauth_scopes = PYSQL_OAUTH_SCOPES ,
92
92
oauth_client_id = kwargs .get ("oauth_client_id" ) or PYSQL_OAUTH_CLIENT_ID ,
93
- oauth_redirect_port_range = kwargs .get ("oauth_redirect_port_range" ) if kwargs .get (
94
- "oauth_client_id" ) else PYSQL_OAUTH_REDIRECT_PORT_RANGE ,
93
+ oauth_redirect_port_range = [kwargs .get ("oauth_redirect_port" )]
94
+ if kwargs .get ("oauth_client_id" )
95
+ else PYSQL_OAUTH_REDIRECT_PORT_RANGE ,
95
96
oauth_persistence = kwargs .get ("experimental_oauth_persistence" ),
96
97
)
97
98
return get_auth_provider (cfg )
Original file line number Diff line number Diff line change @@ -61,10 +61,11 @@ def __init__(
61
61
Note this is beta (private preview)
62
62
63
63
oauth_client_id: `str`, optional
64
- custom oauth client_id. If not specified, it will use the client_id of databricks-sql-python
64
+ custom oauth client_id. If not specified, it will use the built-in client_id of databricks-sql-python.
65
65
66
- oauth_redirect_port_range: `List[str]`, optional
67
- oauth redirect port range. This is required when custom oauth client_id `oauth_client_id` is set
66
+ oauth_redirect_port: `int`, optional
67
+ port of the oauth redirect uri (localhost). This is required when custom oauth client_id
68
+ `oauth_client_id` is set
68
69
69
70
experimental_oauth_persistence: configures preferred storage for persisting oauth tokens.
70
71
This has to be a class implementing `OAuthPersistence`.
You can’t perform that action at this time.
0 commit comments