Skip to content

kbagent auth login: no redirect back to CLI when user isn't already logged in to the platform #780

Description

@davidesner

Summary

kbagent auth login does not complete when the user is not already logged in to the Keboola platform in their browser.

Steps to reproduce

  1. Make sure you are logged out of the Keboola platform in the browser (no active platform session).
  2. Run kbagent auth login (or kbagent auth login --stack <url> --register-projects).
  3. The command opens a browser tab and redirects to the platform login page, as expected.
  4. Log in with valid credentials.

Expected behavior

After a successful login, the browser should redirect back to the CLI's local callback (completing the PKCE/OAuth flow), and kbagent auth login should finish and return control to the terminal.

Actual behavior

After login, no redirect back to the CLI happens. Instead:

  • The browser just lands on the standard project selection / project detail screen, as if the user had logged in normally through the UI - not on a "you can close this tab" / CLI-callback confirmation page.
  • The kbagent auth login command in the terminal hangs indefinitely and never returns.

This only reproduces when the browser has no existing platform session at the start of the flow. If the user is already logged in (so the browser just bounces through the login redirect without actually prompting for credentials), the callback appears to work.

Environment

  • Reported by: David Ešner (Keboola, AI team)
  • Client: kbagent CLI (terminal), browser-based auth login flow

Notes

This effectively blocks first-time / logged-out setup via kbagent auth login, since the only way to get through it currently is to log in to the platform UI first (in the same browser) and then re-run auth login.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

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