Skip to content

Few chronicle updates#312284

Draft
vijayupadya wants to merge 9 commits intomainfrom
vijayu/consentDiag
Draft

Few chronicle updates#312284
vijayupadya wants to merge 9 commits intomainfrom
vijayu/consentDiag

Conversation

@vijayupadya
Copy link
Copy Markdown
Contributor

Few chronicle updates

vijayupadya and others added 4 commits April 22, 2026 10:16
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Copilot AI review requested due to automatic review settings April 24, 2026 02:12
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for Copilot “session sync” as a core VS Code setting (with enterprise policy), and updates the Copilot extension’s “chronicle”/session indexing feature flags and tooling to align with the new setting.

Changes:

  • Introduces chat.sessionSync.enabled (core) with CopilotSessionSync policy wiring and policy-data export updates.
  • Adds a new public Copilot extension setting github.copilot.chat.localIndex.enabled with migration from the prior team-internal key.
  • Extends chronicle tooling: session-sync enablement suggestion UX and a command to delete synced cloud session data, plus a cloud API client method.
Show a summary per file
File Description
src/vs/workbench/services/accounts/browser/defaultAccount.ts Threads a new session_sync_enabled entitlement/policy flag from token entitlements into cached policy data.
src/vs/workbench/contrib/chat/common/constants.ts Adds ChatConfiguration.SessionSyncEnabled constant.
src/vs/workbench/contrib/chat/browser/chat.contribution.ts Registers chat.sessionSync.enabled setting with enterprise policy mapping and localization.
src/vs/base/common/defaultAccount.ts Extends IPolicyData with session_sync_enabled.
extensions/copilot/src/platform/configuration/common/configurationService.ts Adds Advanced.LocalIndexEnabled via defineAndMigrateExpSetting and deprecates the old team-internal key.
extensions/copilot/src/extension/intents/node/chronicleIntent.ts Switches chronicle availability gating to the new local-index setting (with fallback logic).
extensions/copilot/src/extension/contextKeys/vscode-node/contextKeys.contribution.ts Updates github.copilot.sessionSearch.enabled context key to follow the new local-index setting (with fallback logic).
extensions/copilot/src/extension/chronicle/vscode-node/sessionStoreTracker.ts Gates local session store tracking on the new local-index setting (with fallback logic).
extensions/copilot/src/extension/chronicle/vscode-node/remoteSessionExporter.ts Gates cloud exporting on local index + core session sync; adds sync suggestion and delete-cloud-sessions command.
extensions/copilot/src/extension/chronicle/node/cloudSessionApiClient.ts Adds deleteSession endpoint call used by the delete command.
extensions/copilot/src/extension/chronicle/common/test/sessionIndexingPreference.spec.ts Updates tests to reflect new “session sync” gate semantics.
extensions/copilot/src/extension/chronicle/common/sessionIndexingPreference.ts Replaces repo-exclusion/cloud-sync settings with core chat.sessionSync.enabled consent check.
extensions/copilot/package.nls.json Adds command title localization; renames local-index setting localization key usage.
extensions/copilot/package.json Contributes new delete command and new github.copilot.chat.localIndex.enabled setting.
build/lib/policies/policyData.jsonc Adds exported policy metadata for chat.sessionSync.enabled and updates policy export contents.

Copilot's findings

Comments suppressed due to low confidence (3)

extensions/copilot/src/extension/chronicle/vscode-node/remoteSessionExporter.ts:141

  • This autorun only re-runs when observables are read. getNonExtensionConfig('chat.sessionSync.enabled') is not observable, so toggling the core setting at runtime won’t start/stop the exporter until some other observable changes. Consider wiring cloudEnabled through an observable (e.g., observableFromEvent on onDidChangeConfiguration + affectsConfiguration('chat.sessionSync.enabled')).
			const localEnabled = this._configService.isConfigured(ConfigKey.Advanced.LocalIndexEnabled) ? localEnabledNew.read(reader) : localEnabledOld.read(reader);
			const cloudEnabled = this._configService.getNonExtensionConfig<boolean>('chat.sessionSync.enabled') ?? false;
			if (!localEnabled || !cloudEnabled) {
				// Suggest session sync when local index is on but sync is off
				if (localEnabled && !cloudEnabled) {

extensions/copilot/src/extension/chronicle/vscode-node/remoteSessionExporter.ts:273

  • The success showInformationMessage concatenates multiple localized fragments (and a raw space) into one message. Please prefer a single localized string with placeholders (or separate showInformationMessage calls) to avoid broken grammar/order in non-English locales.
		if (errors > 0) {
			vscode.window.showWarningMessage(vscode.l10n.t('Deleted {0}, not found {1}, errors {2}.', deleted, notFound, errors));
		} else {
			vscode.window.showInformationMessage(vscode.l10n.t('{0} session(s) deleted from the cloud.', deleted) + (notFound > 0 ? ' ' + vscode.l10n.t('{0} not found in cloud (local-only or already deleted).', notFound) : ''));
		}

extensions/copilot/src/extension/chronicle/vscode-node/remoteSessionExporter.ts:192

  • The button label "Don't Show Again" is misleading here because there’s no persisted state; the prompt is only suppressed for the current session via _syncSuggestionShown. Either persist a dismissal flag (globalState/storage) or rename the action to something like "Not Now".
		vscode.window.showInformationMessage(
			vscode.l10n.t('Session sync is available for richer cross-device Copilot session history.'),
			vscode.l10n.t('Enable'),
			vscode.l10n.t('Don\'t Show Again'),
		).then(choice => {
  • Files reviewed: 15/15 changed files
  • Comments generated: 7

Comment thread extensions/copilot/src/extension/chronicle/vscode-node/sessionStoreTracker.ts Outdated
Comment thread build/lib/policies/policyData.jsonc Outdated
Comment thread extensions/copilot/src/extension/intents/node/chronicleIntent.ts Outdated
Comment thread extensions/copilot/src/extension/chronicle/vscode-node/remoteSessionExporter.ts Outdated
Comment thread extensions/copilot/src/extension/intents/node/chronicleIntent.ts Outdated
Comment thread extensions/copilot/src/extension/intents/node/chronicleIntent.ts
vijayupadya and others added 5 commits April 23, 2026 22:12
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants