Skip to content

Commit 963713d

Browse files
Merge branch 'main' into index-fixes
2 parents c5e6290 + ca5463f commit 963713d

File tree

344 files changed

+7209
-3487
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

344 files changed

+7209
-3487
lines changed
+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
## 0.0.92 - 2025-02-26
2+
### Fixed
3+
* Off-screen rendering to solve white flash on load and lack of changing cursor type
4+
* OSR-related fixes for non-Mac users
5+
* Fixes for inline edit in JetBrains

.changes/extensions/intellij/1.0.0.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
## 1.0.0 - 2025-02-26
2+
### Added
3+
* Introduces hub.continue.dev
4+
* Improved theme matching
5+
### Fixed
6+
* Fixes interference between SonarQube and Continue autocomplete
7+
* Numerous reliability improvements

.changes/extensions/vscode/1.0.0.md

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
## 1.0.0 - 2025-02-26
2+
### Added
3+
* Introduces hub.continue.dev
4+
* Improved apply quality
5+
### Fixed
6+
* Numerous reliability improvements

.changes/unreleased/Fixed-20241007-183820.yaml

-5
This file was deleted.

.changes/unreleased/Fixed-20241108-114322.yaml

-4
This file was deleted.

.changes/unreleased/Fixed-20241108-114707.yaml

-4
This file was deleted.

.continue/prompts/core-unit-test.prompt

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Generate unit tests for core utilities
44
Write jest tests for the provided code.
55
Use jest version ^29 (e.g. jest 29.7.0)
66

7-
Use best practices. Be clear and consise.
7+
Use best practices. Be clear and concise.
88
Aim for 100% code coverage where reasonable.
99
Multiple tests can be written, split up tests for best clarity and readability.
1010
Only use typescript, and if the file/code is not typescript, warn the user.
@@ -15,7 +15,7 @@ Use double quotes (or backticks if needed) for strings
1515
The code being tested is used in IDE extensions, and it:
1616
- accesses code workspaces through the IDE ("workspace directories")
1717
- persists extension-related data to the the local machine of the user ("global directory"), and
18-
- uses configuration via a `ConfigHandler`, which is stored in either the global directory (default) or accesed via a remote "control plane" using the `ControlPlaneClient`
18+
- uses configuration via a `ConfigHandler`, which is stored in either the global directory (default) or accessed via a remote "control plane" using the `ControlPlaneClient`
1919

2020
Jest testing setup includes
2121
- @core/test/jest.global-setup.ts initializes a temporary global directory, which is where files that store persisted extension data live.
@@ -31,7 +31,7 @@ Jest testing setup includes
3131

3232
Do NOT write tests for any files in `core/test`, only use them as helpers for testing other files. If no other files are provided, warn the user and write no tests.
3333

34-
IMPORTANT: Do NOT mock the fixtures above other than using `jest.spyOn`. DO mock 3rd party modules, etc. when sensible.
34+
IMPORTANT: Do NOT mock the fixtures above other than using `jest.spyOn`. DO mock 3rd party modules, etc. when sensible.
3535
Instead, generate actual mock files and data for operations
3636
Pure mocks should only be used to emulate specific network responses/error or hard-to-duplicate errors, or to prevent long-duration tests
3737

.github/ISSUE_TEMPLATE/bug_report.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@ body:
2727
- **Continue version**: v0.9.4
2828
- **IDE version**: VSCode 1.85.1
2929
- Model: Claude Sonnet 3.5
30-
- config.yaml: `models: ...`
31-
- OR config.json: `{ "models": ... }`
30+
- Assistant configuration
3231
value: |
3332
- OS:
3433
- Continue version:
@@ -38,6 +37,7 @@ body:
3837
```yaml
3938
4039
```
40+
OR link to assistant in Continue hub:
4141
render: Markdown
4242
validations:
4343
required: false

.github/workflows/jetbrains-release.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
- id: check
3232
working-directory: .
3333
run: |
34-
if [[ "${{ github.event.release.tag_name }}" == v0.0.*-jetbrains ]]; then
34+
if [[ "${{ github.event.release.tag_name }}" == v1.0.*-jetbrains ]]; then
3535
echo "should_run=true" >> $GITHUB_OUTPUT
3636
else
3737
echo "should_run=false" >> $GITHUB_OUTPUT

.github/workflows/main.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
- id: check
2121
working-directory: .
2222
run: |
23-
if [[ "${{ github.event.release.tag_name }}" == v0.8.*-vscode ]]; then
23+
if [[ "${{ github.event.release.tag_name }}" == v1.0.*-vscode ]]; then
2424
echo "should_run=true" >> $GITHUB_OUTPUT
2525
else
2626
echo "should_run=false" >> $GITHUB_OUTPUT

.github/workflows/pr_checks.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
pull_request:
55
branches:
66
- main
7+
- staging
78

89
push:
910
branches:
1011
- main
12+
- staging
1113

1214
jobs:
1315
install-root:

