databricks-cli/cmd/auth
shreyas-goenka 35cdf4010d
Do not error if we cannot prompt for a profile in `auth login` ()
## Changes
With https://github.com/databricks/cli/pull/1370 we started to error if
a profile name was not provided in a non-tty setting. The Databricks
VSCode extension, however, uses the `auth login` command to simply
refresh the tokens. Thus, this PR is a regression fix for that use case.

## Tests
Manually, `databricks auth login --host
https://e2-dogfood.staging.cloud.databricks.com` no longer errors.
Instead it successfully refreshes the credentials.
2024-09-04 07:14:21 +00:00
..
testdata Fix host resolution order in `auth login` () 2024-08-14 13:01:00 +00:00
README.md Rename bricks -> databricks () 2023-05-16 18:35:39 +02:00
auth.go Fix host resolution order in `auth login` () 2024-08-14 13:01:00 +00:00
describe.go Fixed typo in error template for auth describe () 2024-04-08 11:19:13 +00:00
describe_test.go Added `auth describe` command () 2024-04-03 08:14:04 +00:00
env.go Improve token refresh flow () 2024-05-16 10:22:09 +00:00
login.go Do not error if we cannot prompt for a profile in `auth login` () 2024-09-04 07:14:21 +00:00
login_test.go Fix host resolution order in `auth login` () 2024-08-14 13:01:00 +00:00
profiles.go Update error checks that use the `os` package to use `errors.Is` () 2024-06-03 12:39:36 +00:00
profiles_test.go Pass `DATABRICKS_CONFIG_FILE` env var to sdk config during `auth profiles` () 2024-04-24 09:18:13 +00:00
token.go Improve token refresh flow () 2024-05-16 10:22:09 +00:00
token_test.go Improve token refresh flow () 2024-05-16 10:22:09 +00:00

README.md

Auth challenge (happy path)

Simplified description of PKCE implementation:

Token refresh (happy path)