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

Cody: Reduce scroll threshold for auto scroll #39

Merged
merged 1 commit into from
Jul 10, 2023

Conversation

umpox
Copy link
Contributor

@umpox umpox commented Jul 10, 2023

Description

To give a typing feel, we reduced streaming intervals between character chunks in this PR

We should also adjust this scroll threshold, as it is now more likely that a new chunk will come in while a user scrolls, and move them back to the bottom of the threshold.

@umpox umpox requested review from a team July 10, 2023 16:27
@umpox umpox merged commit 7fcdb53 into main Jul 10, 2023
@umpox umpox deleted the tr/halve-scroll-threshold branch July 10, 2023 16:54
valerybugakov pushed a commit that referenced this pull request Nov 28, 2024
Backports keep giving an error about not finding the right team, testing
to see if it's a lint issue
abeatrix added a commit that referenced this pull request Dec 16, 2024
)

FIX https://linear.app/sourcegraph/issue/CODY-4529

# Fix Deep Cody Rate Limiter Reset Logic

This PR fixes an issue where users were unable to use Deep Cody even
after the 24-hour cooldown period had elapsed.

## Changes

- Added explicit 24-hour reset check in
`DeepCodyRateLimiter.isAtLimit()`
- Simplified quota replenishment logic
- Improved handling of initial quota state

## Technical Details

Previously, the rate limiter used a continuous time-based quota
replenishment system that calculated partial quotas based on elapsed
time. This led to unexpected behavior where users wouldn't get a
fresh quota even after not using Deep Cody for over 24 hours.

The updated implementation:
1. First checks if a full day (24 hours) has passed since last usage
2. If yes, immediately resets to full quota
3. If no, calculates remaining quota using time-based replenishment


## Test plan



Added new test case resets quota after 24 hours of non-use that
specifically tests the 24-hour reset functionality
Test verifies that:

- When last use was 25 hours ago (>24h)
- With an empty quota (0)
- The limiter resets to full quota (50)
- Confirms the storage is updated with new quota and timestamp

Maintained all existing test cases to ensure no regressions
Uses the same test infrastructure (mocks, beforeEach setup)

## Changelog


 <br> Backport 34d5e74 from #6366

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Dec 16, 2024
FIX https://linear.app/sourcegraph/issue/CODY-4529

# Fix Deep Cody Rate Limiter Reset Logic

This PR fixes an issue where users were unable to use Deep Cody even
after the 24-hour cooldown period had elapsed.

## Changes

- Added explicit 24-hour reset check in
`DeepCodyRateLimiter.isAtLimit()`
- Simplified quota replenishment logic
- Improved handling of initial quota state

## Technical Details

Previously, the rate limiter used a continuous time-based quota
replenishment system that calculated partial quotas based on elapsed
time. This led to unexpected behavior where users wouldn&#39;t get a
fresh quota even after not using Deep Cody for over 24 hours.

The updated implementation:
1. First checks if a full day (24 hours) has passed since last usage
2. If yes, immediately resets to full quota
3. If no, calculates remaining quota using time-based replenishment


## Test plan



Added new test case resets quota after 24 hours of non-use that
specifically tests the 24-hour reset functionality
Test verifies that:

- When last use was 25 hours ago (&gt;24h)
- With an empty quota (0)
- The limiter resets to full quota (50)
- Confirms the storage is updated with new quota and timestamp

Maintained all existing test cases to ensure no regressions
Uses the same test infrastructure (mocks, beforeEach setup)