.github/workflows/preview.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
- id: check
2121
working-directory: .
2222
run: |
23-
if [[ "${{ github.event.release.tag_name }}" == v0.9.*-vscode ]]; then
23+
if [[ "${{ github.event.release.tag_name }}" == v1.1.*-vscode ]]; then
2424
echo "should_run=true" >> $GITHUB_OUTPUT
2525
else
2626
echo "should_run=false" >> $GITHUB_OUTPUT
@@ -217,8 +217,8 @@ jobs:
217217
git config --local user.email "[email protected]"
218218
git config --local user.name "GitHub Action"
219219
220-
- name: Pull latest changes
221-
run: git pull origin main
220+
- name: Pull latest changes from release
221+
run: git fetch origin ${{ github.ref }} && git checkout ${{ github.ref }}
222222

223223
# 1. Download the artifacts
224224
- uses: actions/download-artifact@v4

.vscode/launch.json

+19
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,25 @@
138138
"env": {
139139
"NODE_OPTIONS": "--experimental-vm-modules"
140140
}
141+
},
142+
{
143+
"name": "[config-yaml] Jest Test Debugger, Current Open File",
144+
"type": "node",
145+
"request": "launch",
146+
"runtimeArgs": [
147+
"--inspect-brk",
148+
"${workspaceRoot}/packages/config-yaml/node_modules/jest/bin/jest.js",
149+
"--runInBand",
150+
"--config",
151+
"${workspaceRoot}/packages/config-yaml/jest.config.mjs",
152+
"${relativeFile}"
153+
],
154+
"cwd": "${workspaceRoot}/packages/config-yaml",
155+
"console": "integratedTerminal",
156+
"internalConsoleOptions": "neverOpen",
157+
"env": {
158+
"NODE_OPTIONS": "--experimental-vm-modules"
159+
}
141160
}
142161
]
143162
}

