diff --git a/.continue/mcpServers/continue-docs-mcp.yaml b/.continue/mcpServers/continue-docs-mcp.yaml deleted file mode 100644 index a295b5546..000000000 --- a/.continue/mcpServers/continue-docs-mcp.yaml +++ /dev/null @@ -1,11 +0,0 @@ -name: Continue Documentation MCP -version: 0.0.1 -schema: v1 -mcpServers: - - name: Continue Docs Search - type: stdio - command: npx - args: - - mint-mcp - - add - - continue-docs diff --git a/.continue/rules/typescript-enum-usage.md b/.continue/rules/typescript-enum-usage.md new file mode 100644 index 000000000..34728c1d5 --- /dev/null +++ b/.continue/rules/typescript-enum-usage.md @@ -0,0 +1,6 @@ +--- +globs: "**/*.{ts,tsx}" +alwaysApply: false +--- + +Use enums instead of simple string unions when possible in TypeScript code diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 4a0595a38..cc85d0d0a 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -11,6 +11,8 @@ body: attributes: label: Before submitting your bug report options: + - label: I've tried using the "Ask AI" feature on the [Continue docs site](https://docs.continue.dev/) to see if the docs have an answer + required: false - label: I believe this is a bug. I'll try to join the [Continue Discord](https://discord.gg/NWtdYexhMs) for questions required: false - label: I'm not able to find an [open issue](https://github.com/continuedev/continue/issues?q=is%3Aopen+is%3Aissue) that reports the same bug diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 2497e28dc..348566cd8 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -8,9 +8,9 @@ - [] The relevant docs, if any, have been updated or created - [] The relevant tests, if any, have been updated or created -## Screenshots +## Screen recording or screenshot -[ For visual changes, include screenshots. Screen recordings are particularly helpful, and appreciated! ] +[ When applicable, please include a short screen recording or screenshot - this makes it much easier for us as contributors to review and understand your changes. See [this PR](https://github.com/continuedev/continue/pull/6455) as a good example. ] ## Tests diff --git a/.github/workflows/cla.yaml b/.github/workflows/cla.yaml index 5d5ce3933..225439ced 100644 --- a/.github/workflows/cla.yaml +++ b/.github/workflows/cla.yaml @@ -24,7 +24,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: path-to-signatures: "signatures/version1/cla.json" - path-to-document: "https://github.com/continuedev/continue/blob/main/docs/docs/CLA.md" + path-to-document: "https://github.com/continuedev/continue/blob/main/CLA.md" branch: cla-signatures # Bots and CLAs signed outside of GitHub allowlist: dependabot[bot],fbricon,panyamkeerthana,Jazzcort,owtaylor,halfline diff --git a/.github/workflows/compliance.yaml b/.github/workflows/compliance.yaml index 13dbdc9f3..1c4adce0c 100644 --- a/.github/workflows/compliance.yaml +++ b/.github/workflows/compliance.yaml @@ -31,6 +31,8 @@ jobs: uses: wagoid/commitlint-github-action@v6 with: configFile: .commitlintrc.warning.json + # Only check the last commit instead of all commits in the PR + commitDepth: 1 continue-on-error: true - name: Add commit message guidance comment @@ -57,7 +59,7 @@ jobs: body: [ "## ⚠️ Conventional Commit Format", "", - "Your commit messages don't follow the conventional commit format, but **this won't block your PR from being merged**. We recommend downloading [this extension](https://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commits) if you are using VS Code.", + "Your latest commit message doesn't follow the conventional commit format, but **this won't block your PR from being merged**. We recommend downloading [this extension](https://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commits) if you are using VS Code.", "", "### Expected Format:", "```", diff --git a/.github/workflows/jetbrains-release.yaml b/.github/workflows/jetbrains-release.yaml index 956d249c4..531129c79 100644 --- a/.github/workflows/jetbrains-release.yaml +++ b/.github/workflows/jetbrains-release.yaml @@ -63,7 +63,6 @@ jobs: - name: Bump version in gradle.properties run: | - cd extensions/intellij awk '/pluginVersion=/{split($0,a,"="); split(a[2],b,"."); b[3]+=1; printf "%s=%s.%s.%s\n",a[1],b[1],b[2],b[3];next}1' gradle.properties > tmp && mv tmp gradle.properties rm -rf tmp NEW_VERSION=$(grep 'pluginVersion=' gradle.properties | cut -d'=' -f2) @@ -224,10 +223,6 @@ jobs: # apple-product-id: dev.continue.continue-binary # options: --options runtime --entitlements entitlements.xml - # Build plugin - - name: Build plugin - run: ./gradlew buildPlugin - # Publish the plugin to JetBrains Marketplace - name: Publish EAP Plugin if: github.event_name == 'release' || github.event.inputs.publish_build == 'true' @@ -237,7 +232,7 @@ jobs: PRIVATE_KEY: ${{ secrets.JETBRAINS_PRIVATE_KEY }} PRIVATE_KEY_PASSWORD: ${{ secrets.JETBRAINS_PRIVATE_KEY_PASSWORD }} RELEASE_CHANNEL: eap - run: ./gradlew publishPlugin + run: ./gradlew publishPlugin --info --stacktrace - name: Publish Stable Plugin if: github.event_name == 'release' || github.event.inputs.publish_build == 'true' @@ -247,7 +242,7 @@ jobs: PRIVATE_KEY: ${{ secrets.JETBRAINS_PRIVATE_KEY }} PRIVATE_KEY_PASSWORD: ${{ secrets.JETBRAINS_PRIVATE_KEY_PASSWORD }} RELEASE_CHANNEL: default - run: ./gradlew publishPlugin + run: ./gradlew publishPlugin --info --stacktrace # Prepare plugin archive content for creating artifact - name: Prepare Plugin Artifact diff --git a/.github/workflows/metrics.yaml b/.github/workflows/metrics.yaml index 1ee476aaf..ba4e1cd4a 100644 --- a/.github/workflows/metrics.yaml +++ b/.github/workflows/metrics.yaml @@ -50,7 +50,7 @@ jobs: echo "metrics_content=$content" >> "$GITHUB_OUTPUT" - name: Post a message in a channel - uses: slackapi/slack-github-action@v2.1.0 + uses: slackapi/slack-github-action@v2.1.1 with: webhook: ${{ secrets.ISSUE_PR_METRICS_SLACK_WEBHOOK_URL }} webhook-type: incoming-webhook diff --git a/.github/workflows/pr_checks.yaml b/.github/workflows/pr_checks.yaml index 36eebc970..b4333890d 100644 --- a/.github/workflows/pr_checks.yaml +++ b/.github/workflows/pr_checks.yaml @@ -50,7 +50,10 @@ jobs: install-config-yaml: needs: install-root - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] steps: - uses: actions/checkout@v4 @@ -77,7 +80,10 @@ jobs: install-openai-adapters: needs: install-root - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] steps: - uses: actions/checkout@v4 @@ -133,7 +139,10 @@ jobs: install-core: needs: install-root - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] steps: - uses: actions/checkout@v4 @@ -381,7 +390,10 @@ jobs: install-vscode: needs: [install-root, install-core, install-config-yaml, install-openai-adapters] - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] steps: - uses: actions/checkout@v4 @@ -572,6 +584,43 @@ jobs: cd packages/config-yaml npm test + openai-adapters-tests: + needs: install-openai-adapters + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4 + with: + node-version-file: ".nvmrc" + + - uses: actions/cache@v4 + with: + path: node_modules + key: ${{ runner.os }}-root-node-modules-${{ hashFiles('package-lock.json') }} + + - uses: actions/cache@v4 + id: openai-adapters-cache + with: + path: packages/openai-adapters/node_modules + key: ${{ runner.os }}-openai-adapters-node-modules-${{ hashFiles('packages/openai-adapters/package-lock.json') }} + + - name: Run openai-adapters tests + run: | + cd packages/openai-adapters + npm test + env: + IGNORE_API_KEY_TESTS: ${{ github.event.pull_request.head.repo.fork == true || github.actor == 'dependabot[bot]' }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }} + AZURE_FOUNDRY_CODESTRAL_API_KEY: ${{ secrets.AZURE_FOUNDRY_CODESTRAL_API_KEY }} + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: ${{ secrets.AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY }} + AZURE_OPENAI_GPT41_API_KEY: ${{ secrets.AZURE_OPENAI_GPT41_API_KEY }} + VOYAGE_API_KEY: ${{ secrets.VOYAGE_API_KEY }} + vscode-get-test-file-matrix: runs-on: ubuntu-latest needs: [install-root, install-vscode, install-config-yaml] @@ -613,13 +662,19 @@ jobs: echo "test_file_matrix<> $GITHUB_OUTPUT echo "$FILES" >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT + env: + # https://github.com/microsoft/vscode-ripgrep/issues/9#issuecomment-643965333 + GITHUB_TOKEN: ${{ secrets.CI_GITHUB_TOKEN }} - name: Debug Outputs run: | echo "Test files: ${{ steps.vscode-get-test-file-matrix.outputs.test_file_matrix }}" vscode-package-extension: - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] needs: [ install-vscode, @@ -676,7 +731,7 @@ jobs: - name: Upload build artifact uses: actions/upload-artifact@v4 with: - name: vscode-extension-build + name: vscode-extension-build-${{ runner.os }} path: extensions/vscode/build vscode-download-e2e-dependencies: @@ -772,7 +827,7 @@ jobs: - name: Download build artifact uses: actions/download-artifact@v4 with: - name: vscode-extension-build + name: vscode-extension-build-Linux path: extensions/vscode/build - name: Download e2e dependencies @@ -1068,6 +1123,7 @@ jobs: - config-yaml-checks - install-config-yaml - install-openai-adapters + - openai-adapters-tests steps: - name: Decide whether the needed jobs succeeded or failed diff --git a/.github/workflows/release-config-yaml.yml b/.github/workflows/release-config-yaml.yml index f0d220ed0..fea1c31d4 100644 --- a/.github/workflows/release-config-yaml.yml +++ b/.github/workflows/release-config-yaml.yml @@ -6,6 +6,13 @@ on: - main paths: - "packages/config-yaml/**" + - ".github/workflows/release-config-yaml.yml" + - ".github/workflows/reusable-release.yml" + +permissions: + contents: write + issues: write + pull-requests: write jobs: release: @@ -16,3 +23,12 @@ jobs: secrets: SEMANTIC_RELEASE_GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN }} SEMANTIC_RELEASE_NPM_TOKEN: ${{ secrets.SEMANTIC_RELEASE_NPM_TOKEN }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }} + AZURE_FOUNDRY_CODESTRAL_API_KEY: ${{ secrets.AZURE_FOUNDRY_CODESTRAL_API_KEY }} + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: ${{ secrets.AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY }} + AZURE_OPENAI_GPT41_API_KEY: ${{ secrets.AZURE_OPENAI_GPT41_API_KEY }} + VOYAGE_API_KEY: ${{ secrets.VOYAGE_API_KEY }} diff --git a/.github/workflows/release-fetch.yml b/.github/workflows/release-fetch.yml index 2fa1124bc..fb4636a21 100644 --- a/.github/workflows/release-fetch.yml +++ b/.github/workflows/release-fetch.yml @@ -6,6 +6,13 @@ on: - main paths: - "packages/fetch/**" + - ".github/workflows/release-fetch.yml" + - ".github/workflows/reusable-release.yml" + +permissions: + contents: write + issues: write + pull-requests: write jobs: release: @@ -16,3 +23,12 @@ jobs: secrets: SEMANTIC_RELEASE_GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN }} SEMANTIC_RELEASE_NPM_TOKEN: ${{ secrets.SEMANTIC_RELEASE_NPM_TOKEN }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }} + AZURE_FOUNDRY_CODESTRAL_API_KEY: ${{ secrets.AZURE_FOUNDRY_CODESTRAL_API_KEY }} + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: ${{ secrets.AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY }} + AZURE_OPENAI_GPT41_API_KEY: ${{ secrets.AZURE_OPENAI_GPT41_API_KEY }} + VOYAGE_API_KEY: ${{ secrets.VOYAGE_API_KEY }} diff --git a/.github/workflows/release-llm-info.yml b/.github/workflows/release-llm-info.yml index 1b1c044dc..7a94eba59 100644 --- a/.github/workflows/release-llm-info.yml +++ b/.github/workflows/release-llm-info.yml @@ -16,3 +16,11 @@ jobs: secrets: SEMANTIC_RELEASE_GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN }} SEMANTIC_RELEASE_NPM_TOKEN: ${{ secrets.SEMANTIC_RELEASE_NPM_TOKEN }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }} + AZURE_FOUNDRY_CODESTRAL_API_KEY: ${{ secrets.AZURE_FOUNDRY_CODESTRAL_API_KEY }} + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: ${{ secrets.AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY }} + AZURE_OPENAI_GPT41_API_KEY: ${{ secrets.AZURE_OPENAI_GPT41_API_KEY }} \ No newline at end of file diff --git a/.github/workflows/release-openai-adapters.yml b/.github/workflows/release-openai-adapters.yml index ce7f4fda8..e2a6b0622 100644 --- a/.github/workflows/release-openai-adapters.yml +++ b/.github/workflows/release-openai-adapters.yml @@ -6,6 +6,13 @@ on: - main paths: - "packages/openai-adapters/**" + - ".github/workflows/release-openai-adapters.yml" + - ".github/workflows/reusable-release.yml" + +permissions: + contents: write + issues: write + pull-requests: write jobs: release: @@ -16,3 +23,12 @@ jobs: secrets: SEMANTIC_RELEASE_GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN }} SEMANTIC_RELEASE_NPM_TOKEN: ${{ secrets.SEMANTIC_RELEASE_NPM_TOKEN }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }} + AZURE_FOUNDRY_CODESTRAL_API_KEY: ${{ secrets.AZURE_FOUNDRY_CODESTRAL_API_KEY }} + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: ${{ secrets.AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY }} + AZURE_OPENAI_GPT41_API_KEY: ${{ secrets.AZURE_OPENAI_GPT41_API_KEY }} + VOYAGE_API_KEY: ${{ secrets.VOYAGE_API_KEY }} diff --git a/.github/workflows/reusable-release.yml b/.github/workflows/reusable-release.yml index 7de9d7320..80d135e29 100644 --- a/.github/workflows/reusable-release.yml +++ b/.github/workflows/reusable-release.yml @@ -14,6 +14,24 @@ on: required: true SEMANTIC_RELEASE_NPM_TOKEN: required: true + OPENAI_API_KEY: + required: false + ANTHROPIC_API_KEY: + required: false + GEMINI_API_KEY: + required: false + MISTRAL_API_KEY: + required: false + AZURE_OPENAI_API_KEY: + required: false + AZURE_FOUNDRY_CODESTRAL_API_KEY: + required: false + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: + required: false + AZURE_OPENAI_GPT41_API_KEY: + required: false + VOYAGE_API_KEY: + required: false permissions: contents: write @@ -46,10 +64,20 @@ jobs: - name: Run tests run: npm test + env: + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }} + AZURE_FOUNDRY_CODESTRAL_API_KEY: ${{ secrets.AZURE_FOUNDRY_CODESTRAL_API_KEY }} + AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY: ${{ secrets.AZURE_FOUNDRY_MISTRAL_SMALL_API_KEY }} + AZURE_OPENAI_GPT41_API_KEY: ${{ secrets.AZURE_OPENAI_GPT41_API_KEY }} + VOYAGE_API_KEY: ${{ secrets.VOYAGE_API_KEY }} - name: Release env: GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN }} NPM_TOKEN: ${{ secrets.SEMANTIC_RELEASE_NPM_TOKEN }} NODE_AUTH_TOKEN: ${{ secrets.SEMANTIC_RELEASE_NPM_TOKEN }} - run: npx semantic-release \ No newline at end of file + run: npx semantic-release diff --git a/.idea/gradle.xml b/.idea/gradle.xml index c277e816e..324ac997a 100644 --- a/.idea/gradle.xml +++ b/.idea/gradle.xml @@ -5,7 +5,7 @@