-
Notifications
You must be signed in to change notification settings - Fork 274
config(amazonq): Add project context to inline completion #4976
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
Conversation
...tware/aws/toolkits/jetbrains/services/cwc/editor/context/project/ProjectContextController.kt
Fixed
Show fixed
Hide fixed
...e/aws/toolkits/jetbrains/services/codewhisperer/service/CodeWhispererFeatureConfigService.kt
Fixed
Show fixed
Hide fixed
...oftware/aws/toolkits/jetbrains/services/cwc/editor/context/project/ProjectContextProvider.kt
Outdated
Show resolved
Hide resolved
...tware/aws/toolkits/jetbrains/services/codewhisperer/util/CodeWhispererFileContextProvider.kt
Fixed
Show fixed
Hide fixed
| } | ||
|
|
||
| // takeLast(11) will extract 10 lines (exclusing current line) of left context as the query parameter | ||
| fun generateQuery(fileContext: FileContextInfo) = fileContext.caretContext.leftFileContext.split("\n").takeLast(11).joinToString("\n") |
Check notice
Code scanning / QDJVMC
Class member can have 'private' visibility Note
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i wanna add test for this query fun later so leave it public for now.
...src/software/aws/toolkits/jetbrains/services/amazonq/project/ProjectContextEditorListener.kt
Show resolved
Hide resolved
...unity/src/software/aws/toolkits/jetbrains/services/amazonq/project/ProjectContextProvider.kt
Show resolved
Hide resolved
...ware/aws/toolkits/jetbrains/services/amazonq/workspace/context/ProjectContextProviderTest.kt
Show resolved
Hide resolved
|
unit test fixes. change log item like vsc |
| } | ||
| } | ||
|
|
||
| private object NaiveSampleCase { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can also just make a folder in testData
https://plugins.jetbrains.com/docs/intellij/test-project-and-testdata-directories.html#testdata-files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sg, thanks for the info richard, i will do it in a followup
...unity/src/software/aws/toolkits/jetbrains/services/amazonq/project/ProjectContextProvider.kt
Outdated
Show resolved
Hide resolved
...unity/src/software/aws/toolkits/jetbrains/services/amazonq/project/ProjectContextProvider.kt
Outdated
Show resolved
Hide resolved
|
test failed due to |
|
thread leak fix #5003 |
Description
Prerequisite
License
I confirm that my contribution is made under the terms of the Apache 2.0 license.