.vscode/settings.json

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313
"args": ["-l"]
1414
}
1515
},
16+
"editor.codeActionsOnSave": {
17+
"source.organizeImports": "explicit"
18+
},
1619
"editor.defaultFormatter": "esbenp.prettier-vscode",
1720
"search.exclude": {
1821
"**/package-lock.json": true,

.vscode/tasks.json

+21-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,27 @@
7171
}
7272
]
7373
},
74-
// Build the React app. It gets bundled into the extension as a file resource and has a seprate build step
74+
{
75+
"label": "vscode-extension:package",
76+
"dependsOn": ["vscode-extension:esbuild"],
77+
"type": "npm",
78+
"script": "package",
79+
"path": "extensions/vscode",
80+
"problemMatcher": [
81+
{
82+
"pattern": [
83+
{
84+
"regexp": "> (.*?):([0-9]+):([0-9]+): (warning|error): (.+)$",
85+
"file": 1,
86+
"line": 2,
87+
"column": 3,
88+
"severity": 4,
89+
"message": 5
90+
}
91+
]
92+
}
93+
]
94+
},
7595
{
7696
"label": "vscode-extension:continue-ui:build",
7797
"type": "shell",

CONTRIBUTING.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ nvm use
128128
1. The new VS Code window with the extension is referred to as the _Host VS Code_
129129
2. The window you started debugging from is referred to as the _Main VS Code_
130130

131-
3. To package the extension, run `npm run package` in the `extensions/vscode` directory. This will generate `extensions/vscode/build/continue-{VERSION}.vsix`, which you can install by right-clicking and selecting "Install Extension VSIX".
131+
3. To package the extension, run `npm run package` in the `extensions/vscode` directory, select `Tasks: Run Task` and then select `vscode-extension:package`. This will generate `extensions/vscode/build/continue-{VERSION}.vsix`, which you can install by right-clicking and selecting "Install Extension VSIX".
132132

133133
##### Debugging
134134

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
<div align="center">
1010

11-
**[Continue](https://docs.continue.dev) is the leading open-source AI code assistant. You can connect any models and any context to build custom autocomplete and chat experiences inside [VS Code](https://marketplace.visualstudio.com/items?itemName=Continue.continue) and [JetBrains](https://plugins.jetbrains.com/plugin/22707-continue-extension)**
11+
**[Continue](https://docs.continue.dev) enables to developers to create, share, and use custom AI code assistants with our open-source [VS Code](https://marketplace.visualstudio.com/items?itemName=Continue.continue) and [JetBrains](https://plugins.jetbrains.com/plugin/22707-continue-extension) extensions and [hub of models, rules, prompts, docs, and other building blocks](https://hub.continue.dev)**
1212

1313
</div>
1414

@@ -46,7 +46,7 @@
4646

4747
## Actions
4848

49-
[Actions](https://continue.dev/docs/actions/how-to-use-it) are shortcuts for common use cases.
49+
[Actions](https://continue.dev/docs/actions/how-to-use-it) are shortcuts for common use cases
5050

5151
![actions](docs/static/img/actions.gif)
5252

binary/build.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ async function installNodeModuleInTempDirAndCopyToCurrent(packageName, toCopy) {
285285

286286
// Informs the `continue-binary` of where to look for node_sqlite3.node
287287
// https://www.npmjs.com/package/bindings#:~:text=The%20searching%20for,file%20is%20found
288-
// fs.writeFileSync(`${targetDir}/package.json`, "");
288+
fs.writeFileSync(`${targetDir}/package.json`, "");
289289
}
290290

291291
// Cleanup - this is needed when running locally

binary/core-dev-server.js

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
const path = require('path');
2+
process.env.CONTINUE_DEVELOPMENT = true;
3+
4+
process.env.CONTINUE_GLOBAL_DIR = path.join(process.env.PROJECT_DIR, 'extensions', '.continue-debug');
5+
6+
require('./out/index.js');

binary/package-lock.json

+4-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

binary/prompt-logs.js

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
const fs = require('fs');
2+
const path = require('path');
3+
4+
const logDirPath = path.join(__dirname, '..', 'extensions', '.continue-debug', 'logs');
5+
const logFilePath = path.join(logDirPath, "prompt.log");
6+
7+
if (!fs.existsSync(logDirPath)) {
8+
fs.mkdirSync(logDirPath, { recursive: true });
9+
}
10+
11+
if (!fs.existsSync(logFilePath)) {
12+
fs.createWriteStream(logFilePath).end();
13+
}
14+
15+
console.log("Watching logs at " + logFilePath)
16+
17+
fs.watch(logFilePath, () => {
18+
// console.clear();
19+
fs.createReadStream(logFilePath).pipe(process.stdout);
20+
});

core/autocomplete/CompletionProvider.ts

+7-8
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,13 @@ export class CompletionProvider {
134134
token: AbortSignal | undefined,
135135
): Promise<AutocompleteOutcome | undefined> {
136136
try {
137+
// Create abort signal if not given
138+
if (!token) {
139+
const controller = this.loggingService.createAbortController(
140+
input.completionId,
141+
);
142+
token = controller.signal;
143+
}
137144
const startTime = Date.now();
138145
const options = await this._getAutocompleteOptions();
139146

@@ -158,14 +165,6 @@ export class CompletionProvider {
158165
return undefined;
159166
}
160167

161-
// Create abort signal if not given
162-
if (!token) {
163-
const controller = this.loggingService.createAbortController(
164-
input.completionId,
165-
);
166-
token = controller.signal;
167-
}
168-
169168
const [snippetPayload, workspaceDirs] = await Promise.all([
170169
getAllSnippets({
171170
helper,

core/autocomplete/constants/AutocompleteLanguageInfo.ts

+10
Original file line numberDiff line numberDiff line change
@@ -240,6 +240,14 @@ export const Solidity = {
240240
endOfLine: [";"],
241241
};
242242

243+
// Lua
244+
export const Lua = {
245+
name: "Lua",
246+
topLevelKeywords: ["function"],
247+
singleLineComment: "--",
248+
endOfLine: [],
249+
};
250+
243251
// YAML
244252
export const YAML: AutocompleteLanguageInfo = {
245253
name: "YAML",
@@ -367,6 +375,8 @@ export const LANGUAGES: { [extension: string]: AutocompleteLanguageInfo } = {
367375
yaml: YAML,
368376
yml: YAML,
369377
md: Markdown,
378+
lua: Lua,
379+
luau: Lua,
370380
};
371381

372382
export function languageForFilepath(fileUri: string): AutocompleteLanguageInfo {

core/autocomplete/templating/AutocompleteTemplate.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,8 @@ export function getTemplateForModel(model: string): AutocompleteTemplate {
399399
lowerCaseModel.includes("gpt") ||
400400
lowerCaseModel.includes("davinci-002") ||
401401
lowerCaseModel.includes("claude") ||
402-
lowerCaseModel.includes("granite3")
402+
lowerCaseModel.includes("granite3") ||
403+
lowerCaseModel.includes("granite-3")
403404
) {
404405
return holeFillerTemplate;
405406
}

core/autocomplete/util/AutocompleteLoggingService.ts

+9-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { logDevData } from "../../util/devdata";
1+
import { DataLogger } from "../../data/log";
22
import { COUNT_COMPLETION_REJECTED_AFTER } from "../../util/parameters";
33
import { Telemetry } from "../../util/posthog";
44
import { getUriFileExtension } from "../../util/uri";
@@ -96,7 +96,14 @@ export class AutocompleteLoggingService {
9696
}
9797

9898
private logAutocompleteOutcome(outcome: AutocompleteOutcome) {
99-
logDevData("autocomplete", outcome);
99+
void DataLogger.getInstance().logDevData({
100+
name: "autocomplete",
101+
data: {
102+
...outcome,
103+
useFileSuffix: true, // from outdated schema
104+
},
105+
});
106+
100107
const { prompt, completion, prefix, suffix, ...restOfOutcome } = outcome;
101108
void Telemetry.capture(
102109
"autocomplete",

0 commit comments

Comments
 (0)