Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add setContext notification for cody.serverEndpoint #5918

Merged
merged 2 commits into from
Oct 17, 2024

Conversation

pkukielka
Copy link
Contributor

@pkukielka pkukielka commented Oct 16, 2024

Changes

I've added cody.serverEndpoint context variable, which on the clients side is received through window/didChangeContext notification. We need it on the jetbrains side in few places, e.g. when we are checking if current account is a dotcom account.

I think it might be better idea to replace this with a dedicated endpoint, but I'm not sure if cody.activated is currently used anywhere?
@dominiccooney @sqs WDYT?

Test plan

Full QA with sourcegraph/jetbrains#2382 is needed.
It does not change anything on the Cody side.

@pkukielka pkukielka force-pushed the pkukielka/add-token-update-notification branch from aa29e17 to 30cabe2 Compare October 16, 2024 15:15
'setContext',
'cody.serverEndpoint',
authStatus.endpoint
)
} catch {}
Copy link
Contributor

Choose a reason for hiding this comment

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

I'd rather have some logging here. Some day we may suffer from unknown and hard to identify problems.

@pkukielka pkukielka merged commit 5e87b71 into main Oct 17, 2024
20 checks passed
@pkukielka pkukielka deleted the pkukielka/add-token-update-notification branch October 17, 2024 12:15
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