Skip to content

Conversation

@Hweinstock
Copy link
Contributor

@Hweinstock Hweinstock commented Apr 22, 2025

Problem

the buttonClick event was not routed yet, but was implemented in runtimes here: aws/language-server-runtimes#464

Solution

  • add listener in chat-client to forward this button click to the host-client.
  • add a logging message in controller to see which button was clicked (temporary stub for backend logic).
  • In combination with https://github.com/aws/language-servers/pull/1041/files, the button should verify executions.

Verification

verification.mov

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

mynahUi.updateStore(storeTabKey, { promptInputStickyCard: null })
})
} else {
const payload: ButtonClickParams = {
Copy link
Contributor

Choose a reason for hiding this comment

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

oh wait so tool clicks are going to come through onInBodyButtonClicked?

Copy link
Contributor Author

@Hweinstock Hweinstock Apr 22, 2025

Choose a reason for hiding this comment

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

Yeah, this is how its implemented on agentic-chat branch here. Which took forever to find since its redirected almost 10 times.

@Hweinstock Hweinstock marked this pull request as ready for review April 22, 2025 12:52
@Hweinstock Hweinstock requested a review from a team as a code owner April 22, 2025 12:52
Hweinstock added a commit to aws/aws-toolkit-vscode that referenced this pull request Apr 22, 2025
## Problem
With aws/language-servers#1037, the chat client
will forward the button click event to the host client (VSC in this
case). We are then responsible for making a request to the LSP with this
button click.

## Solution
- route the button click to the LSP. 
- log any failed button click actions. 

## Verification
See aws/language-servers#1037, for a demo of the
e2e button hookup working.

---

- Treat all work as PUBLIC. Private `feature/x` branches will not be
squash-merged at release time.
- Your code changes must meet the guidelines in
[CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines).
- License: I confirm that my contribution is made under the terms of the
Apache 2.0 license.
@Hweinstock Hweinstock merged commit c6bb6c5 into aws:main Apr 22, 2025
7 checks passed
@Hweinstock Hweinstock deleted the buttonEvent branch April 22, 2025 13:03
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