{"version":"2.1.312","anchor":"cli-background-subcommands-wait-for-oauth-refresh-before-exi","canonical_anchor":"cli-background-subcommands-wait-for-oauth-refresh-before-exi","heading":"Background session commands wait for a sign-in refresh before exiting","tier":"notice","area":"Sessions","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.312\/e\/cli-background-subcommands-wait-for-oauth-refresh-before-exi","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.312","markdown":"### Background session commands wait for a sign-in refresh before exiting\n\nThe logs, attach, respawn, rm and stop commands, and `--bg`, now wait for any sign-in refresh to finish before exiting\n\n**What**\n\nThe commands that manage background sessions (logs, attach, respawn, rm and stop) and starting a session with `--bg` now wait for any sign-in token refresh in progress to finish before they exit. Before, they exited as soon as Claude Code had finished sending its usage data.\n\n**Why**\n\nA freshly refreshed sign-in is less likely to be lost when one of these commands exits.\n\n- Area: Sessions\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}