Change:
// ensure that it is published before Continue On is invoked if (!repository.HEAD?.upstream && repository.HEAD?.type === RefType.Head) { <del> if (publishBeforeContinueOn === 'prompt') { const always = vscode.l10n.t('Always'); const never = vscode.l10n.t('Never'); const selection = await vscode.window.showInformationMessage( vscode.l10n.t('The current branch is not published to the remote. Would you like to publish it to access your changes elsewhere?'), { modal: true }, ...[always, never] ); switch (selection) { case always: vscode.workspace.getConfiguration('git').update('publishBeforeContinueOn', 'always'); break; case never: vscode.workspace.getConfiguration('git').update('publishBeforeContinueOn', 'never'); default: return; } </del> <ins> const publishBranch = vscode.l10n.t('Publish Branch'); const selection = await vscode.window.showInformationMessage( vscode.l10n.t('The current branch is not published to the remote. Would you like to publish it to access your changes elsewhere?'), { modal: true }, publishBranch ); if (selection !== publishBranch) { throw new vscode.CancellationError(); </ins> } <del> await vscode.window.withProgress({ location: vscode.ProgressLocation.Notification, title: vscode.l10n.t('Publishing branch...') }, async () => { await vscode.commands.executeCommand('git.publish'); }); </del> <ins> await vscode.commands.executeCommand('git.publish'); </ins> } } }

Discussion:
Testing on Windows 11, latest Insiders When I selected in the publish warning, the same notification toasted again. ! ! I hit Cancel again, and I was then prompted to sign into GitHub, which I already did in the browser before getting the branch toast: ! Perhaps tied to
I realize I'm now getting duplicate toasts after any option. When I selected Allow, I got the same toast again: !

Testing Choosing Never failed: <img width="458" alt="image" src="https://user-"
Choosing Always also failed: <img width="453" alt="image" src="https://user-"
I was using a public repo:
I experience the same on Windows 11 with the repo:
Create New Codespace still fails with ContinueOn
The original issue reported here was due to the fact that we weren't properly awaiting the branch publish before invoking the codespace creation. based on our offline discussion I think you're encountering a different issue because the publish completes but the codespace creation doesn't start, and only if you aren't signed into the GitHub Codespaces extension, so I'm going to close this issue and we can file a new one to investigate the scenario you've uncovered since I can't reproduce it at the moment:

Testing I can't choose to publish and ask again next time: <img width="264" alt="image" src="https://user-"
Also: The text doesn't indicate that the Always/Never choice only applies to the current workspace folder (as I just discovered) and not to all repositories.
+1, I was about to file the same issue.
Great feedback, this leads me to think we should just have 'Yes' and 'Cancel' as the options here, because choosing 'Never' will break the Continue On flow (i.e. it's not an option that we can actually support, and per we should actually throw a and bail out of the whole flow here).
'Publish Branch' might be clearer than 'Yes'. The PR extension uses this dialog: <img width="261" alt="image" src="https://user-"
The "fix" for this is more problematic for me. I used to have this in my settings: Now every time I quit VS Code (I'm on Mac if it makes a difference), I see the dialog and I have to press "Cancel". Even worse, pressing "Cancel" seems to only close the dialog and reopen it again. can we reopen this issue and restore the setting at least? That'd be highly appreciated. Thanks.