## Changelog


 <br> Backport 34d5e74 from #6366

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Dec 17, 2024
…n issue (#6378)

Follow up on #6366

This PR fixes several issues with the Deep Cody rate limiter
implementation:

Root Cause Fix: Rate Limit State Synchronization

- Fixed race condition in LocalStorageProvider.ts where concurrent
Promise.all() usage led to inconsistent state between quota and
timestamp storage
- Changed to sequential storage operations to ensure timestamp is always
saved after quota update
- This resolves the core issue where users were locked out due to
incorrect time calculations (CODY-4529)

## Test plan



- Added precise tests for time-based quota calculations
- Enhanced test coverage for various timing scenarios

Before this change, the Deep Cody rate limit error would always return
the &quot;Retry time&quot; with current time + 24 hours to indicate the
current time is being used as the last used time.

Submitted at 6:44


![image](https://github.com/user-attachments/assets/d9b50ff8-bc09-473b-a387-497d1ccbe0c2)

Submitted again at 6:45


![image](https://github.com/user-attachments/assets/e1b0266b-cfbc-40f8-807b-a9d4c93be682)

After this change, the &quot;Retry Time&quot; should stick with the last
used time until it&#39;s been reset after 24 hours.

## Changelog


 <br> Backport a7339ef from #6377

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Dec 17, 2024
…ue (#6379)

Follow up on #6366

This PR fixes several issues with the Deep Cody rate limiter
implementation:

Root Cause Fix: Rate Limit State Synchronization

- Fixed race condition in LocalStorageProvider.ts where concurrent
Promise.all() usage led to inconsistent state between quota and
timestamp storage
- Changed to sequential storage operations to ensure timestamp is always
saved after quota update
- This resolves the core issue where users were locked out due to
incorrect time calculations (CODY-4529)

## Test plan



- Added precise tests for time-based quota calculations
- Enhanced test coverage for various timing scenarios

Before this change, the Deep Cody rate limit error would always return
the &quot;Retry time&quot; with current time + 24 hours to indicate the
current time is being used as the last used time.

Submitted at 6:44


![image](https://github.com/user-attachments/assets/d9b50ff8-bc09-473b-a387-497d1ccbe0c2)

Submitted again at 6:45


![image](https://github.com/user-attachments/assets/e1b0266b-cfbc-40f8-807b-a9d4c93be682)

After this change, the &quot;Retry Time&quot; should stick with the last
used time until it&#39;s been reset after 24 hours.

## Changelog


 <br> Backport a7339ef from #6377

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Dec 17, 2024
CLOSE
https://linear.app/sourcegraph/issue/CODY-4533/layout-bug-in-prompts-tab-and-new-user-menu-ui


![image](https://github.com/user-attachments/assets/a7d5fe5c-2635-47f1-8ffa-00c781287f62)

Fix UserMenu dropdown appearing underneath PromptList search box
The UserMenu dropdown and PromptList search box were competing for
z-index positioning since both had z-index: 1. Because PromptList was
rendered after UserMenu in the DOM order, it would appear on top of the
UserMenu dropdown when opened.

This fix increases UserMenu&#39;s z-index to 2, ensuring it properly
stacks above the PromptList search box while maintaining both
components&#39; ability to overlay their respective underlying content.

Changes

- Updated UserMenu dropdown z-index from 1 to 2 to create proper
stacking hierarchy
- Maintains existing stacking contexts for both components

## Test plan



After


![image](https://github.com/user-attachments/assets/9341c4cf-b90c-4e28-806e-5c6ce15d69ab)

1. Open Cody sidebar
2. Navigate to Prompts tab
3. Click on user avatar to open UserMenu dropdown
4. Verify UserMenu dropdown appears above the PromptList search box
5. Verify PromptList search box still properly overlays its content when
scrolling
6. Verify UserMenu dropdown properly overlays all other UI elements


## Changelog


 <br> Backport 03dbec6 from #6380

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Dec 17, 2024
…#6393)

CLOSE
https://linear.app/sourcegraph/issue/CODY-4533/layout-bug-in-prompts-tab-and-new-user-menu-ui


![image](https://github.com/user-attachments/assets/a7d5fe5c-2635-47f1-8ffa-00c781287f62)

Fix UserMenu dropdown appearing underneath PromptList search box
The UserMenu dropdown and PromptList search box were competing for
z-index positioning since both had z-index: 1. Because PromptList was
rendered after UserMenu in the DOM order, it would appear on top of the
UserMenu dropdown when opened.

This fix increases UserMenu&#39;s z-index to 2, ensuring it properly
stacks above the PromptList search box while maintaining both
components&#39; ability to overlay their respective underlying content.

Changes

- Updated UserMenu dropdown z-index from 1 to 2 to create proper
stacking hierarchy
- Maintains existing stacking contexts for both components

## Test plan



After


![image](https://github.com/user-attachments/assets/9341c4cf-b90c-4e28-806e-5c6ce15d69ab)

1. Open Cody sidebar
2. Navigate to Prompts tab
3. Click on user avatar to open UserMenu dropdown
4. Verify UserMenu dropdown appears above the PromptList search box
5. Verify PromptList search box still properly overlays its content when
scrolling
6. Verify UserMenu dropdown properly overlays all other UI elements


## Changelog


 <br> Backport 03dbec6 from #6380

Co-authored-by: Beatrix <[email protected]>
abeatrix pushed a commit that referenced this pull request Dec 23, 2024
…query (#6440)

When we remove the mentions, for some reason we&#39;re trimming spaces
from the start, but not the end. This means our exact match heuristics
won&#39;t work as well for these situations because there&#39;s a rogue
space at the end of the query.

This just fixes the logic to trim spaces from both the start and end

## Test plan

This query used to give less relevant results because we kept the
trailing space:
![CleanShot 2024-12-20 at 10 53
31@2x](https://github.com/user-attachments/assets/f49246ee-99cf-47b2-835a-34505ab7ac5d)
 <br> Backport 78da6bb from #6432

Co-authored-by: Camden Cheek <[email protected]>
abeatrix pushed a commit that referenced this pull request Dec 23, 2024
…#6446)

When we remove the mentions, for some reason we&#39;re trimming spaces
from the start, but not the end. This means our exact match heuristics
won&#39;t work as well for these situations because there&#39;s a rogue
space at the end of the query.

This just fixes the logic to trim spaces from both the start and end

## Test plan

This query used to give less relevant results because we kept the
trailing space:
![CleanShot 2024-12-20 at 10 53
31@2x](https://github.com/user-attachments/assets/f49246ee-99cf-47b2-835a-34505ab7ac5d)
 <br> Backport 78da6bb from #6432

Co-authored-by: Camden Cheek <[email protected]>
abeatrix added a commit that referenced this pull request Jan 13, 2025
…text settings (#6619)

CLOSE https://linear.app/sourcegraph/issue/CODY-4632

Updates the `ToolboxButton` component that provides a UI for managing
agent context settings with a more detailed description of the feature.

- Updates toggles for agentic context and terminal access, with
appropriate warnings
- Displays the button on all messages
- Debounces the settings update to avoid excessive API calls with the
removed save button
- Display button on all messages
- Display button without title text in non-first message
- Hide terminal context on unsupported instance/clients

## Test plan



UI update without feature change - storybook updated.


![image](https://github.com/user-attachments/assets/0459f2b1-e0b9-463f-83c8-0d20e6f789b4)


![image](https://github.com/user-attachments/assets/37ee046a-0b6c-4d1c-916f-fd593d636c5a)

Hide shell command on unsupported client or instances


![image](https://github.com/user-attachments/assets/24cc5215-7118-4cfa-a5de-0b643cdf2a1f)

### Before

The current one doesn&#39;t explain what agentic context and terminal
context are:


![image](https://github.com/user-attachments/assets/27da9d5f-bf5e-4a34-8ed8-6e37a80dbd48)
 <br> Backport d865d65 from #6596

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Jan 13, 2025
…6618)

CLOSE https://linear.app/sourcegraph/issue/CODY-4671

Fixes a regression where the agent would mark a context as needed but
got filtered out during the validation step

- Simplify the context review logic by directly extracting context names
from the response and fetching the full content for the requested files.
- Remove unnecessary callbacks and optimize the context fetching
process.
- Add a helper function to check if the response is ready to answer.


## Test plan



Manual testing:

1. Ask in new chat: &quot;how does agentic context work in
@_cody_repo&quot;
2. Add a follow up: &quot;how many loop does deep cody run for the
review step?&quot;

Before

Deep Cody requested a file:


![image](https://github.com/user-attachments/assets/a15b9e8e-3d2f-4eaa-b143-db9384540f28)

But it wasn&#39;t included in the final selected context:

&lt;img width=&quot;829&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/07f0d283-0e84-4879-81e8-f6f38c807ccb&quot;
/&gt;

After:

&lt;img width=&quot;839&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/bb846639-7a04-4ad8-a247-982dd9ede381&quot;
/&gt;


 <br> Backport 54982b5 from #6602

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Jan 13, 2025
… settings (#6626)

CLOSE https://linear.app/sourcegraph/issue/CODY-4632

Updates the `ToolboxButton` component that provides a UI for managing
agent context settings with a more detailed description of the feature.

- Updates toggles for agentic context and terminal access, with
appropriate warnings
- Displays the button on all messages
- Debounces the settings update to avoid excessive API calls with the
removed save button
- Display button on all messages
- Display button without title text in non-first message
- Hide terminal context on unsupported instance/clients

## Test plan



UI update without feature change - storybook updated.


![image](https://github.com/user-attachments/assets/0459f2b1-e0b9-463f-83c8-0d20e6f789b4)


![image](https://github.com/user-attachments/assets/37ee046a-0b6c-4d1c-916f-fd593d636c5a)

Hide shell command on unsupported client or instances


![image](https://github.com/user-attachments/assets/24cc5215-7118-4cfa-a5de-0b643cdf2a1f)

### Before

The current one doesn&#39;t explain what agentic context and terminal
context are:


![image](https://github.com/user-attachments/assets/27da9d5f-bf5e-4a34-8ed8-6e37a80dbd48)
 <br> Backport d865d65 from #6596

Co-authored-by: Beatrix <[email protected]>
abeatrix added a commit that referenced this pull request Jan 13, 2025
CLOSE https://linear.app/sourcegraph/issue/CODY-4671

Fixes a regression where the agent would mark a context as needed but
got filtered out during the validation step

- Simplify the context review logic by directly extracting context names
from the response and fetching the full content for the requested files.
- Remove unnecessary callbacks and optimize the context fetching
process.
- Add a helper function to check if the response is ready to answer.


## Test plan



Manual testing:

1. Ask in new chat: &quot;how does agentic context work in
@_cody_repo&quot;
2. Add a follow up: &quot;how many loop does deep cody run for the
review step?&quot;

Before

Deep Cody requested a file:


![image](https://github.com/user-attachments/assets/a15b9e8e-3d2f-4eaa-b143-db9384540f28)

But it wasn&#39;t included in the final selected context:

&lt;img width=&quot;829&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/07f0d283-0e84-4879-81e8-f6f38c807ccb&quot;
/&gt;

After:

&lt;img width=&quot;839&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/bb846639-7a04-4ad8-a247-982dd9ede381&quot;
/&gt;


 <br> Backport 54982b5 from #6602

Co-authored-by: Beatrix <[email protected]>
hitesh-1997 pushed a commit that referenced this pull request Jan 21, 2025
…d of changelog entries (#6712)

This works by using the title as the changelog entry instead.
We cannot use the compact mode version with this feature enabled, it
fails to find a `section` `formatEntry` command and exits before the
changelog is generated.

Also updated the changelog marker since it&#39;s different now?


## Test plan
I ran the
[action](https://github.com/sourcegraph/cody/actions/runs/12799005063/job/35684227555)
which produced this [PR](#6668)

 <br> Backport 4ce3794 from #6669

Co-authored-by: Anish Lakhwara <[email protected]>
hitesh-1997 pushed a commit that referenced this pull request Jan 22, 2025
…ime error (#6729)

- By testing locally, I reproduced the runtime error we see in our
analytics data. It&#39;s coming from the diagnostics retriever where
line numbers are not clamped.
- Closes [CODY-4717: Fix the `illegal line` runtime
error](https://linear.app/sourcegraph/issue/CODY-4717/fix-the-illegal-line-runtime-error)

## Test plan

CI + updated unit tests
 <br> Backport 962666c from #6727

Co-authored-by: Valery Bugakov <[email protected]>
kalanchan added a commit that referenced this pull request Jan 22, 2025
…s to keep workflow referen… (#6739)

running into errors in generate changelog action where it can&#39;t
create the PRs due to conflicts, this removes the non essential git
configuration steps to keep the reference branch the same


## Test plan
N/A, couldn&#39;t test locally need the github UI

 <br> Backport bfa18e6 from #6737

Co-authored-by: Kalan <[email protected]>
umpox pushed a commit that referenced this pull request Jan 22, 2025
…aces vscode sign-in flow) (#6742)

Part of
https://linear.app/sourcegraph/issue/DES-235/[onboarding-polish]-extensions-logout-guidance-step

This small change allows us to specify the instance URL for sigh up /
auth flow, it&#39;s useful for workspace flow when we don&#39;t
originally start our log-in flow from vscode and fill in the workspace
URL but right from the workspace instance and we should notify cody to
which URL it should try to log in with access token (code URL param)

This PR is primarily needed for the workspace log-in into VSCode Cody PR
in the Sourcegraph repository.


https://github.com/user-attachments/assets/1dd1b90d-970e-4c2d-a71a-89cdaddf354a

@mmanela I saw your contributions about instance param in this flow, do
you think we should make users go through this flow manually? I still
left your logic in there so we can switch it later if we want.

@kalanchan, this PR is important for workspace setup flow. Can I ask you
to make sure it&#39;s included in the upcoming Cody release? I think
it&#39;s going to be 1.62, right?

## Test plan
- Check that the standard auth flow has no regression
- The workspace flow will be tested in the Sourcegraph repository PR
 <br> Backport 7e4dbf9 from #6730

Co-authored-by: Vova Kulikov <[email protected]>
umpox pushed a commit that referenced this pull request Jan 22, 2025
… when enabled (#6758)

FIX https://linear.app/sourcegraph/issue/CODY-4737

The issue was that the Tool Cody model was being added to the list of
primary models regardless of whether the feature was enabled or not. The
root cause was that the check for the existence of the Tool Cody model
was not properly scoped to the `isToolCodyEnabled` flag but was checking
the observable instead, which would always returns true as the
observable is defined.

This change fixes the issue by only adding the Tool Cody model to the
list of primary models if the `isToolCodyEnabled` flag is true and the
Tool Cody model is not already present in the list of primary models.

Included some minor clean up.

## Test plan



Verify Tool Cody is not showing up in your model dropdown if you
don&#39;t have the configuration in your settings:

&lt;img width=&quot;603&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/6ebdbb6e-650d-4bc4-ad62-40a285a13f5f&quot;
/&gt;

 <br> Backport ae351c2 from #6753

Co-authored-by: Beatrix <[email protected]>
umpox pushed a commit that referenced this pull request Jan 22, 2025
…n enabled (#6759)

FIX https://linear.app/sourcegraph/issue/CODY-4737

The issue was that the Tool Cody model was being added to the list of
primary models regardless of whether the feature was enabled or not. The
root cause was that the check for the existence of the Tool Cody model
was not properly scoped to the `isToolCodyEnabled` flag but was checking
the observable instead, which would always returns true as the
observable is defined.

This change fixes the issue by only adding the Tool Cody model to the
list of primary models if the `isToolCodyEnabled` flag is true and the
Tool Cody model is not already present in the list of primary models.

Included some minor clean up.

## Test plan



Verify Tool Cody is not showing up in your model dropdown if you
don&#39;t have the configuration in your settings:

&lt;img width=&quot;603&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/6ebdbb6e-650d-4bc4-ad62-40a285a13f5f&quot;
/&gt;

 <br> Backport ae351c2 from #6753

Co-authored-by: Beatrix <[email protected]>
umpox pushed a commit that referenced this pull request Jan 27, 2025
… for quick sign-in (#6653) (#6818)

This is cherry-picking @mmanela commit from
#6653

It was recently reverted here
#6794 due to problems with
reverting other PRs and merge conflicts.

This PR contains a required change for a successful Workspace Auth flow
so we should include this in the upcoming 1.64 release

## Original PR description 
VS Code side part of

https://linear.app/sourcegraph/issue/SRC-908/automate-cody-authflow-vs-code

After a user creates a workspace we want to make it easy for them to
sign-in to the instance in their editor. For enterprise instances today,
they need to copy the instance url, go into VS Code and then choose to
signin with enterprise instance and then paste the url.

This change will help stream-line that flow by allowing the UI in
sourcegraph to link to VS Code with a url like

`vscode://sourcegraph.cody-ai?instance=someinstance.sourcegraphdev.app`

VS Code will handle and either switch to that account if you already are
auth&#39;d OR pop-open the signin menu directly


![image](https://github.com/user-attachments/assets/cdab4135-2dae-48d3-945c-2e70187c37f0)

Note: For initial version I limited just to workspace domains. But we
can generalize that to allow other instance domains.

## Test plan

1. Validate when client doesn&#39;t have instance already
2. Validate when client already has instance connected

(cherry-picked from commit 9719dc4)

 <br> Backport ef65034 from #6812

Co-authored-by: Vova Kulikov <[email protected]>
umpox pushed a commit that referenced this pull request Jan 27, 2025
… URL for quick sign-in (#6653) (#6817)

This is cherry-picking @mmanela commit from
#6653

It was recently reverted here
#6794 due to problems with
reverting other PRs and merge conflicts.

This PR contains a required change for a successful Workspace Auth flow
so we should include this in the upcoming 1.64 release

## Original PR description 
VS Code side part of

https://linear.app/sourcegraph/issue/SRC-908/automate-cody-authflow-vs-code

After a user creates a workspace we want to make it easy for them to
sign-in to the instance in their editor. For enterprise instances today,
they need to copy the instance url, go into VS Code and then choose to
signin with enterprise instance and then paste the url.

This change will help stream-line that flow by allowing the UI in
sourcegraph to link to VS Code with a url like

`vscode://sourcegraph.cody-ai?instance=someinstance.sourcegraphdev.app`

VS Code will handle and either switch to that account if you already are
auth&#39;d OR pop-open the signin menu directly


![image](https://github.com/user-attachments/assets/cdab4135-2dae-48d3-945c-2e70187c37f0)

Note: For initial version I limited just to workspace domains. But we
can generalize that to allow other instance domains.

## Test plan

1. Validate when client doesn&#39;t have instance already
2. Validate when client already has instance connected

(cherry-picked from commit 9719dc4)

 <br> Backport ef65034 from #6812

Co-authored-by: Vova Kulikov <[email protected]>
umpox pushed a commit that referenced this pull request Jan 28, 2025
…tic model (#6828)

The display name for the deep-cody model has been updated from
&#39;Agentic Chat&#39; to &#39;Agentic chat&#39;.


## Test plan



Verify the name update:

&lt;img width=&quot;496&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/8e1cc5a3-d8bc-44ea-94c9-1a1488e39541&quot;
/&gt;
 <br> Backport ca3fcd1 from #6827

Co-authored-by: Beatrix <[email protected]>
umpox pushed a commit that referenced this pull request Jan 28, 2025
…model (#6829)

The display name for the deep-cody model has been updated from
&#39;Agentic Chat&#39; to &#39;Agentic chat&#39;.


## Test plan



Verify the name update:

&lt;img width=&quot;496&quot; alt=&quot;image&quot;
src=&quot;https://github.com/user-attachments/assets/8e1cc5a3-d8bc-44ea-94c9-1a1488e39541&quot;
/&gt;
 <br> Backport ca3fcd1 from #6827

Co-authored-by: Beatrix <[email protected]>
dominiccooney added a commit that referenced this pull request Jan 30, 2025
… some clean up (#6883)

- Name all of the release workflows consistently so they will appear
together in GitHub&#39;s actions list.
- Remove the unused experimental changelog generator.
- Remove stale release instructions from CONTRIBUTING.md, instead point
to Notion.

## Test plan

I am release captain, I will dogfood this week. <br> Backport
495962e from #6879

Co-authored-by: Dominic Cooney <[email protected]>
dominiccooney added a commit that referenced this pull request Jan 30, 2025
…ease.sh about release branches (#6884)

These scripts predate release branches and used to always look at global
tags. This change makes it work on release branches. It uses git to list
the commits on the release branch, then does the same version bump
calculation using the branch&#39;s tags.

It takes care to handle newly budding branches which are just a commit
on `main` that has no backports yet. In that case it looks at all of the
available tags.

It will work carrying a branch from prerelease through to release:

```
# At the start of the branch
$ ./scripts/push-git-tag-for-next-release.sh --minor --nightly
# During prerelease, assume we have accumulated some commits on the branch now:
$ ./scripts/push-git-tag-for-next-release.sh --patch --nightly
# Transitioning to release:
$ ./scripts/push-git-tag-for-next-release.sh --minor
# Hopefully never needed, but making emergency patches on stable:
$ ./scripts/push-git-tag-for-next-release.sh --patch
```

There are some caveats with this tool:
- When working on a release branch, it only has *local* view of *that
branch&#39;s tags.* Misusing it should be harmless because creating a
tag which conflicts with an existing tag will fail when the tag is
pushed.
- It does not enforce the new practice of stable builds having even
version numbers and prerelease builds having odd version numbers.

If you ever need to work around this tool, just author and push git tags
yourself. To this point release captains have been doing that anyway.

Adds a `--dry-run` option which makes testing easier. Removes outdated
docs and points to Notion instead.

## Test plan

```
# Pretend you&#39;re just cooking up a release branch
$ git remote update origin
$ git checkout -b my-release-branch origin/main
$ cd jetbrains
$ ./scripts/push-git-tag-for-next-release.sh --minor --nightly --dry-run
# It should suggest a minor version bump based on all the version tags in the repo
...
# Pretend you&#39;re on a release branch, we&#39;re doing a patch release
$ git fetch origin refs/heads/jb-v7.8.x
$ git checkout FETCH_HEAD
$ git checkout &lt;this PR&gt; -- scripts/next-release.sh scripts/push-git-tag-for-next-release.sh
$ git commit -m &#39;test test test do not push&#39;  # script insists the repo is clean
$ ./scripts/push-git-tag-for-next-release.sh --minor --dry-run
# It should suggest v7.8.1
```

I am the release captain and will dogfood this script in the current
release. <br> Backport b912145 from
#6881

Co-authored-by: Dominic Cooney <[email protected]>
julialeex pushed a commit that referenced this pull request Feb 7, 2025
…s. (#6977)

We will create releases in sourcegraph/cody now, because that&#39;s
where the commits are! And link to this page to display them:


https://github.com/sourcegraph/cody/releases?q=JetBrains&amp;expanded=true

## Test plan

```
cd jetbrains
./gradlew verifyPlugin
```

Land this, backport it, then release a v7.67 nightly and check that [the
JetBrains Marketplace
page](https://plugins.jetbrains.com/plugin/9682-cody-ai-code-assistant/edit/versions/nightly)
looks good. <br> Backport 15147f6 from
#6976

Co-authored-by: Dominic Cooney <[email protected]>
julialeex pushed a commit that referenced this pull request Feb 7, 2025
… follow-up message (#7009)

The user knows who they are, why show it next to every message? It
clutters the UI. So I removed the avatar from the human messages (we
still have the avatar in the top right).

I also removed the name from the follow-up message. It doesn&#39;t add
anything.

Ideally we&#39;d remove the &quot;user name&quot; every where but when I
did that, the layout looked kinda bad because there was still the
&#39;split into chat&#39; button.

## Before

![before](https://github.com/user-attachments/assets/2ce844e1-275a-42e4-876c-5d18bb011a47)

## After

![after](https://github.com/user-attachments/assets/364a23a7-242b-4ed7-a49f-08de8df6b47f)

## Test plan

- N/A <br> Backport 127d52c from #6981

Co-authored-by: Thorsten Ball <[email protected]>
julialeex pushed a commit that referenced this pull request Feb 7, 2025
…S Code (#7006)

Previously, pressing Enter in a chat message in VS Code&#39;s Cody chat
would cause the iframe to be shifted up by ~5px. This was an annoying
visual jitter. Now, this no longer happens.

## Test plan

CI

Also: Run in VS Code, type a chat message, press Enter, and ensure there
is no jitter. Also ask a long chat question and ensure that the
scroll-to-end works.

## Changelog

- Fixed an issue where pressing Enter in chat would cause brief visual
jitter in the UI. <br> Backport bc8f1fb
from #6991

Co-authored-by: Quinn Slack <[email protected]>
julialeex pushed a commit that referenced this pull request Feb 7, 2025
…constant (#7019)

This bugged me while reading and to warm up to the codebase, I decided
to replace the hardcoded strings with the reference. Can&#39;t do it in
`lib/shared`, but in `vscode`.


## Test plan

- Run Cody and see that agentic chat works.
 <br> Backport 386c0b6 from #6958

Co-authored-by: Thorsten Ball <[email protected]>
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