Compare commits

..

291 Commits

Author SHA1 Message Date
Michael Hohn
390dfeb087 refactor cli 2025-03-15 18:12:04 -07:00
Michael Hohn
012e597d4a refactor cli 2025-03-15 18:09:29 -07:00
Michael Hohn
cd568db7b4 refactor cli 2025-03-15 18:06:26 -07:00
Michael Hohn
dc745dd8e1 refactor cli 2025-03-15 18:02:25 -07:00
Michael Hohn
29d6b127e2 refactor cli 2025-03-15 18:00:00 -07:00
Michael Hohn
1cbfba32a0 refactor cli 2025-03-15 17:43:55 -07:00
Michael Hohn
c2b2d10591 refactor cli 2025-03-15 17:43:14 -07:00
Michael Hohn
1fe4abf6e8 refactor cli 2025-03-15 17:42:28 -07:00
Michael Hohn
efaef8a2cb refactor cli 2025-03-15 17:40:54 -07:00
Michael Hohn
a8d61a605a refactor cli 2025-03-15 17:36:35 -07:00
Michael Hohn
e44024763d refactor cli 2025-03-15 17:24:46 -07:00
Michael Hohn
9a6aa52a40 fix: reconciled status names between server/agent/vscode-codeql
Some checks failed
Update Node version / Create PR (push) Has been cancelled
Run CLI tests / Find Nightly Release (push) Has been cancelled
Run CLI tests / Set Matrix for cli-test (push) Has been cancelled
Run CLI tests / CLI Test (push) Has been cancelled
Run CLI tests / Report failure on the default branch (push) Has been cancelled
Code Scanning - CodeQL / codeql (push) Has been cancelled
Bump CLI version / Build (push) Has been cancelled
2025-03-14 12:45:36 -07:00
Michael Hohn
c106903f01 wip: update settings, push new images 2025-02-20 10:30:22 -08:00
Nicolas Will
d40cda150c WIP: standalone MRVA 2024-07-01 18:20:23 +02:00
Nora
d4df484acb Merge pull request #3645 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-445e2aa325
Bump the storybook group in /extensions/ql-vscode with 12 updates
2024-06-21 09:26:31 +02:00
Nora
3e1d924110 Merge pull request #3646 from github/dependabot/npm_and_yarn/extensions/ql-vscode/testing-library-f694122557
Bump @testing-library/jest-dom from 6.4.5 to 6.4.6 in /extensions/ql-vscode in the testing-library group
2024-06-21 09:26:06 +02:00
dependabot[bot]
cc4666a614 Bump @testing-library/jest-dom
Bumps the testing-library group in /extensions/ql-vscode with 1 update: [@testing-library/jest-dom](https://github.com/testing-library/jest-dom).


Updates `@testing-library/jest-dom` from 6.4.5 to 6.4.6
- [Release notes](https://github.com/testing-library/jest-dom/releases)
- [Changelog](https://github.com/testing-library/jest-dom/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/jest-dom/compare/v6.4.5...v6.4.6)

---
updated-dependencies:
- dependency-name: "@testing-library/jest-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-20 13:19:50 +00:00
dependabot[bot]
51906bbcee Bump the storybook group in /extensions/ql-vscode with 12 updates
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.1.8` | `8.1.10` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.1.8` | `8.1.10` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.1.8` | `8.1.10` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.1.8` | `8.1.10` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.1.8` | `8.1.10` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.1.8` | `8.1.10` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.1.8` | `8.1.10` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.1.8` | `8.1.10` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.1.8` | `8.1.10` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.1.8` | `8.1.10` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.1.8` | `8.1.10` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.1.8` | `8.1.10` |


Updates `@storybook/addon-a11y` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/addons/interactions)

Updates `@storybook/addon-links` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/addons/links)

Updates `@storybook/blocks` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/ui/blocks)

Updates `@storybook/components` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/ui/components)

Updates `@storybook/manager-api` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/lib/manager-api)

Updates `@storybook/react` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/renderers/react)

Updates `@storybook/react-vite` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/lib/theming)

Updates `storybook` from 8.1.8 to 8.1.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.10/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-20 13:19:27 +00:00
Robert
fcfa6979e2 Merge pull request #3643 from github/robertbrignull/re-enable-short-paths
Re-enable windows 8.3 paths in tests
2024-06-19 10:20:24 +01:00
Andrew Eisenberg
f0783ed274 Merge pull request #3644 from github/dependabot/npm_and_yarn/extensions/ql-vscode/ws-8.17.1
Bump ws from 8.15.0 to 8.17.1 in /extensions/ql-vscode
2024-06-18 14:33:18 -07:00
dependabot[bot]
fe45e00fb3 Bump ws from 8.15.0 to 8.17.1 in /extensions/ql-vscode
Bumps [ws](https://github.com/websockets/ws) from 8.15.0 to 8.17.1.
- [Release notes](https://github.com/websockets/ws/releases)
- [Commits](https://github.com/websockets/ws/compare/8.15.0...8.17.1)

---
updated-dependencies:
- dependency-name: ws
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-18 21:07:21 +00:00
Robert
4a317d33a9 Enable 8.3 paths in unit tests 2024-06-18 10:08:18 +00:00
Robert
ffc7135c1f Revert "Remove short-paths.test.ts"
This reverts commit 10f4b47019.
2024-06-18 09:31:33 +00:00
Nora
c805b48f18 Merge pull request #3640 from github/nora/update-pr-template
Update vscode-codeql PR template
2024-06-17 17:32:50 +02:00
Nora
e1b95c2f7c Merge pull request #3641 from github/nora/update-outdated-readme-links
Update outdated links in VS Code extension README
2024-06-17 16:54:07 +02:00
Nora
481d2f5404 Remove language preference
Co-authored-by: Charis Kyriakou <charisk@users.noreply.github.com>
2024-06-17 09:22:55 +02:00
Nora
15fa23acb4 Fix grammatical issue
Co-authored-by: Charis Kyriakou <charisk@users.noreply.github.com>
2024-06-17 09:22:27 +02:00
Nora
a625d9aabe Update old links 2024-06-14 15:11:47 +00:00
Nora
cd70b19bb3 Add changelog reminder to PR submit guidance 2024-06-14 14:52:58 +00:00
Nora
7a58084df9 Remove checklist but keep a note on the changelog 2024-06-14 14:50:18 +00:00
Nora
916d16126b Merge pull request #3633 from github/github-action/bump-node-version
Bump Node version to v20.9.0
2024-06-14 14:42:54 +02:00
Nora
a5eb915267 Merge pull request #3632 from github/dependabot/npm_and_yarn/extensions/ql-vscode/ts-unused-exports-10.1.0
Bump ts-unused-exports from 10.0.1 to 10.1.0 in /extensions/ql-vscode
2024-06-14 14:42:44 +02:00
dependabot[bot]
a5440ef482 Bump ts-unused-exports from 10.0.1 to 10.1.0 in /extensions/ql-vscode
Bumps [ts-unused-exports](https://github.com/pzavolinsky/ts-unused-exports) from 10.0.1 to 10.1.0.
- [Changelog](https://github.com/pzavolinsky/ts-unused-exports/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pzavolinsky/ts-unused-exports/commits)

---
updated-dependencies:
- dependency-name: ts-unused-exports
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-14 12:26:39 +00:00
Nora
fc86be7687 Merge branch 'main' into github-action/bump-node-version 2024-06-14 12:24:20 +00:00
Nora
f0909a9d67 Merge pull request #3636 from github/github-action/bump-cli
Bump CLI Version to v2.17.5 for integration tests
2024-06-14 14:23:19 +02:00
Nora
40b5b5ba7e Merge pull request #3639 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-f899e8f28b
Bump the storybook group in /extensions/ql-vscode with 12 updates
2024-06-13 15:50:42 +02:00
dependabot[bot]
fa85bcfad6 Bump the storybook group in /extensions/ql-vscode with 12 updates
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.1.6` | `8.1.8` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.1.6` | `8.1.8` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.1.6` | `8.1.8` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.1.6` | `8.1.8` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.1.6` | `8.1.8` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.1.6` | `8.1.8` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.1.6` | `8.1.8` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.1.6` | `8.1.8` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.1.6` | `8.1.8` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.1.6` | `8.1.8` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.1.6` | `8.1.8` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.1.6` | `8.1.8` |


Updates `@storybook/addon-a11y` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/addons/interactions)

Updates `@storybook/addon-links` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/addons/links)

Updates `@storybook/blocks` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/ui/blocks)

Updates `@storybook/components` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/ui/components)

Updates `@storybook/manager-api` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/lib/manager-api)

Updates `@storybook/react` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/renderers/react)

Updates `@storybook/react-vite` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/lib/theming)

Updates `storybook` from 8.1.6 to 8.1.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.8/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-13 13:36:58 +00:00
Chris Smowton
dd1b054f26 Merge branch 'main' into github-action/bump-cli 2024-06-13 14:33:51 +01:00
Kasper Svendsen
b96cd6c7e1 Merge pull request #3635 from github/kaspersv/clear-pkg-cache-on-dbscheme-changes
Clear query server package cache on dbscheme edits
2024-06-13 13:47:16 +02:00
Kasper Svendsen
b466d2aa36 Merge branch 'main' into kaspersv/clear-pkg-cache-on-dbscheme-changes 2024-06-13 13:34:18 +02:00
Robert
7f6c1ad7f7 Merge pull request #3637 from github/robertbrignull/remove_path_tests
Remove short-paths.test.ts
2024-06-13 12:26:39 +01:00
Robert
10f4b47019 Remove short-paths.test.ts 2024-06-13 11:03:37 +00:00
github-actions[bot]
b31a769fdd Bump CLI version from v2.17.4 to v2.17.5 for integration tests 2024-06-12 17:18:50 +00:00
github-actions[bot]
c4e2f11372 Bump Node version to v20.9.0 2024-06-12 12:25:46 +00:00
Kasper Svendsen
9494d32144 Clear query server package cache on dbscheme edits 2024-06-11 10:55:42 +00:00
Andrew Eisenberg
12555d90c1 Merge pull request #3630 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-a6a5a2e80a
Bump the storybook group in /extensions/ql-vscode with 13 updates
2024-06-06 09:48:18 -07:00
dependabot[bot]
d46e03b4cc Bump the storybook group in /extensions/ql-vscode with 13 updates
Bumps the storybook group in /extensions/ql-vscode with 13 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.1.5` | `8.1.6` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.1.5` | `8.1.6` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.1.5` | `8.1.6` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.1.5` | `8.1.6` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.1.5` | `8.1.6` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.1.5` | `8.1.6` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.1.5` | `8.1.6` |
| [@storybook/csf](https://github.com/ComponentDriven/csf) | `0.1.7` | `0.1.8` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.1.5` | `8.1.6` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.1.5` | `8.1.6` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.1.5` | `8.1.6` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.1.5` | `8.1.6` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.1.5` | `8.1.6` |


Updates `@storybook/addon-a11y` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/addons/interactions)

Updates `@storybook/addon-links` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/addons/links)

Updates `@storybook/blocks` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/ui/blocks)

Updates `@storybook/components` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/ui/components)

Updates `@storybook/csf` from 0.1.7 to 0.1.8
- [Release notes](https://github.com/ComponentDriven/csf/releases)
- [Changelog](https://github.com/ComponentDriven/csf/blob/v0.1.8/CHANGELOG.md)
- [Commits](https://github.com/ComponentDriven/csf/compare/v0.1.7...v0.1.8)

Updates `@storybook/manager-api` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/lib/manager-api)

Updates `@storybook/react` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/renderers/react)

Updates `@storybook/react-vite` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/lib/theming)

Updates `storybook` from 8.1.5 to 8.1.6
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.6/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/csf"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-06 14:20:38 +00:00
dependabot[bot]
f0e2285122 Bump @testing-library/react (#3631)
Bumps the testing-library group in /extensions/ql-vscode with 1 update: [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/react` from 15.0.7 to 16.0.0
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v15.0.7...v16.0.0)

---
updated-dependencies:
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-06 15:16:43 +01:00
Koen Vlaswinkel
f4d0d23170 Merge pull request #3629 from github/github-action/bump-cli
Bump CLI Version to v2.17.4 for integration tests
2024-06-04 10:06:27 +02:00
github-actions[bot]
513fb65560 Bump CLI version from v2.17.3 to v2.17.4 for integration tests 2024-06-03 16:10:31 +00:00
Koen Vlaswinkel
7d353ced9b Merge pull request #3626 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-d4cb5c71ab
Bump the storybook group in /extensions/ql-vscode with 12 updates
2024-05-31 10:09:46 +02:00
dependabot[bot]
be3506d987 Bump the storybook group in /extensions/ql-vscode with 12 updates
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.1.3` | `8.1.5` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.1.3` | `8.1.5` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.1.3` | `8.1.5` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.1.3` | `8.1.5` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.1.3` | `8.1.5` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.1.3` | `8.1.5` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.1.3` | `8.1.5` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.1.3` | `8.1.5` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.1.3` | `8.1.5` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.1.3` | `8.1.5` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.1.3` | `8.1.5` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.1.3` | `8.1.5` |


Updates `@storybook/addon-a11y` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/addons/interactions)

Updates `@storybook/addon-links` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/addons/links)

Updates `@storybook/blocks` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/ui/blocks)

Updates `@storybook/components` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/ui/components)

Updates `@storybook/manager-api` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/lib/manager-api)

Updates `@storybook/react` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/renderers/react)

Updates `@storybook/react-vite` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/lib/theming)

Updates `storybook` from 8.1.3 to 8.1.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.5/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-30 14:06:20 +00:00
dependabot[bot]
3fa6304050 Bump @babel/core from 7.24.4 to 7.24.6 in /extensions/ql-vscode (#3628)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.24.4 to 7.24.6.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.24.6/packages/babel-core)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-30 07:03:18 -07:00
dependabot[bot]
bb40e5bcad Bump ts-jest from 29.1.2 to 29.1.4 in /extensions/ql-vscode (#3627)
Bumps [ts-jest](https://github.com/kulshekhar/ts-jest) from 29.1.2 to 29.1.4.
- [Release notes](https://github.com/kulshekhar/ts-jest/releases)
- [Changelog](https://github.com/kulshekhar/ts-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/kulshekhar/ts-jest/compare/v29.1.2...v29.1.4)

---
updated-dependencies:
- dependency-name: ts-jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-30 07:02:48 -07:00
Koen Vlaswinkel
e2a8ae318b Merge pull request #3625 from github/koesie10/update-test-plan
Update test plan
2024-05-29 11:46:43 +02:00
Koen Vlaswinkel
79867e2f9d Merge pull request #3624 from github/version/bump-to-v1.13.2
Bump version to v1.13.2
2024-05-29 11:46:29 +02:00
Koen Vlaswinkel
1bc13d70ce Update test plan
This fixes the model pack query to account for the new MAD ID in the
`sinkModel` and removes the LLM section.
2024-05-29 11:22:04 +02:00
github-actions[bot]
0bd359997d Bump version to v1.13.2 2024-05-29 09:17:05 +00:00
Koen Vlaswinkel
28a7d1cf34 Merge pull request #3623 from github/v1.13.1
v1.13.1
2024-05-29 11:15:50 +02:00
Koen Vlaswinkel
1572c095ca v1.13.1
Some checks failed
Release / Release (push) Has been cancelled
Release / Publish to VS Code Marketplace (push) Has been cancelled
Release / Publish to Open VSX Registry (push) Has been cancelled
2024-05-29 10:43:56 +02:00
Nick Rolfe
83df05e731 Merge pull request #3622 from github/nickrolfe/eval-log-progress
Report progress for post-evaluation actions
2024-05-28 17:38:56 +01:00
Nick Rolfe
b43b1d4c8e Update changelog for progress reporting on post-evaluation steps 2024-05-28 11:06:00 +00:00
Nick Rolfe
79ff9e0378 Report progress for post-evaluation actions
Generating and parsing log summaries can be quite slow, so we should update the progress window with messages about what's being worked on.
2024-05-28 11:05:34 +00:00
Andrew Eisenberg
d7a82cc686 Merge pull request #3616 from github/aeisenberg/flush-cache-on-db-remove
Fix bug with reimporting test cases
2024-05-23 08:55:23 -07:00
Andrew Eisenberg
39ad5b28c7 Fix typo in comment
Co-authored-by: Koen Vlaswinkel <koesie10@users.noreply.github.com>
2024-05-23 08:43:03 -07:00
Robert
68c159f1fe Merge pull request #3619 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-23a9a17fad
Bump the storybook group in /extensions/ql-vscode with 12 updates
2024-05-23 15:55:29 +01:00
Robert
355a6fc552 Merge pull request #3621 from github/dependabot/npm_and_yarn/extensions/ql-vscode/markdownlint-cli2-formatter-pretty-0.0.6
Bump markdownlint-cli2-formatter-pretty from 0.0.5 to 0.0.6 in /extensions/ql-vscode
2024-05-23 14:52:49 +01:00
dependabot[bot]
6f54bebe35 Bump markdownlint-cli2-formatter-pretty in /extensions/ql-vscode
Bumps [markdownlint-cli2-formatter-pretty](https://github.com/DavidAnson/markdownlint-cli2) from 0.0.5 to 0.0.6.
- [Changelog](https://github.com/DavidAnson/markdownlint-cli2/blob/main/CHANGELOG.md)
- [Commits](https://github.com/DavidAnson/markdownlint-cli2/compare/v0.0.5...v0.0.6)

---
updated-dependencies:
- dependency-name: markdownlint-cli2-formatter-pretty
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-23 13:40:16 +00:00
dependabot[bot]
bea108a412 Bump the storybook group in /extensions/ql-vscode with 12 updates
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.1.1` | `8.1.3` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.1.1` | `8.1.3` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.1.1` | `8.1.3` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.1.1` | `8.1.3` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.1.1` | `8.1.3` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.1.1` | `8.1.3` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.1.1` | `8.1.3` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.1.1` | `8.1.3` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.1.1` | `8.1.3` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.1.1` | `8.1.3` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.1.1` | `8.1.3` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.1.1` | `8.1.3` |


Updates `@storybook/addon-a11y` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/addons/interactions)

Updates `@storybook/addon-links` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/addons/links)

Updates `@storybook/blocks` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/ui/blocks)

Updates `@storybook/components` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/ui/components)

Updates `@storybook/manager-api` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/lib/manager-api)

Updates `@storybook/react` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/renderers/react)

Updates `@storybook/react-vite` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/lib/theming)

Updates `storybook` from 8.1.1 to 8.1.3
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.3/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-23 13:39:25 +00:00
Andrew Eisenberg
088d2fa91e Fix failing tests
Also:
- Address comments in PR
- Add changelog note
2024-05-22 23:05:12 +00:00
Andrew Eisenberg
6c92a5b800 Merge remote-tracking branch 'upstream/main' into aeisenberg/flush-cache-on-db-remove 2024-05-22 22:42:54 +00:00
Robert
db0d062443 Merge pull request #3618 from github/robertbrignull/delete-ghec-dr-flag
Remove the enableGhecDr flag
2024-05-22 11:47:11 +01:00
Robert
673ea13af8 Remove the enableGhecDr flag 2024-05-22 10:42:47 +01:00
Koen Vlaswinkel
2208b42485 Merge pull request #3615 from github/github-action/bump-cli
Bump CLI Version to v2.17.3 for integration tests
2024-05-21 10:47:38 +02:00
Andrew Eisenberg
376d6b75d6 Fix bug with reimporting test cases
When re-importing a test database, if the source archive for that
database is not in the workspace, then old source code will be seen when
inspected.

To reproduce:

1. Run a ql test file with a failure (I'm using a javascript DB).
2. Right click and import on the db that sticks around.
3. Change the JS source file for the test.
4. Re-run and still have a failure.
5. Re-import the database
6. Run the query under test
7. Click on a result item
8. **BUG:** The source code is old

The problem is that the source archive cache is not being flushed in
this case. I added a case to flush the source archive when the archive
was imported into the workspace as a folder, but not when the archive is
external.

The fix is to listen for database remove events in the archive
filesystem provider and flush the associated database source
archive.

There is a complication:

The database remove event didn't emit the removed database. This is
because the only place that consumed the event didn't need it.

To get around this, I changed the structure of the events. I added a
new `fullRefresh` boolean. If true, then the original database change
handler will ensure the entire tree is refreshed. If false, only the
selected database.
2024-05-17 23:10:56 +00:00
dependabot[bot]
d8a7dcd7d2 Bump react-dom and @types/react-dom in /extensions/ql-vscode (#3614)
Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 18.2.0 to 18.3.1
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v18.3.1/packages/react-dom)

Updates `@types/react-dom` from 18.2.18 to 18.3.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-17 15:53:59 -07:00
github-actions[bot]
580257f024 Bump CLI version from v2.17.2 to v2.17.3 for integration tests 2024-05-17 17:05:04 +00:00
dependabot[bot]
233cb1cd41 Bump semver from 7.6.0 to 7.6.2 in /extensions/ql-vscode (#3613)
Bumps [semver](https://github.com/npm/node-semver) from 7.6.0 to 7.6.2.
- [Release notes](https://github.com/npm/node-semver/releases)
- [Changelog](https://github.com/npm/node-semver/blob/main/CHANGELOG.md)
- [Commits](https://github.com/npm/node-semver/compare/v7.6.0...v7.6.2)

---
updated-dependencies:
- dependency-name: semver
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-16 09:34:12 -07:00
dependabot[bot]
d9fcfa0374 Bump the storybook group in /extensions/ql-vscode with 12 updates (#3612)
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.0.10` | `8.1.1` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.0.10` | `8.1.1` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.0.10` | `8.1.1` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.0.10` | `8.1.1` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.0.10` | `8.1.1` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.0.10` | `8.1.1` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.0.10` | `8.1.1` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.0.10` | `8.1.1` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.0.10` | `8.1.1` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.0.10` | `8.1.1` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.0.10` | `8.1.1` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.0.10` | `8.1.1` |


Updates `@storybook/addon-a11y` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/addons/interactions)

Updates `@storybook/addon-links` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/addons/links)

Updates `@storybook/blocks` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/ui/blocks)

Updates `@storybook/components` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/ui/components)

Updates `@storybook/manager-api` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/lib/manager-api)

Updates `@storybook/react` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/renderers/react)

Updates `@storybook/react-vite` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/lib/theming)

Updates `storybook` from 8.0.10 to 8.1.1
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.1.1/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-16 09:33:50 -07:00
Ben Ahmady
1dc48b3309 Update links in VS Marketplace README (#3611) 2024-05-15 08:52:15 +00:00
Angela P Wen
2babb0b106 Handle exit and error events for query server child processes (#3610) 2024-05-14 18:48:29 -07:00
Koen Vlaswinkel
247df2e1f9 Merge pull request #3607 from github/koesie10/ghec-dr-variant-analysis
Add GHEC-DR support
2024-05-14 10:40:28 +02:00
Koen Vlaswinkel
ba9007e426 Fix typo in comment
Co-authored-by: Robert <robertbrignull@github.com>
2024-05-14 09:42:04 +02:00
Koen Vlaswinkel
616b613fbd Merge pull request #3608 from github/koesie10/fix-supported-cli-version-warning
Fix incorrect supported CLI version warning
2024-05-13 16:57:50 +02:00
Koen Vlaswinkel
47ae0fe9f5 Fix incorrect supported CLI version warning 2024-05-13 16:44:03 +02:00
Nora
9d6b4e8e5a Merge pull request #3603 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-7db07c6d5e
Bump the storybook group in /extensions/ql-vscode with 13 updates
2024-05-13 16:32:04 +02:00
Nora
5ae70696a8 Merge pull request #3604 from github/dependabot/npm_and_yarn/extensions/ql-vscode/testing-library-66b9683d1a
Bump the testing-library group in /extensions/ql-vscode with 2 updates
2024-05-13 16:30:18 +02:00
dependabot[bot]
712dd525ee Bump the storybook group in /extensions/ql-vscode with 13 updates
Bumps the storybook group in /extensions/ql-vscode with 13 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.0.9` | `8.0.10` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.0.9` | `8.0.10` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.0.9` | `8.0.10` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.0.9` | `8.0.10` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.0.9` | `8.0.10` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.0.9` | `8.0.10` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.0.9` | `8.0.10` |
| [@storybook/csf](https://github.com/ComponentDriven/csf) | `0.1.6` | `0.1.7` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.0.9` | `8.0.10` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.0.9` | `8.0.10` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.0.9` | `8.0.10` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.0.9` | `8.0.10` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.0.9` | `8.0.10` |


Updates `@storybook/addon-a11y` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/addons/interactions)

Updates `@storybook/addon-links` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/addons/links)

Updates `@storybook/blocks` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/ui/blocks)

Updates `@storybook/components` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/ui/components)

Updates `@storybook/csf` from 0.1.6 to 0.1.7
- [Release notes](https://github.com/ComponentDriven/csf/releases)
- [Changelog](https://github.com/ComponentDriven/csf/blob/v0.1.7/CHANGELOG.md)
- [Commits](https://github.com/ComponentDriven/csf/compare/v0.1.6...v0.1.7)

Updates `@storybook/manager-api` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/lib/manager-api)

Updates `@storybook/react` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/renderers/react)

Updates `@storybook/react-vite` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/lib/theming)

Updates `storybook` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.10/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/csf"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-13 14:19:37 +00:00
Nora
fdc5645928 Merge pull request #3606 from github/dependabot/npm_and_yarn/extensions/ql-vscode/eslint-plugin-github-4.10.2
Bump eslint-plugin-github from 4.10.1 to 4.10.2 in /extensions/ql-vscode
2024-05-13 16:18:42 +02:00
dependabot[bot]
5c81c0e9bf Bump the testing-library group in /extensions/ql-vscode with 2 updates
Bumps the testing-library group in /extensions/ql-vscode with 2 updates: [@testing-library/jest-dom](https://github.com/testing-library/jest-dom) and [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/jest-dom` from 6.4.2 to 6.4.5
- [Release notes](https://github.com/testing-library/jest-dom/releases)
- [Changelog](https://github.com/testing-library/jest-dom/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/jest-dom/compare/v6.4.2...v6.4.5)

Updates `@testing-library/react` from 15.0.6 to 15.0.7
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v15.0.6...v15.0.7)

---
updated-dependencies:
- dependency-name: "@testing-library/jest-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-13 14:17:39 +00:00
dependabot[bot]
0e07e5e3eb Bump eslint-plugin-github from 4.10.1 to 4.10.2 in /extensions/ql-vscode
Bumps [eslint-plugin-github](https://github.com/github/eslint-plugin-github) from 4.10.1 to 4.10.2.
- [Release notes](https://github.com/github/eslint-plugin-github/releases)
- [Commits](https://github.com/github/eslint-plugin-github/compare/v4.10.1...v4.10.2)

---
updated-dependencies:
- dependency-name: eslint-plugin-github
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-13 14:05:08 +00:00
Koen Vlaswinkel
c90acdb4e1 Merge pull request #3600 from github/github-action/bump-cli
Bump CLI Version to v2.17.2 for integration tests
2024-05-13 13:17:54 +02:00
Koen Vlaswinkel
dad37f202d Merge pull request #3599 from github/koesie10/upgrade-publish-vsce
Use @vscode/vsce when publishing the extension
2024-05-13 13:04:42 +02:00
Koen Vlaswinkel
1f937ad208 Do not import from config in unit tests 2024-05-13 12:15:27 +02:00
Koen Vlaswinkel
086d8e2104 Update prompts to use GHEC-DR URL 2024-05-13 11:19:31 +02:00
Koen Vlaswinkel
c2ddd680c1 Use GHEC-DR URL in Octokit instance 2024-05-13 11:19:31 +02:00
Koen Vlaswinkel
9a14896a4e Use GHE auth provider if GHEC-DR URI is set 2024-05-13 11:19:31 +02:00
Koen Vlaswinkel
871fc0b817 Use GHEC-DR URL in file blob URL 2024-05-13 11:19:31 +02:00
Koen Vlaswinkel
ca092a1623 Use GHEC-DR URL in Actions workflow run URL 2024-05-13 11:19:30 +02:00
Koen Vlaswinkel
529bbe3ffa Handle GHEC-DR repository URLs 2024-05-13 11:19:30 +02:00
Koen Vlaswinkel
31b2d24ca9 Update custom errors to use GHEC-DR URL 2024-05-13 11:19:30 +02:00
github-actions[bot]
f54cace05b Bump CLI version from v2.17.1 to v2.17.2 for integration tests 2024-05-07 11:22:36 +00:00
Koen Vlaswinkel
f773f9f675 Use @vscode/vsce when publishing the extension 2024-05-06 15:31:05 +02:00
dependabot[bot]
67aa216ea1 Bump react and @types/react in /extensions/ql-vscode (#3596)
Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 18.2.0 to 18.3.1
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v18.3.1/packages/react)

Updates `@types/react` from 18.2.43 to 18.3.1
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-02 15:56:40 +01:00
dependabot[bot]
4b67f4dd54 Bump vite from 5.2.6 to 5.2.11 in /extensions/ql-vscode (#3597)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.2.6 to 5.2.11.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.2.11/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-02 15:37:22 +01:00
dependabot[bot]
572a8b7828 Bump styled-components from 6.1.8 to 6.1.9 in /extensions/ql-vscode (#3598)
Bumps [styled-components](https://github.com/styled-components/styled-components) from 6.1.8 to 6.1.9.
- [Release notes](https://github.com/styled-components/styled-components/releases)
- [Commits](https://github.com/styled-components/styled-components/compare/v6.1.8...v6.1.9)

---
updated-dependencies:
- dependency-name: styled-components
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-02 15:36:08 +01:00
dependabot[bot]
b7d6aeda3c Bump @testing-library/react (#3595)
Bumps the testing-library group in /extensions/ql-vscode with 1 update: [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/react` from 15.0.5 to 15.0.6
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v15.0.5...v15.0.6)

---
updated-dependencies:
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-02 15:35:27 +01:00
github-actions[bot]
2da77acd9e Bump CLI version from v2.17.0 to v2.17.1 for integration tests (#3577)
Co-authored-by: github-actions[bot] <github-actions@github.com>
2024-05-02 10:00:37 +00:00
Anders Starcke Henriksen
607a8380cc Merge pull request #3581 from github/dependabot/npm_and_yarn/extensions/ql-vscode/ts-json-schema-generator-2.1.1
Bump ts-json-schema-generator from 2.0.1 to 2.1.1 in /extensions/ql-vscode
2024-05-02 09:19:22 +02:00
Koen Vlaswinkel
f698ac321f Add back ts-node for Gulp 2024-05-01 14:59:02 +02:00
Koen Vlaswinkel
85abd9a1ac Switch from ts-node to vite-node
vite-node seems to have better support for mixed ESM and CJS modules and
makes the scripts work with both kinds of packages without having to
change the project configuration.
2024-05-01 14:50:12 +02:00
Anders Starcke Henriksen
329eba9536 Merge pull request #3592 from github/release-token
Update release with new PAT lifetime.
2024-05-01 14:49:03 +02:00
Anders Starcke Henriksen
733a0328d0 Merge pull request #3594 from github/version/bump-to-v1.13.1
Bump version to v1.13.1
2024-05-01 14:32:42 +02:00
dependabot[bot]
1c7f92b503 Bump ts-json-schema-generator in /extensions/ql-vscode
Bumps [ts-json-schema-generator](https://github.com/vega/ts-json-schema-generator) from 2.0.1 to 2.1.1.
- [Release notes](https://github.com/vega/ts-json-schema-generator/releases)
- [Changelog](https://github.com/vega/ts-json-schema-generator/blob/v2.1.1/CHANGELOG.md)
- [Commits](https://github.com/vega/ts-json-schema-generator/compare/v2.0.1...v2.1.1)

---
updated-dependencies:
- dependency-name: ts-json-schema-generator
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-01 12:13:48 +00:00
github-actions[bot]
884ec21e5a Bump version to v1.13.1 2024-05-01 11:44:41 +00:00
Anders Starcke Henriksen
35c533606f Merge pull request #3593 from github/v1.13.0
v1.13.0
2024-05-01 13:42:53 +02:00
Anders Starcke Henriksen
4adf60a978 v1.13.0
Some checks failed
Release / Release (push) Has been cancelled
Release / Publish to VS Code Marketplace (push) Has been cancelled
Release / Publish to Open VSX Registry (push) Has been cancelled
2024-05-01 10:36:40 +02:00
Koen Vlaswinkel
69775414f0 Merge pull request #3591 from github/koesie10/update-changelog
Add Ruby model editor support to CHANGELOG
2024-05-01 09:54:47 +02:00
Anders Starcke Henriksen
10c74d5d8c Update release with new PAT lifetime. 2024-05-01 09:54:04 +02:00
Koen Vlaswinkel
325f5d6667 Move up changelog entry 2024-05-01 09:42:03 +02:00
Koen Vlaswinkel
e968c226ba Add Ruby model editor support to CHANGELOG 2024-05-01 09:33:22 +02:00
dependabot[bot]
44429c2513 Bump husky from 8.0.3 to 9.0.11 in /extensions/ql-vscode (#3590)
Bumps [husky](https://github.com/typicode/husky) from 8.0.3 to 9.0.11.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v8.0.3...v9.0.11)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-30 09:26:20 -07:00
dependabot[bot]
96881f2bf2 Bump the testing-library group in /extensions/ql-vscode with 2 updates (#3589)
Bumps the testing-library group in /extensions/ql-vscode with 2 updates: [@testing-library/dom](https://github.com/testing-library/dom-testing-library) and [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/dom` from 10.0.0 to 10.1.0
- [Release notes](https://github.com/testing-library/dom-testing-library/releases)
- [Changelog](https://github.com/testing-library/dom-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/dom-testing-library/compare/v10.0.0...v10.1.0)

Updates `@testing-library/react` from 15.0.4 to 15.0.5
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v15.0.4...v15.0.5)

---
updated-dependencies:
- dependency-name: "@testing-library/dom"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: testing-library
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-30 09:25:56 -07:00
dependabot[bot]
06f4e33719 Bump @storybook/csf in /extensions/ql-vscode in the storybook group (#3588)
Bumps the storybook group in /extensions/ql-vscode with 1 update: [@storybook/csf](https://github.com/ComponentDriven/csf).


Updates `@storybook/csf` from 0.1.4 to 0.1.6
- [Release notes](https://github.com/ComponentDriven/csf/releases)
- [Changelog](https://github.com/ComponentDriven/csf/blob/v0.1.6/CHANGELOG.md)
- [Commits](https://github.com/ComponentDriven/csf/compare/v0.1.4...v0.1.6)

---
updated-dependencies:
- dependency-name: "@storybook/csf"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-30 09:25:14 -07:00
Koen Vlaswinkel
570e410e06 Merge pull request #3587 from github/koesie10/upgrade-e2e-tests
Upgrade E2E test dependencies
2024-04-30 17:24:33 +02:00
Koen Vlaswinkel
1d5b4f3fbb Merge pull request #3586 from github/koesie10/fix-e2e-tests
Always use the latest released CodeQL version in E2E tests
2024-04-30 16:30:42 +02:00
Koen Vlaswinkel
0e5b460e67 Upgrade Alpine to 3.19.1 2024-04-30 16:20:19 +02:00
Koen Vlaswinkel
a39f4582e3 Enable Dependabot for E2E docker image 2024-04-30 16:19:13 +02:00
Koen Vlaswinkel
18f12e53c9 Upgrade E2E tests to VS Code v1.88.1 2024-04-30 16:17:51 +02:00
Koen Vlaswinkel
ac8dd9189e Always use the latest released CodeQL version in E2E tests 2024-04-30 16:11:19 +02:00
Koen Vlaswinkel
7d564b50e7 Merge pull request #3584 from github/koesie10/add-ruby-as-supported-model-editor-language
Add Ruby as a fully-supported model editor language
2024-04-30 12:42:52 +02:00
Koen Vlaswinkel
013bf65c0a Merge pull request #3585 from github/koesie10/fix-modeled-method-fs-test
Fix modeled method FS test
2024-04-30 12:42:44 +02:00
Koen Vlaswinkel
bd6862efda Fix modeled method FS test 2024-04-30 11:53:15 +02:00
Koen Vlaswinkel
64f0115070 Add Ruby as a fully-supported model editor language 2024-04-26 17:00:06 +02:00
dependabot[bot]
596049a8cb Bump @testing-library/react (#3580)
Bumps the testing-library group in /extensions/ql-vscode with 1 update: [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/react` from 15.0.2 to 15.0.4
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v15.0.2...v15.0.4)

---
updated-dependencies:
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-25 15:00:47 +00:00
dependabot[bot]
58a5a43609 Bump the storybook group in /extensions/ql-vscode with 12 updates (#3579)
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.0.8` | `8.0.9` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.0.8` | `8.0.9` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.0.8` | `8.0.9` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.0.8` | `8.0.9` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.0.8` | `8.0.9` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.0.8` | `8.0.9` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.0.8` | `8.0.9` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.0.8` | `8.0.9` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.0.8` | `8.0.9` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.0.8` | `8.0.9` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.0.8` | `8.0.9` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.0.8` | `8.0.9` |


Updates `@storybook/addon-a11y` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/addons/interactions)

Updates `@storybook/addon-links` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/addons/links)

Updates `@storybook/blocks` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/ui/blocks)

Updates `@storybook/components` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/ui/components)

Updates `@storybook/manager-api` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/lib/manager-api)

Updates `@storybook/react` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/renderers/react)

Updates `@storybook/react-vite` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/lib/theming)

Updates `storybook` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.9/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-25 15:46:04 +01:00
dependabot[bot]
67ad9cb6ce Bump nanoid from 5.0.6 to 5.0.7 in /extensions/ql-vscode (#3582)
Bumps [nanoid](https://github.com/ai/nanoid) from 5.0.6 to 5.0.7.
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/5.0.6...5.0.7)

---
updated-dependencies:
- dependency-name: nanoid
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-25 14:59:18 +01:00
Robert
29c36584f8 Merge pull request #3576 from github/robertbrignull/disable-llm-proxima
Disable LLM model generation when not using github.com
2024-04-22 16:47:56 +01:00
Robert
e59145372e Disable LLM model generation when not using github.com 2024-04-22 16:28:52 +01:00
Robert
ad17a4f828 Merge pull request #3570 from github/robertbrignull/disable_top1000
Hide system defined lists when enterprise URI is set
2024-04-22 10:12:19 +01:00
dependabot[bot]
f17319a5cf Bump markdownlint-cli2 from 0.12.1 to 0.13.0 in /extensions/ql-vscode (#3571)
Bumps [markdownlint-cli2](https://github.com/DavidAnson/markdownlint-cli2) from 0.12.1 to 0.13.0.
- [Changelog](https://github.com/DavidAnson/markdownlint-cli2/blob/main/CHANGELOG.md)
- [Commits](https://github.com/DavidAnson/markdownlint-cli2/compare/v0.12.1...v0.13.0)

---
updated-dependencies:
- dependency-name: markdownlint-cli2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-18 13:12:06 -07:00
dependabot[bot]
0d52be1dbf Bump @babel/preset-react from 7.23.3 to 7.24.1 in /extensions/ql-vscode (#3575)
Bumps [@babel/preset-react](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-react) from 7.23.3 to 7.24.1.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.24.1/packages/babel-preset-react)

---
updated-dependencies:
- dependency-name: "@babel/preset-react"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-18 13:11:46 -07:00
dependabot[bot]
13a61094c1 Bump @babel/preset-env from 7.24.0 to 7.24.4 in /extensions/ql-vscode (#3574)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.24.0 to 7.24.4.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.24.4/packages/babel-preset-env)

---
updated-dependencies:
- dependency-name: "@babel/preset-env"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-18 19:40:48 +00:00
dependabot[bot]
230cdd024c Bump @babel/core from 7.24.0 to 7.24.4 in /extensions/ql-vscode (#3573)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.24.0 to 7.24.4.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.24.4/packages/babel-core)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-18 12:26:36 -07:00
dependabot[bot]
29a47305a9 Bump eslint-plugin-react from 7.33.2 to 7.34.1 in /extensions/ql-vscode (#3572)
Bumps [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) from 7.33.2 to 7.34.1.
- [Release notes](https://github.com/jsx-eslint/eslint-plugin-react/releases)
- [Changelog](https://github.com/jsx-eslint/eslint-plugin-react/blob/v7.34.1/CHANGELOG.md)
- [Commits](https://github.com/jsx-eslint/eslint-plugin-react/compare/v7.33.2...v7.34.1)

---
updated-dependencies:
- dependency-name: eslint-plugin-react
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-18 12:26:18 -07:00
Robert
26ec371730 move onDidChangeConfiguration to be the last field in VariantAnalysisConfig 2024-04-18 09:59:50 +01:00
Robert
58de4864c0 Pass VariantAnalysisConfig into DbManager to avoid vscode dependency 2024-04-18 09:55:21 +01:00
Robert
17ff592a60 Hide system defined lists when enterprise URI is set 2024-04-17 14:31:14 +01:00
Robert
1c267e4c28 Merge pull request #3569 from github/robertbrignull/ghec_dr_mode
Detect when the github-enterprise.uri setting is set
2024-04-17 11:06:26 +01:00
Robert
2f67ccea56 Cover all cases of URIs and feature flags 2024-04-17 10:53:17 +01:00
Robert
b3fdb3a126 Use endsWith instead of regex 2024-04-17 09:37:53 +01:00
Robert
07ba537590 Make config field use camel-case 2024-04-17 09:37:38 +01:00
Robert
8abde36dcb Detect when the github-enterprise.uri setting is set 2024-04-16 17:18:49 +01:00
dependabot[bot]
27d6a749f8 Bump @floating-ui/react from 0.26.10 to 0.26.12 in /extensions/ql-vscode (#3567)
Bumps [@floating-ui/react](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/react) from 0.26.10 to 0.26.12.
- [Release notes](https://github.com/floating-ui/floating-ui/releases)
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/react/CHANGELOG.md)
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/react@0.26.12/packages/react)

---
updated-dependencies:
- dependency-name: "@floating-ui/react"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-16 16:39:37 +01:00
dependabot[bot]
e7af631737 Bump @testing-library/react (#3565)
Bumps the testing-library group in /extensions/ql-vscode with 1 update: [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/react` from 15.0.1 to 15.0.2
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v15.0.1...v15.0.2)

---
updated-dependencies:
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-16 16:24:37 +01:00
dependabot[bot]
cdd889452a Bump @storybook/csf in /extensions/ql-vscode in the storybook group (#3564)
Bumps the storybook group in /extensions/ql-vscode with 1 update: [@storybook/csf](https://github.com/ComponentDriven/csf).


Updates `@storybook/csf` from 0.1.3 to 0.1.4
- [Release notes](https://github.com/ComponentDriven/csf/releases)
- [Changelog](https://github.com/ComponentDriven/csf/blob/v0.1.4/CHANGELOG.md)
- [Commits](https://github.com/ComponentDriven/csf/compare/v0.1.3...v0.1.4)

---
updated-dependencies:
- dependency-name: "@storybook/csf"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-16 16:19:11 +01:00
dependabot[bot]
4abaa22f62 Bump ts-json-schema-generator in /extensions/ql-vscode (#3568)
Bumps [ts-json-schema-generator](https://github.com/vega/ts-json-schema-generator) from 1.5.0 to 2.0.1.
- [Release notes](https://github.com/vega/ts-json-schema-generator/releases)
- [Changelog](https://github.com/vega/ts-json-schema-generator/blob/v2.0.1/CHANGELOG.md)
- [Commits](https://github.com/vega/ts-json-schema-generator/compare/v1.5.0...v2.0.1)

---
updated-dependencies:
- dependency-name: ts-json-schema-generator
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-16 16:12:31 +01:00
dependabot[bot]
df322ce17d Bump applicationinsights from 2.9.4 to 2.9.5 in /extensions/ql-vscode (#3566)
Bumps [applicationinsights](https://github.com/microsoft/ApplicationInsights-node.js) from 2.9.4 to 2.9.5.
- [Release notes](https://github.com/microsoft/ApplicationInsights-node.js/releases)
- [Commits](https://github.com/microsoft/ApplicationInsights-node.js/compare/2.9.4...2.9.5)

---
updated-dependencies:
- dependency-name: applicationinsights
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-16 15:30:48 +01:00
Charis Kyriakou
0df508d1c6 Remove support for CodeQL CLI versions older than 2.14.6 (#3562) 2024-04-16 15:27:32 +01:00
Charis Kyriakou
2e7586c39f Exclude major version updates for the octokit group in dependabot (#3563)
* Exclude major version updates for the octokit group in dependabot

* Commit unstaged changes 🤦
2024-04-16 14:29:17 +01:00
Charis Kyriakou
f854ab50d5 Move octokit throttling plugin dependency out of dev dependencies (#3561) 2024-04-16 11:52:01 +00:00
Andrew Eisenberg
3cc4005500 Merge pull request #3556 from github/dependabot/npm_and_yarn/extensions/ql-vscode/msw-2.2.13
Bump msw from 2.0.13 to 2.2.13 in /extensions/ql-vscode
2024-04-16 01:24:44 -07:00
Koen Vlaswinkel
0d4a95d08e Merge pull request #3552 from github/koesie10/remove-enable-type-models
Remove `codeQL.model.showTypeModels` config
2024-04-16 10:16:52 +02:00
Koen Vlaswinkel
d67cf4b9f7 Remove codeQL.model.showTypeModels config
This removes the `codeQL.model.showTypeModels` setting. We will now
always show type models in the model editor. This also means that the
"auto-generation mode" needs to change to `models` to ensure that the
type models are actually shown to the user. This is done for Ruby, which
is currently the only language to show type models.
2024-04-15 16:52:27 +02:00
Koen Vlaswinkel
c37bd9969c Merge pull request #3550 from github/koesie10/separate-file
Add auto-model generation mode without separate file
2024-04-15 16:52:13 +02:00
Andrew Eisenberg
1dac41d8ea Merge pull request #3558 from github/dependabot/npm_and_yarn/extensions/ql-vscode/testing-library-0922f3acd1
Bump the testing-library group in /extensions/ql-vscode with 2 updates
2024-04-11 11:14:36 -07:00
dependabot[bot]
48a03bd383 Bump the testing-library group in /extensions/ql-vscode with 2 updates
Bumps the testing-library group in /extensions/ql-vscode with 2 updates: [@testing-library/dom](https://github.com/testing-library/dom-testing-library) and [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/dom` from 9.3.4 to 10.0.0
- [Release notes](https://github.com/testing-library/dom-testing-library/releases)
- [Changelog](https://github.com/testing-library/dom-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/dom-testing-library/compare/v9.3.4...v10.0.0)

Updates `@testing-library/react` from 14.2.2 to 15.0.1
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v14.2.2...v15.0.1)

---
updated-dependencies:
- dependency-name: "@testing-library/dom"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: testing-library
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-11 17:31:55 +00:00
dependabot[bot]
b6897e4faf Bump the storybook group in /extensions/ql-vscode with 12 updates (#3557)
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.0.5` | `8.0.8` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.0.5` | `8.0.8` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.0.5` | `8.0.8` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.0.5` | `8.0.8` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.0.5` | `8.0.8` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.0.5` | `8.0.8` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.0.5` | `8.0.8` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.0.5` | `8.0.8` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.0.5` | `8.0.8` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.0.5` | `8.0.8` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.0.5` | `8.0.8` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.0.5` | `8.0.8` |


Updates `@storybook/addon-a11y` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/addons/interactions)

Updates `@storybook/addon-links` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/addons/links)

Updates `@storybook/blocks` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/ui/blocks)

Updates `@storybook/components` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/ui/components)

Updates `@storybook/manager-api` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/lib/manager-api)

Updates `@storybook/react` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/renderers/react)

Updates `@storybook/react-vite` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/lib/theming)

Updates `storybook` from 8.0.5 to 8.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.8/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-11 10:30:00 -07:00
dependabot[bot]
d20a1eb61b Bump ts-jest from 29.1.1 to 29.1.2 in /extensions/ql-vscode (#3555)
Bumps [ts-jest](https://github.com/kulshekhar/ts-jest) from 29.1.1 to 29.1.2.
- [Release notes](https://github.com/kulshekhar/ts-jest/releases)
- [Changelog](https://github.com/kulshekhar/ts-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/kulshekhar/ts-jest/compare/v29.1.1...v29.1.2)

---
updated-dependencies:
- dependency-name: ts-jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-11 10:05:22 -07:00
dependabot[bot]
8ef3ae0ff5 Bump msw from 2.0.13 to 2.2.13 in /extensions/ql-vscode
Bumps [msw](https://github.com/mswjs/msw) from 2.0.13 to 2.2.13.
- [Release notes](https://github.com/mswjs/msw/releases)
- [Changelog](https://github.com/mswjs/msw/blob/main/CHANGELOG.md)
- [Commits](https://github.com/mswjs/msw/compare/v2.0.13...v2.2.13)

---
updated-dependencies:
- dependency-name: msw
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-11 13:40:56 +00:00
Koen Vlaswinkel
c7a048b0dc Merge pull request #3548 from github/koesie10/remove-access-path-suggestions-ff
Remove `codeQL.model.enableAccessPathSuggestions` config
2024-04-11 14:29:50 +02:00
Nora
9026076635 Merge pull request #3547 from github/version/bump-to-v1.12.6
Bump version to v1.12.6
2024-04-10 17:16:19 +02:00
Shati Patel
135dc7084a Remove rogue semmle link (#3549) 2024-04-10 15:05:20 +00:00
Koen Vlaswinkel
8c784d8391 Merge pull request #3543 from github/koesie10/pack-name-config
Add `codeQL.model.packName` setting
2024-04-10 17:03:36 +02:00
Koen Vlaswinkel
fed30b6fed Add auto-model generation mode without separate file 2024-04-10 16:46:45 +02:00
Koen Vlaswinkel
232d4c3f41 Remove unnecessary access path progress for unsupported languages 2024-04-10 16:05:56 +02:00
Koen Vlaswinkel
acb6b8b490 Remove enableAccessPathSuggestions config
Access path suggestions will now be enabled for all languages which
support it (which is currently only Ruby).
2024-04-10 15:46:29 +02:00
Koen Vlaswinkel
3f4ed48787 Trim whitespace and slashes in pack names 2024-04-10 15:08:35 +02:00
github-actions[bot]
e1d9aa813d Bump version to v1.12.6 2024-04-09 12:29:43 +00:00
Nora
8a3a6d7e7e Merge pull request #3546 from github/v1.12.5
v1.12.5
2024-04-09 14:27:59 +02:00
Nora
5b89b9608f Update changelog
Some checks failed
Release / Release (push) Has been cancelled
Release / Publish to VS Code Marketplace (push) Has been cancelled
Release / Publish to Open VSX Registry (push) Has been cancelled
2024-04-09 09:08:47 +00:00
Nora
999c73d05d Update version number in changelog 2024-04-09 08:54:07 +00:00
Charis Kyriakou
070df13947 Rename vscode-app -> extension-app file to match convention (#3545) 2024-04-08 16:11:22 +01:00
Koen Vlaswinkel
0c5b39945c Merge pull request #3544 from github/koesie10/python-parsing-unit-tests
Add unit tests for Python argument options
2024-04-08 16:36:40 +02:00
Koen Vlaswinkel
8e231d7b1d Add unit tests for Python argument options 2024-04-08 14:49:09 +02:00
Koen Vlaswinkel
bf9bfb13b7 Add codeQL.model.packName setting 2024-04-08 14:42:47 +02:00
Koen Vlaswinkel
4dc126d56d Merge pull request #3539 from github/koesie10/pack-location-config
Add `codeQL.model.packLocation` setting
2024-04-08 14:11:46 +02:00
Koen Vlaswinkel
9e729ba054 Merge pull request #3540 from github/koesie10/python-model-editor-args
Improve support for Python arguments
2024-04-08 13:59:45 +02:00
Koen Vlaswinkel
6146d7d78a Fix numbering in comment 2024-04-08 13:58:13 +02:00
Charis Kyriakou
6d8de1b3b8 Remove mocking of modeling events (#3542) 2024-04-08 11:19:02 +01:00
Nora
24e08f768c Merge pull request #3534 from github/dependabot/npm_and_yarn/extensions/ql-vscode/floating-ui/react-0.26.10
Bump @floating-ui/react from 0.26.9 to 0.26.10 in /extensions/ql-vscode
2024-04-08 10:35:52 +02:00
Nora
62e051b3d1 Merge pull request #3535 from github/dependabot/npm_and_yarn/extensions/ql-vscode/github/markdownlint-github-0.6.2
Bump @github/markdownlint-github from 0.6.0 to 0.6.2 in /extensions/ql-vscode
2024-04-08 10:16:20 +02:00
Koen Vlaswinkel
b6931dd79a Merge pull request #3541 from github/koesie10/upgrade-ts-eslint
Upgrade typescript-eslint to v7
2024-04-05 16:49:52 +02:00
Koen Vlaswinkel
70009cdc32 Upgrade typescript-eslint to v7 2024-04-05 16:21:16 +02:00
Koen Vlaswinkel
b3276f5cf5 Merge pull request #3538 from github/github-action/bump-node-version
Bump Node version to v18.18.2
2024-04-05 16:15:54 +02:00
Koen Vlaswinkel
1e3cb0772e Improve support for Python arguments 2024-04-05 15:39:44 +02:00
Koen Vlaswinkel
5fbd912abd Add codeQL.model.packLocation setting
This adds the `codeQL.model.packLocation` setting, which allows users to
specify the location of the CodeQL extension pack. This setting replaces
the `codeQL.model.extensionsDirectory` setting, which has been removed.

The pack location supports variable substitutions and supports both
absolute and relative paths. The default value is
`.github/codeql/extensions/${name}-${language}` which matches the
previous defaults.
2024-04-05 15:04:29 +02:00
github-actions[bot]
03c8748981 Bump Node version to v18.18.2 2024-04-05 12:25:06 +00:00
Koen Vlaswinkel
351bc648ef Merge pull request #3530 from github/koesie10/config-template
Add helper for substituting config variables
2024-04-05 11:15:33 +02:00
dependabot[bot]
8ccca1381a Bump eslint-plugin-jest-dom from 5.1.0 to 5.2.0 in /extensions/ql-vscode (#3536)
Bumps [eslint-plugin-jest-dom](https://github.com/testing-library/eslint-plugin-jest-dom) from 5.1.0 to 5.2.0.
- [Release notes](https://github.com/testing-library/eslint-plugin-jest-dom/releases)
- [Commits](https://github.com/testing-library/eslint-plugin-jest-dom/compare/v5.1.0...v5.2.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-jest-dom
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-04 13:28:39 -07:00
dependabot[bot]
85953ec9c3 Bump d3 from 7.8.5 to 7.9.0 in /extensions/ql-vscode (#3533)
Bumps [d3](https://github.com/d3/d3) from 7.8.5 to 7.9.0.
- [Release notes](https://github.com/d3/d3/releases)
- [Changelog](https://github.com/d3/d3/blob/main/CHANGES.md)
- [Commits](https://github.com/d3/d3/compare/v7.8.5...v7.9.0)

---
updated-dependencies:
- dependency-name: d3
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-04 11:07:16 -07:00
github-actions[bot]
4a303fa48d Bump CLI version from v2.16.6 to v2.17.0 for integration tests (#3537)
Co-authored-by: github-actions[bot] <github-actions@github.com>
2024-04-04 15:53:15 +00:00
dependabot[bot]
48e66cbe25 Bump @github/markdownlint-github in /extensions/ql-vscode
Bumps [@github/markdownlint-github](https://github.com/github/markdownlint-github) from 0.6.0 to 0.6.2.
- [Release notes](https://github.com/github/markdownlint-github/releases)
- [Commits](https://github.com/github/markdownlint-github/compare/0.6.0...v0.6.2)

---
updated-dependencies:
- dependency-name: "@github/markdownlint-github"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-04 13:56:17 +00:00
dependabot[bot]
8787fcdd96 Bump @floating-ui/react from 0.26.9 to 0.26.10 in /extensions/ql-vscode
Bumps [@floating-ui/react](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/react) from 0.26.9 to 0.26.10.
- [Release notes](https://github.com/floating-ui/floating-ui/releases)
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/react/CHANGELOG.md)
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/react@0.26.10/packages/react)

---
updated-dependencies:
- dependency-name: "@floating-ui/react"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-04 13:56:05 +00:00
Nora
20cc5ad988 Merge pull request #3531 from github/dependabot/npm_and_yarn/extensions/ql-vscode/vite-5.2.6
Bump vite from 5.2.0 to 5.2.6 in /extensions/ql-vscode
2024-04-04 10:34:30 +02:00
dependabot[bot]
ecae6bdd99 Bump vite from 5.2.0 to 5.2.6 in /extensions/ql-vscode
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.2.0 to 5.2.6.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.2.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-03 16:47:45 +00:00
Andrew Eisenberg
00c0e70626 Merge pull request #3527 from aeisenberg/aeisenberg/fix-qlpack-schema
Fix the qlpack json schema
2024-04-03 09:46:11 -07:00
Koen Vlaswinkel
8cb2b34992 Add helper for substituting config variables 2024-04-03 14:42:31 +02:00
Robert
7da3740828 Merge pull request #3517 from github/robertbrignull/fix-token-alerts
Mark progress bars as cancellable where it appears we are respecting the token
2024-04-03 11:30:30 +01:00
Andrew Eisenberg
44c3c29857 Update changelog 2024-04-03 03:21:25 +00:00
Andrew Eisenberg
e6ebcf4245 Fix the qlpack json schema
This schema was incorrectly tagging `defaultSuite` properties that
aren't arrays as errors.

I think there are more, similar errors in this schema, but I only fixed
this one so that I can get `github/semmle-code` working with test
discovery.
2024-04-02 20:21:21 -07:00
Robert
4e43a07fb5 Merge branch 'main' into robertbrignull/fix-token-alerts 2024-04-02 17:27:53 +01:00
Charis Kyriakou
3508dc6d8c Tidy up some functions in the model evaluator (#3529)
* Rename model evaluator's updateVariantAnalysis -> setVariantAnalysis

* Merge updateRepoResults and updateReposResults into single setReposResults function
2024-04-02 12:32:50 +01:00
Koen Vlaswinkel
ff6f6cdf8a Merge pull request #3515 from github/koesie10/tee-logger-file-handle
Use file handle in TeeLogger
2024-04-02 10:02:41 +02:00
Robert
a5239fbede Merge pull request #3458 from github/robertbrignull/database-prompting
Refactor database-fetcher.ts into a class and simplify
2024-03-28 18:05:54 +00:00
Robert
7d259a9322 Fix dodgy imports 2024-03-28 17:51:22 +00:00
Koen Vlaswinkel
6f7b7cf84f Merge pull request #3525 from github/dependabot/npm_and_yarn/extensions/ql-vscode/types/semver-7.5.8
Bump @types/semver from 7.5.6 to 7.5.8 in /extensions/ql-vscode
2024-03-28 14:57:58 +01:00
Koen Vlaswinkel
c6865de312 Merge pull request #3526 from github/dependabot/npm_and_yarn/extensions/ql-vscode/express-4.19.2
Bump express from 4.18.2 to 4.19.2 in /extensions/ql-vscode
2024-03-28 14:57:18 +01:00
dependabot[bot]
133d5899af Bump @types/semver from 7.5.6 to 7.5.8 in /extensions/ql-vscode
Bumps [@types/semver](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/semver) from 7.5.6 to 7.5.8.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/semver)

---
updated-dependencies:
- dependency-name: "@types/semver"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-28 13:43:46 +00:00
dependabot[bot]
8d7d469803 Bump express from 4.18.2 to 4.19.2 in /extensions/ql-vscode
Bumps [express](https://github.com/expressjs/express) from 4.18.2 to 4.19.2.
- [Release notes](https://github.com/expressjs/express/releases)
- [Changelog](https://github.com/expressjs/express/blob/master/History.md)
- [Commits](https://github.com/expressjs/express/compare/4.18.2...4.19.2)

---
updated-dependencies:
- dependency-name: express
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-28 13:43:32 +00:00
Koen Vlaswinkel
7575beac6b Merge pull request #3524 from github/dependabot/npm_and_yarn/extensions/ql-vscode/lint-staged-15.2.2
Bump lint-staged from 15.2.0 to 15.2.2 in /extensions/ql-vscode
2024-03-28 14:43:09 +01:00
Koen Vlaswinkel
9e5d0ae7c2 Merge pull request #3522 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-5df8c90cc2
Bump the storybook group in /extensions/ql-vscode with 12 updates
2024-03-28 14:42:31 +01:00
dependabot[bot]
ae6b9df9e7 Bump lint-staged from 15.2.0 to 15.2.2 in /extensions/ql-vscode
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 15.2.0 to 15.2.2.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Changelog](https://github.com/lint-staged/lint-staged/blob/master/CHANGELOG.md)
- [Commits](https://github.com/okonet/lint-staged/compare/v15.2.0...v15.2.2)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-28 13:29:17 +00:00
dependabot[bot]
5ff353962f Bump the storybook group in /extensions/ql-vscode with 12 updates
Bumps the storybook group in /extensions/ql-vscode with 12 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.0.2` | `8.0.5` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `8.0.2` | `8.0.5` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.0.2` | `8.0.5` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.0.2` | `8.0.5` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `8.0.2` | `8.0.5` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/blocks) | `8.0.2` | `8.0.5` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `8.0.2` | `8.0.5` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.0.2` | `8.0.5` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.0.2` | `8.0.5` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.0.2` | `8.0.5` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.0.2` | `8.0.5` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.0.2` | `8.0.5` |


Updates `@storybook/addon-a11y` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/addons/a11y)

Updates `@storybook/addon-actions` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/addons/actions)

Updates `@storybook/addon-essentials` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/addons/interactions)

Updates `@storybook/addon-links` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/addons/links)

Updates `@storybook/blocks` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/ui/blocks)

Updates `@storybook/components` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/ui/components)

Updates `@storybook/manager-api` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/lib/manager-api)

Updates `@storybook/react` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/renderers/react)

Updates `@storybook/react-vite` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/frameworks/react-vite)

Updates `@storybook/theming` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/lib/theming)

Updates `storybook` from 8.0.2 to 8.0.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.5/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-28 13:28:32 +00:00
Robert
3cae3ccc3c Merge branch 'main' into robertbrignull/database-prompting 2024-03-28 13:12:00 +00:00
Shati Patel
7a41d9c605 Add unit test for createModeledMethodKey (#3521) 2024-03-28 11:32:34 +00:00
Robert
d3476259b3 Unexport ProgressTask 2024-03-28 11:07:57 +00:00
Robert
28bf345ea8 Make trim cache not cancellable 2024-03-28 10:58:42 +00:00
Robert
e23d4a9d9f Make restarting the query server not cancellable, because in practice it wasn't 2024-03-28 10:51:00 +00:00
Robert
47a5993333 Make clearCacheInDatabase not take a cancellation token 2024-03-28 10:45:17 +00:00
Shati Patel
45e20f405b Link from alerts indicator to model alerts view (#3520) 2024-03-28 10:31:29 +00:00
Shati Patel
fcf74b337f Refactor: extract function for canonicalising modeled methods (#3518) 2024-03-27 14:40:57 +00:00
Shati Patel
c84fa538ba Fire an event when clicking the "model alerts indicator" button (#3516) 2024-03-27 12:47:22 +00:00
Shati Patel
317d3b3c0e Fix "View" link in model alerts view (#3519) 2024-03-27 12:16:09 +00:00
Koen Vlaswinkel
e52a08db4d Safely close file handle in all cases 2024-03-27 10:46:56 +01:00
Koen Vlaswinkel
139c4555d9 Use Disposable type instead of isDisposable function 2024-03-27 10:43:31 +01:00
Shati Patel
a502e52d37 Add "view" button in model alerts view (#3514) 2024-03-26 17:51:37 +00:00
Robert
6b0f7e86fa Mark progress bars as cancellable where it appears we are respecting the token 2024-03-26 17:05:22 +00:00
Andrew Eisenberg
5d45a114be Merge pull request #3510 from github/aeisenberg/flush-archive-files
Flush archive file systems when removed
2024-03-26 08:11:36 -07:00
Koen Vlaswinkel
b53b33e3b6 Use file handle in TeeLogger
This switches the `TeeLogger` from using the `appendFile` function to
manually opening and closing a file handle and calling `appendFile` on
the file handle. This results in a more efficient implementation as the
file handle is only opened once and closed once, instead of being
opened and closed for every log message. This should result in less
"too many open files" errors.
2024-03-26 15:58:44 +01:00
Shati Patel
ccd53133a9 Use wider type for "reveal in model editor" (#3512) 2024-03-26 13:54:42 +00:00
Koen Vlaswinkel
38e862c1e0 Merge pull request #3513 from github/github-action/bump-cli
Bump CLI Version to v2.16.6 for integration tests
2024-03-26 14:12:44 +01:00
Koen Vlaswinkel
8de85453ec Merge pull request #3511 from github/koesie10/update-kinds
Update supported sink and source kinds in the model editor
2024-03-26 13:54:16 +01:00
github-actions[bot]
6d535ab0ad Bump CLI version from v2.16.5 to v2.16.6 for integration tests 2024-03-26 12:24:52 +00:00
Koen Vlaswinkel
61fa841784 Update CHANGELOG 2024-03-26 12:20:45 +01:00
Koen Vlaswinkel
b3c83d175a Update supported sink and source kinds 2024-03-26 12:09:51 +01:00
Koen Vlaswinkel
bd57005832 Split Java and C# model editor languages 2024-03-26 11:55:20 +01:00
Andrew Eisenberg
e939750822 Flush archive file systems when removed
This change will remove a file system archive from the cache when the associated folder is removed from the workspace.

This avoids the following bug:

1. Import a database and add its source folder
2. Remove the database (source folder is removed as well automatically).
3. Change the source code and recreate the database
4. Reimport the database and source folder
5. BUG: You see the original source folder, not the new source folder
2024-03-25 16:29:02 -07:00
Charis Kyriakou
21c33b762c Added filtering and sorting in the model alerts view (#3509) 2024-03-25 17:18:09 +00:00
Charis Kyriakou
8b6a9352f6 Update model alert processing to track repo results (#3508) 2024-03-25 12:15:16 +00:00
Charis Kyriakou
dea68e928a Extract re-usable SearchBox component (#3507) 2024-03-25 10:34:23 +00:00
Charis Kyriakou
a6b3d38939 Re-use setRepoResults instead of having a setReposResult message (#3506) 2024-03-22 16:01:02 +00:00
Koen Vlaswinkel
1739af4013 Merge pull request #3505 from github/koesie10/fix-python-model-editor
Fix detection of Python instance methods
2024-03-22 15:39:58 +01:00
Charis Kyriakou
cbc6b73759 Wire up processing model evaluation run results and showing alerts (#3503) 2024-03-22 14:33:36 +00:00
Koen Vlaswinkel
5c43018692 Merge pull request #3504 from github/koesie10/downgrade-typescript-eslint
Downgrade `@typescript-eslint/eslint-plugin` to v6
2024-03-22 13:10:03 +01:00
Koen Vlaswinkel
895673188f Fix detection of Python instance methods 2024-03-22 13:09:21 +01:00
Koen Vlaswinkel
38327c7b7f Downgrade @typescript-eslint/eslint-plugin to v6
Version 7 of `@typescript-eslint` is not compatible with Node 18.17 and
requires Node 18.18+ or Node 20. The latest minor/patch version of v7
started enforcing this requirement, but this was already part of the
breaking changes for v7.
2024-03-22 12:21:32 +01:00
Koen Vlaswinkel
161fe3d5a7 Merge pull request #3502 from github/dependabot/npm_and_yarn/extensions/ql-vscode/vscode/debugprotocol-1.65.0
Bump @vscode/debugprotocol from 1.64.0 to 1.65.0 in /extensions/ql-vscode
2024-03-21 14:48:18 +01:00
Koen Vlaswinkel
b99caf7bc1 Merge pull request #3499 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-e497c5f385
Bump the storybook group in /extensions/ql-vscode with 1 update
2024-03-21 14:47:21 +01:00
Koen Vlaswinkel
bd7d8ddaf0 Merge pull request #3501 from github/dependabot/npm_and_yarn/extensions/ql-vscode/typescript-eslint-09a1cc5d51
Bump the typescript-eslint group in /extensions/ql-vscode with 1 update
2024-03-21 14:47:05 +01:00
Koen Vlaswinkel
5c0ecd4041 Merge pull request #3500 from github/dependabot/npm_and_yarn/extensions/ql-vscode/testing-library-79d2cbd4c7
Bump the testing-library group in /extensions/ql-vscode with 1 update
2024-03-21 14:46:43 +01:00
dependabot[bot]
bfdb04bf69 Bump @vscode/debugprotocol in /extensions/ql-vscode
Bumps [@vscode/debugprotocol](https://github.com/microsoft/vscode-debugadapter-node) from 1.64.0 to 1.65.0.
- [Commits](https://github.com/microsoft/vscode-debugadapter-node/compare/v1.64.0...v1.65.0)

---
updated-dependencies:
- dependency-name: "@vscode/debugprotocol"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-21 13:33:52 +00:00
dependabot[bot]
c8f9381af2 Bump the typescript-eslint group in /extensions/ql-vscode with 1 update
Bumps the typescript-eslint group in /extensions/ql-vscode with 1 update: [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin).


Updates `@typescript-eslint/eslint-plugin` from 7.2.0 to 7.3.1
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v7.3.1/packages/eslint-plugin)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/eslint-plugin"
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: typescript-eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-21 13:33:38 +00:00
dependabot[bot]
189a460621 Bump the testing-library group in /extensions/ql-vscode with 1 update
Bumps the testing-library group in /extensions/ql-vscode with 1 update: [@testing-library/react](https://github.com/testing-library/react-testing-library).


Updates `@testing-library/react` from 14.2.1 to 14.2.2
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v14.2.1...v14.2.2)

---
updated-dependencies:
- dependency-name: "@testing-library/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: testing-library
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-21 13:33:15 +00:00
dependabot[bot]
79967b8aed Bump the storybook group in /extensions/ql-vscode with 1 update
Bumps the storybook group in /extensions/ql-vscode with 1 update: [@storybook/csf](https://github.com/ComponentDriven/csf).


Updates `@storybook/csf` from 0.1.2 to 0.1.3
- [Release notes](https://github.com/ComponentDriven/csf/releases)
- [Changelog](https://github.com/ComponentDriven/csf/blob/v0.1.3/CHANGELOG.md)
- [Commits](https://github.com/ComponentDriven/csf/compare/v0.1.2...v0.1.3)

---
updated-dependencies:
- dependency-name: "@storybook/csf"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-21 13:32:57 +00:00
Arthur Baars
cdacde3121 Merge pull request #3498 from github/github-action/bump-cli
Bump CLI Version to v2.16.5 for integration tests
2024-03-21 14:29:09 +01:00
github-actions[bot]
219840200c Bump CLI version from v2.16.4 to v2.16.5 for integration tests 2024-03-21 12:36:34 +00:00
Charis Kyriakou
175907d39c Add React components for showing model alert results (#3495) 2024-03-20 15:00:33 +00:00
Charis Kyriakou
a8a63a4633 Remove repoStates state tracking from model evaluation (#3496) 2024-03-20 14:59:58 +00:00
Shati Patel
83b0614162 Fix code scanning alert about duplicate command usage (#3497) 2024-03-20 14:37:45 +00:00
Koen Vlaswinkel
9e1ca91676 Merge pull request #3480 from github/dependabot/npm_and_yarn/extensions/ql-vscode/storybook-ea1bb043e9
Bump the storybook group in /extensions/ql-vscode with 11 updates
2024-03-20 14:50:38 +01:00
Charis Kyriakou
6c3b0b5bb1 Move AnalysisAlert mock creation to a factory module (#3493) 2024-03-20 12:03:06 +00:00
Robert
e7d2a59756 Merge pull request #3478 from github/robertbrignull/token-query
Simplify query now we've deleted withInheritedProgress
2024-03-20 11:38:42 +00:00
Koen Vlaswinkel
8c3d3b62f5 Move @storybook/icons to devDependencies 2024-03-20 12:28:47 +01:00
Koen Vlaswinkel
c110fd3e0b Switch from Webpack to Vite for Storybook
This simplifies the setup and makes it more similar to the "real"
extension setup since it also uses ESBuild (which is also used by Vite).
2024-03-20 12:26:59 +01:00
Koen Vlaswinkel
47cdd109a4 Merge pull request #3494 from github/version/bump-to-v1.12.5
Bump version to v1.12.5
2024-03-20 12:13:49 +01:00
Koen Vlaswinkel
c553b1cb1d Run storybook migrate mdx-to-csf 2024-03-20 12:08:36 +01:00
Koen Vlaswinkel
ee4b13c9e9 Fix deprecation warning 2024-03-20 12:06:08 +01:00
github-actions[bot]
1982ad45b8 Bump version to v1.12.5 2024-03-20 10:54:17 +00:00
Koen Vlaswinkel
fb77d628f1 Merge pull request #3492 from github/v1.12.4
v1.12.4
2024-03-20 11:52:56 +01:00
Shati Patel
36236680a4 Add model alerts stats to the view (#3481) 2024-03-20 10:14:39 +00:00
dependabot[bot]
de2fc2966d Bump the storybook group in /extensions/ql-vscode with 11 updates
Bumps the storybook group in /extensions/ql-vscode with 11 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `7.6.15` | `8.0.0` |
| [@storybook/addon-actions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/actions) | `7.6.4` | `8.0.0` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `7.6.4` | `8.0.0` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `7.6.4` | `8.0.0` |
| [@storybook/addon-links](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/links) | `7.6.4` | `8.0.0` |
| [@storybook/components](https://github.com/storybookjs/storybook/tree/HEAD/code/ui/components) | `7.6.17` | `8.0.0` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `7.6.7` | `8.0.0` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `7.6.12` | `8.0.0` |
| [@storybook/react-webpack5](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-webpack5) | `7.6.12` | `8.0.0` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `7.6.17` | `8.0.0` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `7.6.15` | `8.0.0` |


Updates `@storybook/addon-a11y` from 7.6.15 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/addons/a11y)

Updates `@storybook/addon-actions` from 7.6.4 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/addons/actions)

Updates `@storybook/addon-essentials` from 7.6.4 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/addons/essentials)

Updates `@storybook/addon-interactions` from 7.6.4 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/addons/interactions)

Updates `@storybook/addon-links` from 7.6.4 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/addons/links)

Updates `@storybook/components` from 7.6.17 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/ui/components)

Updates `@storybook/manager-api` from 7.6.7 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/lib/manager-api)

Updates `@storybook/react` from 7.6.12 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/renderers/react)

Updates `@storybook/react-webpack5` from 7.6.12 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/frameworks/react-webpack5)

Updates `@storybook/theming` from 7.6.17 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/lib/theming)

Updates `storybook` from 7.6.15 to 8.0.0
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.0.0/code/lib/cli)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/addon-actions"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/addon-links"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/components"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/react-webpack5"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
- dependency-name: storybook
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-14 16:19:27 +00:00
Robert
d65e6bea53 Simplify now we've deleted withInheritedProgress 2024-03-14 16:02:37 +00:00
Robert
ff889b73e1 Make documentation of fields more consistent 2024-03-13 18:09:51 +00:00
Robert
834b6a649e Use jest.MockedFunction 2024-03-13 18:06:44 +00:00
Robert
55b9b2e891 Use mocks instead of spies in tests 2024-03-12 15:44:17 +00:00
Robert
ec42728367 Only construct DatabaseFetcher once in extension.ts 2024-03-12 15:38:27 +00:00
Robert
9fa6d99f09 Have the skeleton query wizard call promptImportGithubDatabase so we can make more methods private 2024-03-12 15:32:44 +00:00
Robert
f29aff6303 Inline isFile 2024-03-12 15:32:44 +00:00
Robert
3ee081e8c6 Move commonly-used field to DatabaseFetcher constructor 2024-03-12 15:32:40 +00:00
Robert
18f1a46493 Naively convert DatabaseFetcher to a class 2024-03-12 15:14:00 +00:00
171 changed files with 8873 additions and 10759 deletions

View File

@@ -1,36 +1,16 @@
import javascript
abstract class ProgressBar extends CallExpr {
ProgressBar() { any() }
abstract Function getCallback();
abstract ObjectExpr getOptions();
class WithProgressCall extends CallExpr {
WithProgressCall() { this.getCalleeName() = "withProgress" }
predicate usesToken() { exists(this.getTokenParameter()) }
Parameter getTokenParameter() { result = this.getCallback().getParameter(1) }
Parameter getTokenParameter() { result = this.getArgument(0).(Function).getParameter(1) }
Property getCancellableProperty() { result = this.getOptions().getPropertyByName("cancellable") }
Property getCancellableProperty() { result = this.getArgument(1).(ObjectExpr).getPropertyByName("cancellable") }
predicate isCancellable() {
this.getCancellableProperty().getInit().(BooleanLiteral).getBoolValue() =
true
}
}
class WithProgressCall extends ProgressBar {
WithProgressCall() { this.getCalleeName() = "withProgress" }
override Function getCallback() { result = this.getArgument(0) }
override ObjectExpr getOptions() { result = this.getArgument(1) }
}
class WithInheritedProgressCall extends ProgressBar {
WithInheritedProgressCall() { this.getCalleeName() = "withInheritedProgress" }
override Function getCallback() { result = this.getArgument(1) }
override ObjectExpr getOptions() { result = this.getArgument(2) }
}

View File

@@ -12,7 +12,7 @@
import javascript
import ProgressBar
from ProgressBar t
from WithProgressCall t
where not t.isCancellable() and t.usesToken()
select t,
"The $@ should not be used when the progress bar is not cancellable. Either stop using the $@ or mark the progress bar as cancellable.",

View File

@@ -13,6 +13,6 @@
import javascript
import ProgressBar
from ProgressBar t
from WithProgressCall t
where t.isCancellable() and not t.usesToken()
select t, "This progress bar is $@ but the token is not used. Either use the token or mark the progress bar as not cancellable.", t.getCancellableProperty(), "cancellable"

View File

@@ -17,6 +17,9 @@ updates:
octokit:
patterns:
- "@octokit/*"
update-types:
- "minor"
- "patch"
storybook:
patterns:
- "@storybook/*"
@@ -34,3 +37,10 @@ updates:
day: "thursday" # Thursday is arbitrary
labels:
- "Update dependencies"
- package-ecosystem: docker
directory: "extensions/ql-vscode/test/e2e"
schedule:
interval: "weekly"
day: "thursday" # Thursday is arbitrary
labels:
- "Update dependencies"

View File

@@ -5,8 +5,4 @@
Replace this with a description of the changes your pull request makes.
## Checklist
- [ ] [CHANGELOG.md](https://github.com/github/vscode-codeql/blob/main/extensions/ql-vscode/CHANGELOG.md) has been updated to incorporate all user visible changes made by this pull request.
- [ ] Issues have been created for any UI or other user-facing changes made by this pull request.
- [ ] _[Maintainers only]_ If this pull request makes user-facing changes that require documentation changes, open a corresponding docs pull request in the [github/codeql](https://github.com/github/codeql/tree/main/docs/codeql/codeql-for-visual-studio-code) repo and add the `ready-for-doc-review` label there.
Remember to update the [changelog](https://github.com/github/vscode-codeql/blob/main/extensions/ql-vscode/CHANGELOG.md) if there have been user-facing changes!

View File

@@ -144,6 +144,19 @@ jobs:
matrix:
os: [ubuntu-latest, windows-latest]
steps:
# Enable 8.3 filename creation. This is not required to run the extension but it is required for the unit tests to pass.
# This feature is currently enabled by default in Windows 11 for the C: drive and therefore we must maintain support for it.
# This setting needs to be enabled before files are created, i.e. before we checkout the repository.
- name: Enable 8.3 filenames
shell: pwsh
if: ${{ matrix.os == 'windows-latest' }}
run: |
$shortNameEnableProcess = Start-Process -FilePath fsutil.exe -ArgumentList ('8dot3name', 'set', '0') -Wait -PassThru
$shortNameEnableExitCode = $shortNameEnableProcess.ExitCode
if ($shortNameEnableExitCode -ne 0) {
exit $shortNameEnableExitCode
}
- name: Checkout
uses: actions/checkout@v4
with:

View File

@@ -134,7 +134,7 @@ jobs:
- name: Publish to Registry
run: |
npx vsce publish -p $VSCE_TOKEN --packagePath *.vsix
npx @vscode/vsce publish -p $VSCE_TOKEN --packagePath *.vsix
open-vsx-publish:
name: Publish to Open VSX Registry

View File

@@ -111,4 +111,10 @@
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true,
},
"github.copilot.advanced": {
},
"codeQL.variantAnalysis.enableGhecDr": true,
"github-enterprise.uri": "http://server:8080/"
}

View File

@@ -28,6 +28,7 @@ Here are a few things you can do that will increase the likelihood of your pull
- [Integration tests that do require the VS Code API are located here](extensions/ql-vscode/src/vscode-tests).
- Keep your change as focused as possible. If there are multiple changes you would like to make that are not dependent upon each other, consider submitting them as separate pull requests.
- Write a [good commit message](https://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html).
- Update the [changelog](https://github.com/github/vscode-codeql/blob/main/extensions/ql-vscode/CHANGELOG.md) if you are making user-facing changes.
## Setting up a local build

View File

@@ -1,5 +1,6 @@
# Releasing (write access required)
1. Make sure the needed authentication keys are valid. Most likely the Azure DevOps PAT needs to be regenerated. See below.
1. Determine the new version number. We default to increasing the patch version number, but make our own judgement about whether a change is big enough to warrant a minor version bump. Common reasons for a minor bump could include:
- Making substantial new features available to all users. This can include lifting a feature flag.
- Breakage in compatibility with recent versions of the CLI.
@@ -60,7 +61,7 @@
## Secrets and authentication for publishing
Repository administrators, will need to manage the authentication keys for publishing to the VS Code marketplace and Open VSX. Each requires an authentication token. The VS Code marketplace token expires yearly.
Repository administrators, will need to manage the authentication keys for publishing to the VS Code marketplace and Open VSX. Each requires an authentication token.
To regenerate the Open VSX token:
@@ -69,4 +70,4 @@ To regenerate the Open VSX token:
1. Go to the [Access Tokens](https://open-vsx.org/user-settings/tokens) page and generate a new token.
1. Update the secret in the `publish-open-vsx` environment in the project settings.
To regenerate the VSCode Marketplace token, please see our internal documentation. Note that Azure DevOps PATs expire every 90 days and must be regenerated.
To regenerate the VSCode Marketplace token, please see our internal documentation. Note that Azure DevOps PATs expire every 7 days and must be regenerated.

View File

@@ -179,7 +179,7 @@ Run one of the above MRVAs, but cancel it from within VS Code:
import semmle.python.frameworks.data.internal.ApiGraphModelsExtensions
from string path, string kind
where sinkModel("vscode-codeql", path, kind)
where sinkModel("vscode-codeql", path, kind, _)
select path, kind
```
@@ -210,17 +210,7 @@ Run one of the above MRVAs, but cancel it from within VS Code:
4. Open the ".model.yml" file corresponding to the library that was changed.
- Check that the file contains entries for the methods that were modeled.
#### Test Case 3: Model with AI
Note that this test requires the feature flag: `codeQL.model.llmGeneration`
A package that the AI normally gives models for is `javax.servlet-api` from the `jhy/jsoup` repository.
1. Click "Model with AI".
- Check that rows change to "Thinking".
- Check that results come back and rows get filled out.
#### Test Case 4: Model as dependency
#### Test Case 3: Model as dependency
Note that this test requires the feature flag: `codeQL.model.flowGeneration`

View File

@@ -1,16 +0,0 @@
{
"sourceType": "unambiguous",
"presets": [
[
"@babel/preset-env",
{
"targets": {
"chrome": 100
}
}
],
"@babel/preset-typescript",
"@babel/preset-react"
],
"plugins": []
}

View File

@@ -48,7 +48,7 @@ const baseConfig = {
"@typescript-eslint/no-throw-literal": "error",
"@typescript-eslint/consistent-type-imports": "error",
"import/consistent-type-specifier-style": ["error", "prefer-top-level"],
curly: ["error", "all"],
// curly: ["error", "all"],
"escompat/no-regexp-lookbehind": "off",
"etc/no-implicit-any-catch": "error",
"filenames/match-regex": "off",

View File

@@ -1 +1 @@
v18.17.1
v20.9.0

View File

@@ -1,7 +1,7 @@
import type { StorybookConfig } from "@storybook/react-webpack5";
import type { StorybookConfig } from "@storybook/react-vite";
const config: StorybookConfig = {
stories: ["../src/**/*.stories.mdx", "../src/**/*.stories.@(js|jsx|ts|tsx)"],
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|ts|tsx)"],
addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
@@ -10,7 +10,7 @@ const config: StorybookConfig = {
"./vscode-theme-addon/preset.ts",
],
framework: {
name: "@storybook/react-webpack5",
name: "@storybook/react-vite",
options: {},
},
docs: {

View File

@@ -5,10 +5,10 @@ import { useCallback } from "react";
import { useGlobals } from "@storybook/manager-api";
import {
IconButton,
Icons,
TooltipLinkList,
WithTooltip,
} from "@storybook/components";
import { DashboardIcon } from "@storybook/icons";
import { themeNames, VSCodeTheme } from "./theme";
@@ -53,7 +53,7 @@ export const ThemeSelector: FunctionComponent = () => {
title="Change the theme of the preview"
active={vscodeTheme !== VSCodeTheme.Dark}
>
<Icons icon="dashboard" />
<DashboardIcon />
</IconButton>
</WithTooltip>
);

View File

@@ -1,3 +1,5 @@
/// <reference types="vite/client" />
import { useEffect } from "react";
import type {
PartialStoryFn as StoryFunction,
@@ -6,31 +8,20 @@ import type {
import { VSCodeTheme } from "./theme";
import darkThemeStyle from "../../src/stories/vscode-theme-dark.css?url";
import lightThemeStyle from "../../src/stories/vscode-theme-light.css?url";
import lightHighContrastThemeStyle from "../../src/stories/vscode-theme-light-high-contrast.css?url";
import darkHighContrastThemeStyle from "../../src/stories/vscode-theme-dark-high-contrast.css?url";
import githubLightDefaultThemeStyle from "../../src/stories/vscode-theme-github-light-default.css?url";
import githubDarkDefaultThemeStyle from "../../src/stories/vscode-theme-github-dark-default.css?url";
const themeFiles: { [key in VSCodeTheme]: string } = {
[VSCodeTheme.Dark]:
// eslint-disable-next-line @typescript-eslint/no-var-requires,import/no-commonjs,import/no-webpack-loader-syntax
require("!file-loader?modules!../../src/stories/vscode-theme-dark.css")
.default,
[VSCodeTheme.Light]:
// eslint-disable-next-line @typescript-eslint/no-var-requires,import/no-commonjs,import/no-webpack-loader-syntax
require("!file-loader?modules!../../src/stories/vscode-theme-light.css")
.default,
[VSCodeTheme.LightHighContrast]:
// eslint-disable-next-line @typescript-eslint/no-var-requires,import/no-commonjs,import/no-webpack-loader-syntax
require("!file-loader?modules!../../src/stories/vscode-theme-light-high-contrast.css")
.default,
[VSCodeTheme.DarkHighContrast]:
// eslint-disable-next-line @typescript-eslint/no-var-requires,import/no-commonjs,import/no-webpack-loader-syntax
require("!file-loader?modules!../../src/stories/vscode-theme-dark-high-contrast.css")
.default,
[VSCodeTheme.GitHubLightDefault]:
// eslint-disable-next-line @typescript-eslint/no-var-requires,import/no-commonjs,import/no-webpack-loader-syntax
require("!file-loader?modules!../../src/stories/vscode-theme-github-light-default.css")
.default,
[VSCodeTheme.GitHubDarkDefault]:
// eslint-disable-next-line @typescript-eslint/no-var-requires,import/no-commonjs,import/no-webpack-loader-syntax
require("!file-loader?modules!../../src/stories/vscode-theme-github-dark-default.css")
.default,
[VSCodeTheme.Dark]: darkThemeStyle,
[VSCodeTheme.Light]: lightThemeStyle,
[VSCodeTheme.LightHighContrast]: lightHighContrastThemeStyle,
[VSCodeTheme.DarkHighContrast]: darkHighContrastThemeStyle,
[VSCodeTheme.GitHubLightDefault]: githubLightDefaultThemeStyle,
[VSCodeTheme.GitHubDarkDefault]: githubDarkDefaultThemeStyle,
};
export const withTheme = (StoryFn: StoryFunction, context: StoryContext) => {

View File

@@ -1,5 +1,23 @@
# CodeQL for Visual Studio Code: Changelog
## [UNRELEASED]
## 1.13.1 - 29 May 2024
- Fix a bug when re-importing test databases that erroneously showed old source code. [#3616](https://github.com/github/vscode-codeql/pull/3616)
- Update the progress window with details on potentially long-running post-processing steps after running a query. [#3622](https://github.com/github/vscode-codeql/pull/3622)
## 1.13.0 - 1 May 2024
- Add Ruby support to the CodeQL Model Editor. [#3584](https://github.com/github/vscode-codeql/pull/3584)
- Remove support for CodeQL CLI versions older than 2.14.6. [#3562](https://github.com/github/vscode-codeql/pull/3562)
## 1.12.5 - 9 April 2024
- Add new supported source and sink kinds in the CodeQL Model Editor [#3511](https://github.com/github/vscode-codeql/pull/3511)
- Fix a bug where the test explorer wouldn't display certain tests. [#3527](https://github.com/github/vscode-codeql/pull/3527)
- The "model dependency" operation in the model editor can now be cancelled. [#3517](https://github.com/github/vscode-codeql/pull/3517)
## 1.12.4 - 20 March 2024
- Don't show notification after local query cancellation. [#3489](https://github.com/github/vscode-codeql/pull/3489)
@@ -486,7 +504,7 @@ No user facing changes.
- Allow setting `codeQL.runningQueries.numberOfThreads` and `codeQL.runningTests.numberOfThreads` to 0, (which is interpreted as 'use one thread per core on the machine').
- Clear the problems view of all CodeQL query results when a database is removed.
- Add a `View DIL` command on query history items. This opens a text editor containing the Datalog Intermediary Language representation of the compiled query.
- Remove feature flag for the AST Viewer. For more information on how to use the AST Viewer, [see the documentation](https://help.semmle.com/codeql/codeql-for-vscode/procedures/exploring-the-structure-of-your-source-code.html).
- Remove feature flag for the AST Viewer. For more information on how to use the AST Viewer, [see the documentation](https://codeql.github.com/docs/codeql-for-visual-studio-code/exploring-the-structure-of-your-source-code/).
- The `codeQL.runningTests.numberOfThreads` setting is now used correctly when running tests.
- Alter structure of the _Test Explorer_ tree. It now follows the structure of the filesystem instead of the qlpacks.
- Ensure output of CodeQL test runs includes compilation error messages and test failure messages.

View File

@@ -9,10 +9,12 @@ This project is an extension for Visual Studio Code that adds rich language supp
To see what has changed in the last few versions of the extension, see the [Changelog](https://github.com/github/vscode-codeql/blob/main/extensions/ql-vscode/CHANGELOG.md).
You can also read full documentation for the extension on the [GitHub documentation website](https://docs.github.com/code-security/codeql-for-vs-code/using-the-advanced-functionality-of-the-codeql-for-vs-code-extension).
## Quick start overview
The information in this `README` file describes the quickest way to start using CodeQL.
For information about other configurations, see the separate [CodeQL help](https://codeql.github.com/docs/codeql-for-visual-studio-code/).
For information about other configurations, see "[Using the advanced functionality of the CodeQL for VS Code extension](https://docs.github.com/code-security/codeql-for-vs-code/using-the-advanced-functionality-of-the-codeql-for-vs-code-extension)" in the GitHub documentation.
### Quick start: Installing and configuring the extension
@@ -42,7 +44,7 @@ The CodeQL extension requires a minimum of Visual Studio Code 1.39. Older versio
The extension uses the [CodeQL CLI](https://codeql.github.com/docs/codeql-cli/) to compile and run queries. The extension automatically manages access to the CLI for you by default (recommended). To check for updates to the CodeQL CLI, you can use the **CodeQL: Check for CLI Updates** command.
If you want to override the default behavior and use a CodeQL CLI that's already on your machine, see [Configuring access to the CodeQL CLI](https://codeql.github.com/docs/codeql-for-visual-studio-code/setting-up-codeql-in-visual-studio-code/#configuring-access-to-the-codeql-cli).
If you want to override the default behavior and use a CodeQL CLI that's already on your machine, see "[Configuring access to the CodeQL CLI](https://docs.github.com/code-security/codeql-for-vs-code/using-the-advanced-functionality-of-the-codeql-for-vs-code-extension/configuring-access-to-the-codeql-cli)" in the GitHub documentation.
If you have any difficulty with CodeQL CLI access, see the **CodeQL Extension Log** in the **Output** view for any error messages.
@@ -52,7 +54,7 @@ When you're working with CodeQL, you need access to the standard CodeQL librarie
Initially, we recommend that you clone and use the ready-to-use [starter workspace](https://github.com/github/vscode-codeql-starter/).
This includes libraries and queries for the main supported languages, with folders set up ready for your custom queries. After cloning the workspace (use `git clone --recursive`), you can use it in the same way as any other VS Code workspace—with the added advantage that you can easily update the CodeQL libraries.
For information about configuring an existing workspace for CodeQL, [see the documentation](https://codeql.github.com/docs/codeql-for-visual-studio-code/setting-up-codeql-in-visual-studio-code/#updating-an-existing-workspace-for-codeql).
For information about configuring an existing workspace for CodeQL, see "[Setting up a CodeQL workspace](https://docs.github.com/code-security/codeql-for-vs-code/using-the-advanced-functionality-of-the-codeql-for-vs-code-extension/setting-up-a-codeql-workspace#option-2-updating-an-existing-workspace-for-codeql-advanced)" in the GitHub documentation.
## Upgrading CodeQL standard libraries
@@ -85,7 +87,7 @@ While you can use the [CodeQL CLI to create your own databases](https://codeql.g
1. Select the language for the database you want to download (only required if the project has databases for multiple languages).
1. Once the CodeQL database has been imported, it is displayed in the Databases view.
For more information, see [Choosing a database](https://codeql.github.com/docs/codeql-for-visual-studio-code/analyzing-your-projects/#choosing-a-database) on codeql.github.com.
For more information, see "[Managing CodeQL databases](https://docs.github.com/code-security/codeql-for-vs-code/getting-started-with-codeql-for-vs-code/managing-codeql-databases#choosing-a-database-to-analyze)" in the GitHub documentation.
### Running a query
@@ -106,12 +108,12 @@ If you wish to navigate the query results from your keyboard, you can bind short
## What next?
For more information about the CodeQL extension, [see the documentation](https://codeql.github.com/docs/codeql-for-visual-studio-code/). Otherwise, you could:
We recommend reading the [full documentation for the extension](https://docs.github.com/code-security/codeql-for-vs-code/) on the GitHub documentation website. You may also find the following resources useful:
- [Create a database for a different codebase](https://codeql.github.com/docs/codeql-cli/creating-codeql-databases/).
- [Try out variant analysis](https://help.semmle.com/QL/learn-ql/ql-training.html).
- [Try out variant analysis](https://docs.github.com/code-security/codeql-for-vs-code/getting-started-with-codeql-for-vs-code/running-codeql-queries-at-scale-with-multi-repository-variant-analysis).
- [Learn more about CodeQL](https://codeql.github.com/docs/).
- [Read how security researchers use CodeQL to find CVEs](https://securitylab.github.com/research).
- [Read how security researchers use CodeQL to find CVEs](https://github.blog/tag/github-security-lab/).
## License
@@ -119,4 +121,4 @@ The CodeQL extension for Visual Studio Code is [licensed](LICENSE.md) under the
## Data and Telemetry
If you specifically opt-in to permit GitHub to do so, GitHub will collect usage data and metrics for the purposes of helping the core developers to improve the CodeQL extension for VS Code. This data will not be shared with any parties outside of GitHub. IP addresses and installation IDs will be retained for a maximum of 30 days. Anonymous data will be retained for a maximum of 180 days. For more information about telemetry, [see the documentation](https://codeql.github.com/docs/codeql-for-visual-studio-code/about-telemetry-in-codeql-for-visual-studio-code).
If you specifically opt-in to permit GitHub to do so, GitHub will collect usage data and metrics for the purposes of helping the core developers to improve the CodeQL extension for VS Code. This data will not be shared with any parties outside of GitHub. IP addresses and installation IDs will be retained for a maximum of 30 days. Anonymous data will be retained for a maximum of 180 days. For more information, see "[Telemetry in CodeQL for Visual Studio Code](https://docs.github.com/code-security/codeql-for-vs-code/using-the-advanced-functionality-of-the-codeql-for-vs-code-extension/telemetry-in-codeql-for-visual-studio-code)" in the GitHub documentation.

File diff suppressed because it is too large Load Diff

View File

@@ -4,7 +4,7 @@
"description": "CodeQL for Visual Studio Code",
"author": "GitHub",
"private": true,
"version": "1.12.4",
"version": "1.13.2",
"publisher": "GitHub",
"license": "MIT",
"icon": "media/VS-marketplace-CodeQL-icon.png",
@@ -14,7 +14,7 @@
},
"engines": {
"vscode": "^1.82.0",
"node": "^18.17.1",
"node": "^20.9.0",
"npm": ">=7.20.6"
},
"categories": [
@@ -339,13 +339,6 @@
"title": "Variant analysis",
"order": 5,
"properties": {
"codeQL.variantAnalysis.controllerRepo": {
"type": "string",
"default": "",
"pattern": "^$|^(?:[a-zA-Z0-9]+-)*[a-zA-Z0-9]+/[a-zA-Z0-9-_]+$",
"patternErrorMessage": "Please enter a valid GitHub repository",
"markdownDescription": "[For internal use only] The name of the GitHub repository in which the GitHub Actions workflow is run when using the \"Run Variant Analysis\" command. The repository should be of the form `<owner>/<repo>`)."
},
"codeQL.variantAnalysis.defaultResultsFilter": {
"type": "string",
"default": "all",
@@ -463,8 +456,25 @@
},
{
"type": "object",
"title": "Log insights",
"title": "Model Editor",
"order": 9,
"properties": {
"codeQL.model.packLocation": {
"type": "string",
"default": ".github/codeql/extensions/${name}-${language}",
"markdownDescription": "Location for newly created CodeQL model packs. The location can be either absolute or relative. If relative, it is relative to the workspace root.\n\nThe following variables are supported:\n* **${database}** - the name of the database\n* **${language}** - the name of the language\n* **${name}** - the name of the GitHub repository, or the name of the database if the database was not downloaded from GitHub\n* **${owner}** - the owner of the GitHub repository, or an empty string if the database was not downloaded from GitHub"
},
"codeQL.model.packName": {
"type": "string",
"default": "${owner}/${name}-${language}",
"markdownDescription": "Name of newly created CodeQL model packs. If the result is not a valid pack name, it will be converted to a valid pack name.\n\nThe following variables are supported:\n* **${database}** - the name of the database\n* **${language}** - the name of the language\n* **${name}** - the name of the GitHub repository, or the name of the database if the database was not downloaded from GitHub\n* **${owner}** - the owner of the GitHub repository, or an empty string if the database was not downloaded from GitHub"
}
}
},
{
"type": "object",
"title": "Log insights",
"order": 10,
"properties": {
"codeQL.logInsights.joinOrderWarningThreshold": {
"type": "number",
@@ -478,7 +488,7 @@
{
"type": "object",
"title": "Telemetry",
"order": 10,
"order": 11,
"properties": {
"codeQL.telemetry.enableTelemetry": {
"type": "boolean",
@@ -1914,11 +1924,6 @@
{
"view": "codeQLEvalLogViewer",
"contents": "Run the 'Show Evaluator Log (UI)' command on a CodeQL query run in the Query History view."
},
{
"view": "codeQLVariantAnalysisRepositories",
"contents": "Set up a controller repository to start using variant analysis. [Learn more](https://codeql.github.com/docs/codeql-for-visual-studio-code/running-codeql-queries-at-scale-with-mrva#controller-repository) about controller repositories. \n[Set up controller repository](command:codeQLVariantAnalysisRepositories.setupControllerRepository)",
"when": "!config.codeQL.variantAnalysis.controllerRepo"
}
]
},
@@ -1938,44 +1943,45 @@
"format": "prettier --write **/*.{ts,tsx} && eslint . --ext .ts,.tsx --fix",
"lint": "eslint . --ext .js,.ts,.tsx --max-warnings=0",
"lint:markdown": "markdownlint-cli2 \"../../**/*.{md,mdx}\" \"!**/node_modules/**\" \"!**/.vscode-test/**\" \"!**/build/cli/v*/**\"",
"find-deadcode": "ts-node scripts/find-deadcode.ts",
"find-deadcode": "vite-node scripts/find-deadcode.ts",
"format-staged": "lint-staged",
"storybook": "storybook dev -p 6006",
"build-storybook": "storybook build",
"lint:scenarios": "ts-node scripts/lint-scenarios.ts",
"lint:scenarios": "vite-node scripts/lint-scenarios.ts",
"generate": "npm-run-all -p generate:*",
"generate:schemas": "ts-node scripts/generate-schemas.ts",
"generate:chromium-version": "ts-node scripts/generate-chromium-version.ts",
"generate:schemas": "vite-node scripts/generate-schemas.ts",
"generate:chromium-version": "vite-node scripts/generate-chromium-version.ts",
"check-types": "find . -type f -name \"tsconfig.json\" -not -path \"./node_modules/*\" | sed -r 's|/[^/]+$||' | sort | uniq | xargs -I {} sh -c \"echo Checking types in {} && cd {} && npx tsc --noEmit\"",
"postinstall": "patch-package",
"prepare": "cd ../.. && husky install"
},
"dependencies": {
"@floating-ui/react": "^0.26.9",
"@floating-ui/react": "^0.26.12",
"@octokit/plugin-retry": "^6.0.1",
"@octokit/plugin-throttling": "^8.0.0",
"@octokit/rest": "^20.0.2",
"@vscode/codicons": "^0.0.35",
"@vscode/debugadapter": "^1.59.0",
"@vscode/debugprotocol": "^1.59.0",
"@vscode/debugprotocol": "^1.65.0",
"@vscode/webview-ui-toolkit": "^1.0.1",
"ajv": "^8.11.0",
"child-process-promise": "^2.2.1",
"chokidar": "^3.6.0",
"d3": "^7.6.1",
"d3": "^7.9.0",
"d3-graphviz": "^5.0.2",
"fs-extra": "^11.1.1",
"js-yaml": "^4.1.0",
"msw": "^2.0.13",
"nanoid": "^5.0.6",
"msw": "^2.2.13",
"nanoid": "^5.0.7",
"node-fetch": "^2.6.7",
"p-queue": "^8.0.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"semver": "^7.6.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"semver": "^7.6.2",
"source-map": "^0.7.4",
"source-map-support": "^0.5.21",
"stream-json": "^1.7.3",
"styled-components": "^6.1.8",
"styled-components": "^6.1.9",
"tmp": "^0.2.1",
"tmp-promise": "^3.0.2",
"tree-kill": "^1.2.2",
@@ -1986,29 +1992,30 @@
"zip-a-folder": "^3.1.6"
},
"devDependencies": {
"@babel/core": "^7.24.0",
"@babel/core": "^7.24.6",
"@babel/plugin-transform-modules-commonjs": "^7.18.6",
"@babel/preset-env": "^7.24.0",
"@babel/preset-react": "^7.18.6",
"@babel/preset-env": "^7.24.4",
"@babel/preset-react": "^7.24.1",
"@babel/preset-typescript": "^7.21.4",
"@faker-js/faker": "^8.4.1",
"@github/markdownlint-github": "^0.6.0",
"@octokit/plugin-throttling": "^8.0.0",
"@github/markdownlint-github": "^0.6.2",
"@playwright/test": "^1.40.1",
"@storybook/addon-a11y": "^7.6.15",
"@storybook/addon-actions": "^7.1.0",
"@storybook/addon-essentials": "^7.1.0",
"@storybook/addon-interactions": "^7.1.0",
"@storybook/addon-links": "^7.1.0",
"@storybook/components": "^7.6.17",
"@storybook/csf": "^0.1.1",
"@storybook/manager-api": "^7.6.7",
"@storybook/react": "^7.1.0",
"@storybook/react-webpack5": "^7.6.12",
"@storybook/theming": "^7.6.12",
"@testing-library/dom": "^9.3.4",
"@testing-library/jest-dom": "^6.4.2",
"@testing-library/react": "^14.2.1",
"@storybook/addon-a11y": "^8.1.10",
"@storybook/addon-actions": "^8.1.10",
"@storybook/addon-essentials": "^8.1.10",
"@storybook/addon-interactions": "^8.1.10",
"@storybook/addon-links": "^8.1.10",
"@storybook/blocks": "^8.0.2",
"@storybook/components": "^8.0.2",
"@storybook/csf": "^0.1.8",
"@storybook/icons": "^1.2.9",
"@storybook/manager-api": "^8.1.10",
"@storybook/react": "^8.1.10",
"@storybook/react-vite": "^8.1.10",
"@storybook/theming": "^8.1.10",
"@testing-library/dom": "^10.1.0",
"@testing-library/jest-dom": "^6.4.6",
"@testing-library/react": "^16.0.0",
"@testing-library/user-event": "^14.5.2",
"@types/child-process-promise": "^2.2.1",
"@types/d3": "^7.4.0",
@@ -2020,12 +2027,12 @@
"@types/jest": "^29.5.12",
"@types/js-yaml": "^4.0.6",
"@types/nanoid": "^3.0.0",
"@types/node": "18.17.*",
"@types/node": "20.9.*",
"@types/node-fetch": "^2.5.2",
"@types/react": "^18.0.28",
"@types/react-dom": "^18.2.18",
"@types/react": "^18.3.1",
"@types/react-dom": "^18.3.0",
"@types/sarif": "^2.1.2",
"@types/semver": "^7.2.0",
"@types/semver": "^7.5.8",
"@types/stream-json": "^1.7.1",
"@types/styled-components": "^5.1.11",
"@types/tar-stream": "^3.1.3",
@@ -2033,54 +2040,52 @@
"@types/tmp": "^0.2.6",
"@types/vscode": "^1.82.0",
"@types/yauzl": "^2.10.3",
"@typescript-eslint/eslint-plugin": "^7.2.0",
"@typescript-eslint/parser": "^6.21.0",
"@typescript-eslint/eslint-plugin": "^7.5.0",
"@typescript-eslint/parser": "^7.5.0",
"@vscode/test-electron": "^2.3.9",
"@vscode/vsce": "^2.24.0",
"ansi-colors": "^4.1.1",
"applicationinsights": "^2.9.4",
"applicationinsights": "^2.9.5",
"cosmiconfig": "^9.0.0",
"cross-env": "^7.0.3",
"css-loader": "^6.10.0",
"del": "^6.0.0",
"eslint": "^8.56.0",
"eslint-config-prettier": "^9.0.0",
"eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-deprecation": "^2.0.0",
"eslint-plugin-etc": "^2.0.2",
"eslint-plugin-github": "^4.4.1",
"eslint-plugin-github": "^4.10.2",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jest-dom": "^5.0.1",
"eslint-plugin-jest-dom": "^5.2.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.31.8",
"eslint-plugin-react": "^7.34.1",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-storybook": "^0.8.0",
"file-loader": "^6.2.0",
"glob": "^10.0.0",
"gulp": "^4.0.2",
"gulp-esbuild": "^0.12.0",
"gulp-replace": "^1.1.3",
"gulp-typescript": "^5.0.1",
"husky": "^8.0.0",
"husky": "^9.1.7",
"jest": "^29.0.3",
"jest-environment-jsdom": "^29.0.3",
"jest-runner-vscode": "^3.0.1",
"lint-staged": "^15.0.2",
"markdownlint-cli2": "^0.12.1",
"markdownlint-cli2-formatter-pretty": "^0.0.5",
"mini-css-extract-plugin": "^2.8.1",
"lint-staged": "^15.2.2",
"markdownlint-cli2": "^0.13.0",
"markdownlint-cli2-formatter-pretty": "^0.0.6",
"npm-run-all": "^4.1.5",
"patch-package": "^8.0.0",
"prettier": "^3.2.5",
"storybook": "^7.6.15",
"storybook": "^8.1.10",
"tar-stream": "^3.1.7",
"through2": "^4.0.2",
"ts-jest": "^29.0.1",
"ts-json-schema-generator": "^1.1.2",
"ts-loader": "^9.4.2",
"ts-node": "^10.7.0",
"ts-unused-exports": "^10.0.0",
"typescript": "^5.0.2"
"ts-jest": "^29.1.4",
"ts-json-schema-generator": "^2.1.1",
"ts-node": "^10.9.2",
"ts-unused-exports": "^10.1.0",
"typescript": "^5.0.2",
"vite": "^5.2.11",
"vite-node": "^1.5.3"
},
"lint-staged": {
"./**/*.{json,css,scss}": [

File diff suppressed because it is too large Load Diff

View File

@@ -31,4 +31,9 @@ export interface Credentials {
* @returns An OAuth access token, or undefined.
*/
getExistingAccessToken(): Promise<string | undefined>;
/**
* Returns the ID of the authentication provider to use.
*/
authProviderId: string;
}

View File

@@ -273,6 +273,9 @@ export type VariantAnalysisCommands = {
"codeQL.openVariantAnalysisLogs": (
variantAnalysisId: number,
) => Promise<void>;
"codeQLModelAlerts.openVariantAnalysisLogs": (
variantAnalysisId: number,
) => Promise<void>;
"codeQL.openVariantAnalysisView": (
variantAnalysisId: number,
) => Promise<void>;
@@ -287,7 +290,6 @@ export type DatabasePanelCommands = {
"codeQLVariantAnalysisRepositories.openConfigFile": () => Promise<void>;
"codeQLVariantAnalysisRepositories.addNewDatabase": () => Promise<void>;
"codeQLVariantAnalysisRepositories.addNewList": () => Promise<void>;
"codeQLVariantAnalysisRepositories.setupControllerRepository": () => Promise<void>;
"codeQLVariantAnalysisRepositories.setSelectedItem": TreeViewContextSingleSelectionCommandFunction<DbTreeViewItem>;
"codeQLVariantAnalysisRepositories.setSelectedItemContextMenu": TreeViewContextSingleSelectionCommandFunction<DbTreeViewItem>;

View File

@@ -0,0 +1,57 @@
// Based on https://github.com/microsoft/vscode/blob/edfd5b8ba54d50f3f5c2ebee877af088803def88/src/vs/base/common/labels.ts#L316C1-L400
/**
* Helper to insert values for specific template variables into the string. E.g. "this ${is} a ${template}" can be
* passed to this function together with an object that maps "is" and "template" to strings to have them replaced.
*
* @param template string to which template is applied
* @param values the values of the templates to use
*/
export function substituteConfigVariables(
template: string,
values: {
[key: string]: string | undefined | null;
},
): string {
const segments: string[] = [];
let inVariable = false;
let currentValue = "";
for (const char of template) {
// Beginning of variable
if (char === "$" || (inVariable && char === "{")) {
if (currentValue) {
segments.push(currentValue);
}
currentValue = "";
inVariable = true;
}
// End of variable
else if (char === "}" && inVariable) {
const resolved = values[currentValue];
// Variable
if (resolved && resolved.length > 0) {
segments.push(resolved);
}
// If the variable, doesn't exist, we discard it (i.e. replace it by the empty string)
currentValue = "";
inVariable = false;
}
// Text or Variable Name
else {
currentValue += char;
}
}
// Tail
if (currentValue && !inVariable) {
segments.push(currentValue);
}
return segments.join("");
}

View File

@@ -29,37 +29,45 @@ function validGitHubNwoOrOwner(
/**
* Extracts an NWO from a GitHub URL.
* @param githubUrl The GitHub repository URL
* @param repositoryUrl The GitHub repository URL
* @param githubUrl The URL of the GitHub instance
* @return The corresponding NWO, or undefined if the URL is not valid
*/
export function getNwoFromGitHubUrl(githubUrl: string): string | undefined {
return getNwoOrOwnerFromGitHubUrl(githubUrl, "nwo");
export function getNwoFromGitHubUrl(
repositoryUrl: string,
githubUrl: URL,
): string | undefined {
return getNwoOrOwnerFromGitHubUrl(repositoryUrl, githubUrl, "nwo");
}
/**
* Extracts an owner from a GitHub URL.
* @param githubUrl The GitHub repository URL
* @param repositoryUrl The GitHub repository URL
* @param githubUrl The URL of the GitHub instance
* @return The corresponding Owner, or undefined if the URL is not valid
*/
export function getOwnerFromGitHubUrl(githubUrl: string): string | undefined {
return getNwoOrOwnerFromGitHubUrl(githubUrl, "owner");
export function getOwnerFromGitHubUrl(
repositoryUrl: string,
githubUrl: URL,
): string | undefined {
return getNwoOrOwnerFromGitHubUrl(repositoryUrl, githubUrl, "owner");
}
function getNwoOrOwnerFromGitHubUrl(
githubUrl: string,
repositoryUrl: string,
githubUrl: URL,
kind: "owner" | "nwo",
): string | undefined {
const validHostnames = [githubUrl.hostname, `www.${githubUrl.hostname}`];
try {
let paths: string[];
const urlElements = githubUrl.split("/");
if (
urlElements[0] === "github.com" ||
urlElements[0] === "www.github.com"
) {
paths = githubUrl.split("/").slice(1);
const urlElements = repositoryUrl.split("/");
if (validHostnames.includes(urlElements[0])) {
paths = repositoryUrl.split("/").slice(1);
} else {
const uri = new URL(githubUrl);
if (uri.hostname !== "github.com" && uri.hostname !== "www.github.com") {
const uri = new URL(repositoryUrl);
if (!validHostnames.includes(uri.hostname)) {
return;
}
paths = uri.pathname.split("/").filter((segment: string) => segment);

View File

@@ -10,7 +10,7 @@ import type {
} from "../variant-analysis/shared/variant-analysis-filter-sort";
import type { ErrorLike } from "../common/errors";
import type { DataFlowPaths } from "../variant-analysis/shared/data-flow-paths";
import type { Method } from "../model-editor/method";
import type { Method, MethodSignature } from "../model-editor/method";
import type { ModeledMethod } from "../model-editor/modeled-method";
import type {
MethodModelingPanelViewState,
@@ -605,6 +605,11 @@ interface OpenModelAlertsViewMessage {
t: "openModelAlertsView";
}
interface RevealInModelAlertsViewMessage {
t: "revealInModelAlertsView";
modeledMethod: ModeledMethod;
}
interface ModelDependencyMessage {
t: "modelDependency";
}
@@ -677,11 +682,12 @@ export type FromModelEditorMessage =
| SetMultipleModeledMethodsMessage
| StartModelEvaluationMessage
| StopModelEvaluationMessage
| OpenModelAlertsViewMessage;
| OpenModelAlertsViewMessage
| RevealInModelAlertsViewMessage;
interface RevealInEditorMessage {
t: "revealInModelEditor";
method: Method;
method: MethodSignature;
}
interface StartModelingMessage {
@@ -737,17 +743,29 @@ interface OpenModelPackMessage {
path: string;
}
interface OpenActionsLogsMessage {
t: "openActionsLogs";
variantAnalysisId: number;
}
interface StopEvaluationRunMessage {
t: "stopEvaluationRun";
}
interface RevealModelMessage {
t: "revealModel";
modeledMethod: ModeledMethod;
}
export type ToModelAlertsMessage =
| SetModelAlertsViewStateMessage
| SetVariantAnalysisMessage
| SetRepoResultsMessage
| SetRepoStatesMessage;
| RevealModelMessage;
export type FromModelAlertsMessage =
| CommonFromViewMessages
| OpenModelPackMessage
| StopEvaluationRunMessage;
| OpenActionsLogsMessage
| StopEvaluationRunMessage
| RevealInEditorMessage;

View File

@@ -1,7 +1,10 @@
import { appendFile, ensureFile } from "fs-extra";
import { ensureFile } from "fs-extra";
import { open } from "node:fs/promises";
import type { FileHandle } from "node:fs/promises";
import { isAbsolute } from "path";
import { getErrorMessage } from "../helpers-pure";
import type { Logger, LogOptions } from "./logger";
import type { Disposable } from "../disposable-object";
/**
* An implementation of {@link Logger} that sends the output both to another {@link Logger}
@@ -10,9 +13,10 @@ import type { Logger, LogOptions } from "./logger";
* The first time a message is written, an additional banner is written to the underlying logger
* pointing the user to the "side log" file.
*/
export class TeeLogger implements Logger {
export class TeeLogger implements Logger, Disposable {
private emittedRedirectMessage = false;
private error = false;
private fileHandle: FileHandle | undefined = undefined;
public constructor(
private readonly logger: Logger,
@@ -37,11 +41,15 @@ export class TeeLogger implements Logger {
if (!this.error) {
try {
const trailingNewline = options.trailingNewline ?? true;
await ensureFile(this.location);
if (!this.fileHandle) {
await ensureFile(this.location);
await appendFile(
this.location,
this.fileHandle = await open(this.location, "a");
}
const trailingNewline = options.trailingNewline ?? true;
await this.fileHandle.appendFile(
message + (trailingNewline ? "\n" : ""),
{
encoding: "utf8",
@@ -50,6 +58,14 @@ export class TeeLogger implements Logger {
} catch (e) {
// Write an error message to the primary log, and stop trying to write to the side log.
this.error = true;
try {
await this.fileHandle?.close();
} catch (e) {
void this.logger.log(
`Failed to close file handle: ${getErrorMessage(e)}`,
);
}
this.fileHandle = undefined;
const errorMessage = getErrorMessage(e);
await this.logger.log(
`Error writing to additional log file: ${errorMessage}`,
@@ -65,4 +81,15 @@ export class TeeLogger implements Logger {
show(preserveFocus?: boolean): void {
this.logger.show(preserveFocus);
}
dispose(): void {
try {
void this.fileHandle?.close();
} catch (e) {
void this.logger.log(
`Failed to close file handle: ${getErrorMessage(e)}`,
);
}
this.fileHandle = undefined;
}
}

View File

@@ -26,6 +26,8 @@ import {
// All path operations in this file must be on paths *within* the zip
// archive.
import { posix } from "path";
import { DatabaseEventKind } from "../../databases/local-databases/database-events";
import type { DatabaseManager } from "../../databases/local-databases/database-manager";
const path = posix;
@@ -242,6 +244,10 @@ export class ArchiveFileSystemProvider implements FileSystemProvider {
root = new Directory("");
flushCache(zipPath: string) {
this.archives.delete(zipPath);
}
// metadata
async stat(uri: Uri): Promise<FileStat> {
@@ -355,15 +361,35 @@ export class ArchiveFileSystemProvider implements FileSystemProvider {
*/
export const zipArchiveScheme = "codeql-zip-archive";
export function activate(ctx: ExtensionContext) {
export function activate(ctx: ExtensionContext, dbm?: DatabaseManager) {
const afsp = new ArchiveFileSystemProvider();
if (dbm) {
ctx.subscriptions.push(
dbm.onDidChangeDatabaseItem(async ({ kind, item: db }) => {
if (kind === DatabaseEventKind.Remove) {
if (db?.sourceArchive) {
afsp.flushCache(db.sourceArchive.fsPath);
}
}
}),
);
}
ctx.subscriptions.push(
workspace.registerFileSystemProvider(
zipArchiveScheme,
new ArchiveFileSystemProvider(),
{
isCaseSensitive: true,
isReadonly: true,
},
),
// When a file system archive is removed from the workspace, we should
// also remove it from our cache.
workspace.onDidChangeWorkspaceFolders((event) => {
for (const removed of event.removed) {
const zipPath = removed.uri.fsPath;
afsp.flushCache(zipPath);
}
}),
);
ctx.subscriptions.push(
workspace.registerFileSystemProvider(zipArchiveScheme, afsp, {
isCaseSensitive: true,
isReadonly: true,
}),
);
}

View File

@@ -2,8 +2,8 @@ import { authentication } from "vscode";
import type { Octokit } from "@octokit/rest";
import type { Credentials } from "../authentication";
import { AppOctokit } from "../octokit";
export const GITHUB_AUTH_PROVIDER_ID = "github";
import { hasGhecDrUri } from "../../config";
import { getOctokitBaseUrl } from "./octokit";
// We need 'repo' scope for triggering workflows, 'gist' scope for exporting results to Gist,
// and 'read:packages' for reading private CodeQL packages.
@@ -16,30 +16,24 @@ const SCOPES = ["repo", "gist", "read:packages"];
*/
export class VSCodeCredentials implements Credentials {
/**
* A specific octokit to return, otherwise a new authenticated octokit will be created when needed.
*/
private octokit: Octokit | undefined;
/**
* Creates or returns an instance of Octokit.
* Creates or returns an instance of Octokit. The returned instance should
* not be stored and reused, as it may become out-of-date with the current
* authentication session.
*
* @returns An instance of Octokit.
*/
async getOctokit(): Promise<Octokit> {
if (this.octokit) {
return this.octokit;
}
const accessToken = await this.getAccessToken();
return new AppOctokit({
auth: accessToken,
baseUrl: getOctokitBaseUrl(),
});
}
async getAccessToken(): Promise<string> {
const session = await authentication.getSession(
GITHUB_AUTH_PROVIDER_ID,
this.authProviderId,
SCOPES,
{ createIfNone: true },
);
@@ -49,11 +43,18 @@ export class VSCodeCredentials implements Credentials {
async getExistingAccessToken(): Promise<string | undefined> {
const session = await authentication.getSession(
GITHUB_AUTH_PROVIDER_ID,
this.authProviderId,
SCOPES,
{ createIfNone: false },
);
return session?.accessToken;
}
public get authProviderId(): string {
if (hasGhecDrUri()) {
return "github-enterprise";
}
return "github";
}
}

View File

@@ -0,0 +1,15 @@
import { getGitHubInstanceApiUrl } from "../../config";
/**
* Returns the Octokit base URL to use based on the GitHub instance URL.
*
* This is necessary because the Octokit base URL should not have a trailing
* slash, but this is included by default in a URL.
*/
export function getOctokitBaseUrl(): string {
let apiUrl = getGitHubInstanceApiUrl().toString();
if (apiUrl.endsWith("/")) {
apiUrl = apiUrl.slice(0, -1);
}
return apiUrl;
}

View File

@@ -33,6 +33,14 @@ export interface ProgressUpdate {
message: string;
}
export function progressUpdate(
step: number,
maxStep: number,
message: string,
): ProgressUpdate {
return { step, maxStep, message };
}
export type ProgressCallback = (p: ProgressUpdate) => void;
// Make certain properties within a type optional
@@ -48,7 +56,7 @@ type ProgressOptions = Optional<VSCodeProgressOptions, "location">;
* denote some progress being achieved on this task.
* @param token a cancellation token
*/
export type ProgressTask<R> = (
type ProgressTask<R> = (
progress: ProgressCallback,
token: CancellationToken,
) => Thenable<R>;

View File

@@ -4,7 +4,7 @@ import type {
ConfigurationScope,
Event,
} from "vscode";
import { ConfigurationTarget, EventEmitter, workspace } from "vscode";
import { ConfigurationTarget, EventEmitter, workspace, Uri } from "vscode";
import type { DistributionManager } from "./codeql-cli/distribution";
import { extLogger } from "./common/logging/vscode";
import { ONE_DAY_IN_MS } from "./common/time";
@@ -13,6 +13,8 @@ import {
FilterKey,
SortKey,
} from "./variant-analysis/shared/variant-analysis-filter-sort";
import { substituteConfigVariables } from "./common/config-template";
import { getErrorMessage } from "./common/helpers-pure";
export const ALL_SETTINGS: Setting[] = [];
@@ -68,6 +70,97 @@ export const VSCODE_SAVE_BEFORE_START_SETTING = new Setting(
VSCODE_DEBUG_SETTING,
);
const VSCODE_GITHUB_ENTERPRISE_SETTING = new Setting(
"github-enterprise",
undefined,
);
export const VSCODE_GITHUB_ENTERPRISE_URI_SETTING = new Setting(
"uri",
VSCODE_GITHUB_ENTERPRISE_SETTING,
);
/**
* Get the value of the `github-enterprise.uri` setting, parsed as a URI.
* If the value is not set or cannot be parsed, return `undefined`.
*/
export function getEnterpriseUri(): Uri | undefined {
const config = VSCODE_GITHUB_ENTERPRISE_URI_SETTING.getValue<string>();
if (config) {
try {
let uri = Uri.parse(config, true);
if (uri.scheme === "http") {
uri = uri.with({ scheme: "https" });
}
return uri;
} catch (e) {
void extLogger.log(
`Failed to parse the GitHub Enterprise URI: ${getErrorMessage(e)}`,
);
}
}
return undefined;
}
/**
* Is the GitHub Enterprise URI set?
*/
export function hasEnterpriseUri(): boolean {
return getEnterpriseUri() !== undefined;
}
/**
* Does the uri look like GHEC-DR?
*/
function isGhecDrUri(uri: Uri | undefined): boolean {
return (
uri !== undefined && !uri.authority.toLowerCase().endsWith("github.com")
);
}
/**
* Is the GitHub Enterprise URI set to something that looks like GHEC-DR?
*/
export function hasGhecDrUri(): boolean {
const uri = getEnterpriseUri();
return isGhecDrUri(uri);
}
/**
* The URI for GitHub.com.
*/
export const GITHUB_URL = new URL("https://github.com");
export const GITHUB_API_URL = new URL("https://api.github.com");
/**
* If the GitHub Enterprise URI is set to something that looks like GHEC-DR, return it.
*/
export function getGhecDrUri(): Uri | undefined {
const uri = getEnterpriseUri();
if (isGhecDrUri(uri)) {
return uri;
} else {
return undefined;
}
}
export function getGitHubInstanceUrl(): URL {
const ghecDrUri = getGhecDrUri();
if (ghecDrUri) {
return new URL(ghecDrUri.toString());
}
return GITHUB_URL;
}
export function getGitHubInstanceApiUrl(): URL {
const ghecDrUri = getGhecDrUri();
if (ghecDrUri) {
const url = new URL(ghecDrUri.toString());
url.hostname = `api.${url.hostname}`;
return url;
}
return GITHUB_API_URL;
}
const ROOT_SETTING = new Setting("codeQL");
// Telemetry configuration
@@ -500,27 +593,13 @@ export const NO_CACHE_CONTEXTUAL_QUERIES = new Setting(
// Settings for variant analysis
const VARIANT_ANALYSIS_SETTING = new Setting("variantAnalysis", ROOT_SETTING);
/**
* The name of the "controller" repository that you want to use with the "Run Variant Analysis" command.
* Note: This command is only available for internal users.
*
* This setting should be a GitHub repository of the form `<owner>/<repo>`.
*/
const REMOTE_CONTROLLER_REPO = new Setting(
"controllerRepo",
VARIANT_ANALYSIS_SETTING,
);
export function getRemoteControllerRepo(): string | undefined {
return REMOTE_CONTROLLER_REPO.getValue<string>() || undefined;
}
export async function setRemoteControllerRepo(repo: string | undefined) {
await REMOTE_CONTROLLER_REPO.updateValue(repo, ConfigurationTarget.Global);
}
export interface VariantAnalysisConfig {
controllerRepo: string | undefined;
showSystemDefinedRepositoryLists: boolean;
/**
* This uses a URL instead of a URI because the URL class is available in
* unit tests and is fully browser-compatible.
*/
githubUrl: URL;
onDidChangeConfiguration?: Event<void>;
}
@@ -530,13 +609,17 @@ export class VariantAnalysisConfigListener
{
protected handleDidChangeConfiguration(e: ConfigurationChangeEvent): void {
this.handleDidChangeConfigurationForRelevantSettings(
[VARIANT_ANALYSIS_SETTING],
[VARIANT_ANALYSIS_SETTING, VSCODE_GITHUB_ENTERPRISE_URI_SETTING],
e,
);
}
public get controllerRepo(): string | undefined {
return getRemoteControllerRepo();
public get showSystemDefinedRepositoryLists(): boolean {
return !hasEnterpriseUri();
}
public get githubUrl(): URL {
return getGitHubInstanceUrl();
}
}
@@ -724,7 +807,6 @@ export async function setAutogenerateQlPacks(choice: AutogenerateQLPacks) {
const MODEL_SETTING = new Setting("model", ROOT_SETTING);
const FLOW_GENERATION = new Setting("flowGeneration", MODEL_SETTING);
const LLM_GENERATION = new Setting("llmGeneration", MODEL_SETTING);
const SHOW_TYPE_MODELS = new Setting("showTypeModels", MODEL_SETTING);
const LLM_GENERATION_BATCH_SIZE = new Setting(
"llmGenerationBatchSize",
MODEL_SETTING,
@@ -734,25 +816,34 @@ const LLM_GENERATION_DEV_ENDPOINT = new Setting(
MODEL_SETTING,
);
const MODEL_EVALUATION = new Setting("evaluation", MODEL_SETTING);
const EXTENSIONS_DIRECTORY = new Setting("extensionsDirectory", MODEL_SETTING);
const MODEL_PACK_LOCATION = new Setting("packLocation", MODEL_SETTING);
const MODEL_PACK_NAME = new Setting("packName", MODEL_SETTING);
const ENABLE_PYTHON = new Setting("enablePython", MODEL_SETTING);
const ENABLE_ACCESS_PATH_SUGGESTIONS = new Setting(
"enableAccessPathSuggestions",
MODEL_SETTING,
);
export type ModelConfigPackVariables = {
database: string;
owner: string;
name: string;
language: string;
};
export interface ModelConfig {
flowGeneration: boolean;
llmGeneration: boolean;
showTypeModels: boolean;
getExtensionsDirectory(languageId: string): string | undefined;
getPackLocation(
languageId: string,
variables: ModelConfigPackVariables,
): string;
getPackName(languageId: string, variables: ModelConfigPackVariables): string;
enablePython: boolean;
enableAccessPathSuggestions: boolean;
}
export class ModelConfigListener extends ConfigListener implements ModelConfig {
protected handleDidChangeConfiguration(e: ConfigurationChangeEvent): void {
this.handleDidChangeConfigurationForRelevantSettings([MODEL_SETTING], e);
this.handleDidChangeConfigurationForRelevantSettings(
[MODEL_SETTING, VSCODE_GITHUB_ENTERPRISE_URI_SETTING],
e,
);
}
public get flowGeneration(): boolean {
@@ -760,11 +851,7 @@ export class ModelConfigListener extends ConfigListener implements ModelConfig {
}
public get llmGeneration(): boolean {
return !!LLM_GENERATION.getValue<boolean>();
}
public get showTypeModels(): boolean {
return !!SHOW_TYPE_MODELS.getValue<boolean>();
return !!LLM_GENERATION.getValue<boolean>() && !hasEnterpriseUri();
}
/**
@@ -787,19 +874,33 @@ export class ModelConfigListener extends ConfigListener implements ModelConfig {
return !!MODEL_EVALUATION.getValue<boolean>();
}
public getExtensionsDirectory(languageId: string): string | undefined {
return EXTENSIONS_DIRECTORY.getValue<string>({
languageId,
});
public getPackLocation(
languageId: string,
variables: ModelConfigPackVariables,
): string {
return substituteConfigVariables(
MODEL_PACK_LOCATION.getValue<string>({
languageId,
}),
variables,
);
}
public getPackName(
languageId: string,
variables: ModelConfigPackVariables,
): string {
return substituteConfigVariables(
MODEL_PACK_NAME.getValue<string>({
languageId,
}),
variables,
);
}
public get enablePython(): boolean {
return !!ENABLE_PYTHON.getValue<boolean>();
}
public get enableAccessPathSuggestions(): boolean {
return !!ENABLE_ACCESS_PATH_SUGGESTIONS.getValue<boolean>();
}
}
const GITHUB_DATABASE_SETTING = new Setting("githubDatabase", ROOT_SETTING);

View File

@@ -7,6 +7,7 @@ import { AppOctokit } from "../common/octokit";
import type { ProgressCallback } from "../common/vscode/progress";
import { UserCancellationException } from "../common/vscode/progress";
import type { EndpointDefaults } from "@octokit/types";
import { getOctokitBaseUrl } from "../common/vscode/octokit";
export async function getCodeSearchRepositories(
query: string,
@@ -54,6 +55,7 @@ async function provideOctokitWithThrottling(
const octokit = new MyOctokit({
auth,
baseUrl: getOctokitBaseUrl(),
throttle: {
onRateLimit: (retryAfter: number, options: EndpointDefaults): boolean => {
void logger.log(

File diff suppressed because it is too large Load Diff

View File

@@ -16,6 +16,7 @@ import {
} from "./db-item-selection";
import { createRemoteTree } from "./db-tree-creator";
import type { DbConfigValidationError } from "./db-validation-errors";
import type { VariantAnalysisConfig } from "../config";
export class DbManager extends DisposableObject {
public readonly onDbItemsChanged: AppEvent<void>;
@@ -25,6 +26,7 @@ export class DbManager extends DisposableObject {
constructor(
private readonly app: App,
private readonly dbConfigStore: DbConfigStore,
private readonly variantAnalysisConfigListener: VariantAnalysisConfig,
) {
super();
@@ -36,6 +38,10 @@ export class DbManager extends DisposableObject {
this.dbConfigStore.onDidChangeConfig(() => {
this.onDbItemsChangesEventEmitter.fire();
});
this.variantAnalysisConfigListener.onDidChangeConfiguration?.(() => {
this.onDbItemsChangesEventEmitter.fire();
});
}
public getSelectedDbItem(): DbItem | undefined {
@@ -56,7 +62,11 @@ export class DbManager extends DisposableObject {
const expandedItems = this.getExpandedItems();
const remoteTree = createRemoteTree(configResult.value, expandedItems);
const remoteTree = createRemoteTree(
configResult.value,
this.variantAnalysisConfigListener,
expandedItems,
);
return ValueResult.ok(remoteTree.children);
}

View File

@@ -7,6 +7,7 @@ import { DbManager } from "./db-manager";
import { DbPanel } from "./ui/db-panel";
import { DbSelectionDecorationProvider } from "./ui/db-selection-decoration-provider";
import type { DatabasePanelCommands } from "../common/commands";
import { VariantAnalysisConfigListener } from "../config";
export class DbModule extends DisposableObject {
public readonly dbManager: DbManager;
@@ -17,7 +18,13 @@ export class DbModule extends DisposableObject {
super();
this.dbConfigStore = new DbConfigStore(app);
this.dbManager = this.push(new DbManager(app, this.dbConfigStore));
this.dbManager = this.push(
new DbManager(
app,
this.dbConfigStore,
new VariantAnalysisConfigListener(),
),
);
}
public static async initialize(app: App): Promise<DbModule> {

View File

@@ -1,3 +1,4 @@
import type { VariantAnalysisConfig } from "../config";
import type { DbConfig, RemoteRepositoryList } from "./config/db-config";
import { SelectedDbItemKind } from "./config/db-config";
import type {
@@ -13,13 +14,17 @@ import { ExpandedDbItemKind } from "./db-item-expansion";
export function createRemoteTree(
dbConfig: DbConfig,
variantAnalysisConfig: VariantAnalysisConfig,
expandedItems: ExpandedDbItem[],
): RootRemoteDbItem {
const systemDefinedLists = [
createSystemDefinedList(10, dbConfig),
createSystemDefinedList(100, dbConfig),
createSystemDefinedList(1000, dbConfig),
];
const systemDefinedLists =
variantAnalysisConfig.showSystemDefinedRepositoryLists
? [
createSystemDefinedList(10, dbConfig),
createSystemDefinedList(100, dbConfig),
createSystemDefinedList(1000, dbConfig),
]
: [];
const userDefinedRepoLists =
dbConfig.databases.variantAnalysis.repositoryLists.map((r) =>

View File

@@ -3,6 +3,7 @@ import type { Octokit } from "@octokit/rest";
import type { RestEndpointMethodTypes } from "@octokit/plugin-rest-endpoint-methods";
import { showNeverAskAgainDialog } from "../../common/vscode/dialog";
import type { GitHubDatabaseConfig } from "../../config";
import { hasGhecDrUri } from "../../config";
import type { Credentials } from "../../common/authentication";
import { AppOctokit } from "../../common/octokit";
import type { ProgressCallback } from "../../common/vscode/progress";
@@ -67,7 +68,10 @@ export async function listDatabases(
credentials: Credentials,
config: GitHubDatabaseConfig,
): Promise<ListDatabasesResult | undefined> {
const hasAccessToken = !!(await credentials.getExistingAccessToken());
// On GHEC-DR, unauthenticated requests will never work, so we should always ask
// for authentication.
const hasAccessToken =
!!(await credentials.getExistingAccessToken()) || hasGhecDrUri();
let octokit = hasAccessToken
? await credentials.getOctokit()

View File

@@ -2,10 +2,8 @@ import { window } from "vscode";
import type { Octokit } from "@octokit/rest";
import { showNeverAskAgainDialog } from "../../common/vscode/dialog";
import { getLanguageDisplayName } from "../../common/query-language";
import { downloadGitHubDatabaseFromUrl } from "../database-fetcher";
import type { DatabaseFetcher } from "../database-fetcher";
import { withProgress } from "../../common/vscode/progress";
import type { DatabaseManager } from "../local-databases";
import type { CodeQLCliServer } from "../../codeql-cli/cli";
import type { AppCommandManager } from "../../common/commands";
import type { GitHubDatabaseConfig } from "../../config";
import type { CodeqlDatabase } from "./api";
@@ -58,9 +56,7 @@ export async function downloadDatabaseFromGitHub(
owner: string,
repo: string,
databases: CodeqlDatabase[],
databaseManager: DatabaseManager,
storagePath: string,
cliServer: CodeQLCliServer,
databaseFetcher: DatabaseFetcher,
commandManager: AppCommandManager,
): Promise<void> {
const selectedDatabases = await promptForDatabases(databases);
@@ -72,7 +68,7 @@ export async function downloadDatabaseFromGitHub(
selectedDatabases.map((database) =>
withProgress(
async (progress) => {
await downloadGitHubDatabaseFromUrl(
await databaseFetcher.downloadGitHubDatabaseFromUrl(
database.url,
database.id,
database.created_at,
@@ -81,9 +77,6 @@ export async function downloadDatabaseFromGitHub(
repo,
octokit,
progress,
databaseManager,
storagePath,
cliServer,
true,
false,
);

View File

@@ -14,7 +14,6 @@ import {
} from "./download";
import type { GitHubDatabaseConfig } from "../../config";
import type { DatabaseManager } from "../local-databases";
import type { CodeQLCliServer } from "../../codeql-cli/cli";
import type { CodeqlDatabase, ListDatabasesResult } from "./api";
import { listDatabases } from "./api";
import type { DatabaseUpdate } from "./updates";
@@ -24,6 +23,7 @@ import {
isNewerDatabaseAvailable,
} from "./updates";
import type { Octokit } from "@octokit/rest";
import type { DatabaseFetcher } from "../database-fetcher";
export class GitHubDatabasesModule extends DisposableObject {
/**
@@ -33,8 +33,7 @@ export class GitHubDatabasesModule extends DisposableObject {
constructor(
private readonly app: App,
private readonly databaseManager: DatabaseManager,
private readonly databaseStoragePath: string,
private readonly cliServer: CodeQLCliServer,
private readonly databaseFetcher: DatabaseFetcher,
private readonly config: GitHubDatabaseConfig,
) {
super();
@@ -43,15 +42,13 @@ export class GitHubDatabasesModule extends DisposableObject {
public static async initialize(
app: App,
databaseManager: DatabaseManager,
databaseStoragePath: string,
cliServer: CodeQLCliServer,
databaseFetcher: DatabaseFetcher,
config: GitHubDatabaseConfig,
): Promise<GitHubDatabasesModule> {
const githubDatabasesModule = new GitHubDatabasesModule(
app,
databaseManager,
databaseStoragePath,
cliServer,
databaseFetcher,
config,
);
app.subscriptions.push(githubDatabasesModule);
@@ -185,9 +182,7 @@ export class GitHubDatabasesModule extends DisposableObject {
owner,
repo,
databases,
this.databaseManager,
this.databaseStoragePath,
this.cliServer,
this.databaseFetcher,
this.app.commands,
);
}
@@ -212,8 +207,7 @@ export class GitHubDatabasesModule extends DisposableObject {
repo,
databaseUpdates,
this.databaseManager,
this.databaseStoragePath,
this.cliServer,
this.databaseFetcher,
this.app.commands,
);
}

View File

@@ -1,11 +1,10 @@
import type { CodeqlDatabase } from "./api";
import type { DatabaseItem, DatabaseManager } from "../local-databases";
import type { Octokit } from "@octokit/rest";
import type { CodeQLCliServer } from "../../codeql-cli/cli";
import type { AppCommandManager } from "../../common/commands";
import { getLanguageDisplayName } from "../../common/query-language";
import { showNeverAskAgainDialog } from "../../common/vscode/dialog";
import { downloadGitHubDatabaseFromUrl } from "../database-fetcher";
import type { DatabaseFetcher } from "../database-fetcher";
import { withProgress } from "../../common/vscode/progress";
import { window } from "vscode";
import type { GitHubDatabaseConfig } from "../../config";
@@ -156,8 +155,7 @@ export async function downloadDatabaseUpdateFromGitHub(
repo: string,
updates: DatabaseUpdate[],
databaseManager: DatabaseManager,
storagePath: string,
cliServer: CodeQLCliServer,
databaseFetcher: DatabaseFetcher,
commandManager: AppCommandManager,
): Promise<void> {
const selectedDatabases = await promptForDatabases(
@@ -179,21 +177,19 @@ export async function downloadDatabaseUpdateFromGitHub(
return withProgress(
async (progress) => {
const newDatabase = await downloadGitHubDatabaseFromUrl(
database.url,
database.id,
database.created_at,
database.commit_oid ?? null,
owner,
repo,
octokit,
progress,
databaseManager,
storagePath,
cliServer,
databaseManager.currentDatabaseItem === update.databaseItem,
update.databaseItem.hasSourceArchiveInExplorer(),
);
const newDatabase =
await databaseFetcher.downloadGitHubDatabaseFromUrl(
database.url,
database.id,
database.created_at,
database.commit_oid ?? null,
owner,
repo,
octokit,
progress,
databaseManager.currentDatabaseItem === update.databaseItem,
update.databaseItem.hasSourceArchiveInExplorer(),
);
if (newDatabase === undefined) {
return;
}

View File

@@ -37,11 +37,7 @@ import {
showAndLogExceptionWithTelemetry,
showAndLogErrorMessage,
} from "../common/logging";
import {
importLocalDatabase,
promptImportGithubDatabase,
promptImportInternetDatabase,
} from "./database-fetcher";
import type { DatabaseFetcher } from "./database-fetcher";
import { asError, asyncFilter, getErrorMessage } from "../common/helpers-pure";
import type { QueryRunner } from "../query-server";
import type { App } from "../common/app";
@@ -113,9 +109,8 @@ class DatabaseTreeDataProvider
// Note that events from the database manager are instances of DatabaseChangedEvent
// and events fired by the UI are instances of DatabaseItem
// When event.item is undefined, then the entire tree is refreshed.
// When event.item is a db item, then only that item is refreshed.
this._onDidChangeTreeData.fire(event.item);
// When a full refresh has occurred, then all items are refreshed by passing undefined.
this._onDidChangeTreeData.fire(event.fullRefresh ? undefined : event.item);
}
private handleDidChangeCurrentDatabaseItem(
@@ -248,6 +243,7 @@ export class DatabaseUI extends DisposableObject {
public constructor(
private app: App,
private databaseManager: DatabaseManager,
private readonly databaseFetcher: DatabaseFetcher,
languageContext: LanguageContextStore,
private readonly queryServer: QueryRunner,
private readonly storagePath: string,
@@ -535,13 +531,7 @@ export class DatabaseUI extends DisposableObject {
private async handleChooseDatabaseInternet(): Promise<void> {
return withProgress(
async (progress) => {
await promptImportInternetDatabase(
this.app.commands,
this.databaseManager,
this.storagePath,
progress,
this.queryServer.cliServer,
);
await this.databaseFetcher.promptImportInternetDatabase(progress);
},
{
title: "Adding database from URL",
@@ -552,13 +542,7 @@ export class DatabaseUI extends DisposableObject {
private async handleChooseDatabaseGithub(): Promise<void> {
return withProgress(
async (progress) => {
await promptImportGithubDatabase(
this.app,
this.databaseManager,
this.storagePath,
progress,
this.queryServer.cliServer,
);
await this.databaseFetcher.promptImportGithubDatabase(progress);
},
{
title: "Adding database from GitHub",
@@ -660,14 +644,13 @@ export class DatabaseUI extends DisposableObject {
private async handleClearCache(): Promise<void> {
return withProgress(
async (_progress, token) => {
async () => {
if (
this.queryServer !== undefined &&
this.databaseManager.currentDatabaseItem !== undefined
) {
await this.queryServer.clearCacheInDatabase(
this.databaseManager.currentDatabaseItem,
token,
);
}
},
@@ -679,14 +662,13 @@ export class DatabaseUI extends DisposableObject {
private async handleTrimCache(): Promise<void> {
return withProgress(
async (_progress, token) => {
async () => {
if (
this.queryServer !== undefined &&
this.databaseManager.currentDatabaseItem !== undefined
) {
await this.queryServer.trimCacheInDatabase(
this.databaseManager.currentDatabaseItem,
token,
);
}
},
@@ -707,13 +689,9 @@ export class DatabaseUI extends DisposableObject {
try {
// Assume user has selected an archive if the file has a .zip extension
if (uri.path.endsWith(".zip")) {
await importLocalDatabase(
this.app.commands,
await this.databaseFetcher.importLocalDatabase(
uri.toString(true),
this.databaseManager,
this.storagePath,
progress,
this.queryServer.cliServer,
);
} else {
await this.databaseManager.openDatabase(uri, {
@@ -758,13 +736,9 @@ export class DatabaseUI extends DisposableObject {
await this.databaseManager.removeDatabaseItem(existingItem);
}
await importLocalDatabase(
this.app.commands,
await this.databaseFetcher.importLocalDatabase(
uri.toString(true),
this.databaseManager,
this.storagePath,
progress,
this.queryServer.cliServer,
);
if (existingItem !== undefined) {
@@ -1005,13 +979,9 @@ export class DatabaseUI extends DisposableObject {
// we are selecting a database archive or a testproj.
// Unzip archives (if an archive) and copy into a workspace-controlled area
// before importing.
return await importLocalDatabase(
this.app.commands,
return await this.databaseFetcher.importLocalDatabase(
uri.toString(true),
this.databaseManager,
this.storagePath,
progress,
this.queryServer.cliServer,
);
}
}

View File

@@ -1,4 +1,7 @@
import { pathExists, remove } from "fs-extra";
import { join } from "path";
import type { Uri } from "vscode";
import { zip } from "zip-a-folder";
/**
* The layout of the database.
@@ -28,3 +31,26 @@ export interface DatabaseContents {
export interface DatabaseContentsWithDbScheme extends DatabaseContents {
dbSchemeUri: Uri; // Always present
}
/**
* Databases created by the old odasa tool will not have a zipped
* source location. However, this extension works better if sources
* are zipped.
*
* This function ensures that the source location is zipped. If the
* `src` folder exists and the `src.zip` file does not, the `src`
* folder will be zipped and then deleted.
*
* @param databasePath The full path to the unzipped database
*/
export async function ensureZippedSourceLocation(
databasePath: string,
): Promise<void> {
const srcFolderPath = join(databasePath, "src");
const srcZipPath = `${srcFolderPath}.zip`;
if ((await pathExists(srcFolderPath)) && !(await pathExists(srcZipPath))) {
await zip(srcFolderPath, srcZipPath);
await remove(srcFolderPath);
}
}

View File

@@ -16,4 +16,8 @@ export enum DatabaseEventKind {
export interface DatabaseChangedEvent {
kind: DatabaseEventKind;
item: DatabaseItem | undefined;
// If true, event handlers should consider the database manager
// to have been fully refreshed. Any state managed by the
// event handler should be fully refreshed as well.
fullRefresh: boolean;
}

View File

@@ -43,7 +43,7 @@ import { DatabaseResolver } from "./database-resolver";
import { telemetryListener } from "../../common/vscode/telemetry";
import type { LanguageContextStore } from "../../language-context-store";
import type { DatabaseOrigin } from "./database-origin";
import { ensureZippedSourceLocation } from "../database-fetcher";
import { ensureZippedSourceLocation } from "./database-contents";
/**
* The name of the key in the workspaceState dictionary in which we
@@ -613,6 +613,7 @@ export class DatabaseManager extends DisposableObject {
this._onDidChangeCurrentDatabaseItem.fire({
item,
kind: DatabaseEventKind.Change,
fullRefresh: false,
});
}
}
@@ -662,8 +663,9 @@ export class DatabaseManager extends DisposableObject {
}
// note that we use undefined as the item in order to reset the entire tree
this._onDidChangeDatabaseItem.fire({
item: undefined,
item,
kind: DatabaseEventKind.Add,
fullRefresh: true,
});
}
@@ -671,9 +673,9 @@ export class DatabaseManager extends DisposableObject {
item.name = newName;
await this.updatePersistedDatabaseList();
this._onDidChangeDatabaseItem.fire({
// pass undefined so that the entire tree is rebuilt in order to re-sort
item: undefined,
item,
kind: DatabaseEventKind.Rename,
fullRefresh: true,
});
}
@@ -720,10 +722,10 @@ export class DatabaseManager extends DisposableObject {
);
}
// note that we use undefined as the item in order to reset the entire tree
this._onDidChangeDatabaseItem.fire({
item: undefined,
item,
kind: DatabaseEventKind.Remove,
fullRefresh: true,
});
}
@@ -776,6 +778,7 @@ export class DatabaseManager extends DisposableObject {
this._onDidChangeDatabaseItem.fire({
kind: DatabaseEventKind.Refresh,
item: databaseItem,
fullRefresh: false,
});
}
}

View File

@@ -18,13 +18,12 @@ import type { DbManager } from "../db-manager";
import { DbTreeDataProvider } from "./db-tree-data-provider";
import type { DbTreeViewItem } from "./db-tree-view-item";
import { getGitHubUrl } from "./db-tree-view-item-action";
import { getControllerRepo } from "../../variant-analysis/run-remote-query";
import { getErrorMessage } from "../../common/helpers-pure";
import type { DatabasePanelCommands } from "../../common/commands";
import type { App } from "../../common/app";
import { QueryLanguage } from "../../common/query-language";
import { getCodeSearchRepositories } from "../code-search-api";
import { showAndLogErrorMessage } from "../../common/logging";
import { getGitHubInstanceUrl } from "../../config";
export interface RemoteDatabaseQuickPickItem extends QuickPickItem {
remoteDatabaseKind: string;
@@ -73,9 +72,6 @@ export class DbPanel extends DisposableObject {
this.addNewRemoteDatabase.bind(this),
"codeQLVariantAnalysisRepositories.addNewList":
this.addNewList.bind(this),
"codeQLVariantAnalysisRepositories.setupControllerRepository":
this.setupControllerRepository.bind(this),
"codeQLVariantAnalysisRepositories.setSelectedItem":
this.setSelectedItem.bind(this),
"codeQLVariantAnalysisRepositories.setSelectedItemContextMenu":
@@ -146,16 +142,19 @@ export class DbPanel extends DisposableObject {
}
private async addNewRemoteRepo(parentList?: string): Promise<void> {
const instanceUrl = getGitHubInstanceUrl();
const repoName = await window.showInputBox({
title: "Add a repository",
prompt: "Insert a GitHub repository URL or name with owner",
placeHolder: "<owner>/<repo> or https://github.com/<owner>/<repo>",
placeHolder: `<owner>/<repo> or ${new URL("/", instanceUrl).toString()}<owner>/<repo>`,
});
if (!repoName) {
return;
}
const nwo = getNwoFromGitHubUrl(repoName) || repoName;
const nwo =
getNwoFromGitHubUrl(repoName, getGitHubInstanceUrl()) || repoName;
if (!isValidGitHubNwo(nwo)) {
void showAndLogErrorMessage(
this.app.logger,
@@ -176,17 +175,20 @@ export class DbPanel extends DisposableObject {
}
private async addNewRemoteOwner(): Promise<void> {
const instanceUrl = getGitHubInstanceUrl();
const ownerName = await window.showInputBox({
title: "Add all repositories of a GitHub org or owner",
prompt: "Insert a GitHub organization or owner name",
placeHolder: "<owner> or https://github.com/<owner>",
placeHolder: `<owner> or ${new URL("/", instanceUrl).toString()}<owner>`,
});
if (!ownerName) {
return;
}
const owner = getOwnerFromGitHubUrl(ownerName) || ownerName;
const owner =
getOwnerFromGitHubUrl(ownerName, getGitHubInstanceUrl()) || ownerName;
if (!isValidGitHubOwner(owner)) {
void showAndLogErrorMessage(
this.app.logger,
@@ -411,7 +413,7 @@ export class DbPanel extends DisposableObject {
if (treeViewItem.dbItem === undefined) {
throw new Error("Unable to open on GitHub. Please select a valid item.");
}
const githubUrl = getGitHubUrl(treeViewItem.dbItem);
const githubUrl = getGitHubUrl(treeViewItem.dbItem, getGitHubInstanceUrl());
if (!githubUrl) {
throw new Error(
"Unable to open on GitHub. Please select a variant analysis repository or owner.",
@@ -420,22 +422,4 @@ export class DbPanel extends DisposableObject {
await this.app.commands.execute("vscode.open", Uri.parse(githubUrl));
}
private async setupControllerRepository(): Promise<void> {
try {
// This will also validate that the controller repository is valid
await getControllerRepo(this.app.credentials);
} catch (e: unknown) {
if (e instanceof UserCancellationException) {
return;
}
void showAndLogErrorMessage(
this.app.logger,
`An error occurred while setting up the controller repository: ${getErrorMessage(
e,
)}`,
);
}
}
}

View File

@@ -83,11 +83,6 @@ export class DbTreeDataProvider
}
private createTree(): DbTreeViewItem[] {
// Returning an empty tree here will show the welcome view
if (!this.variantAnalysisConfig.controllerRepo) {
return [];
}
const dbItemsResult = this.dbManager.getDbItems();
if (dbItemsResult.isFailure) {

View File

@@ -62,12 +62,15 @@ function canImportCodeSearch(dbItem: DbItem): boolean {
return DbItemKind.RemoteUserDefinedList === dbItem.kind;
}
export function getGitHubUrl(dbItem: DbItem): string | undefined {
export function getGitHubUrl(
dbItem: DbItem,
githubUrl: URL,
): string | undefined {
switch (dbItem.kind) {
case DbItemKind.RemoteOwner:
return `https://github.com/${dbItem.ownerName}`;
return new URL(`/${dbItem.ownerName}`, githubUrl).toString();
case DbItemKind.RemoteRepo:
return `https://github.com/${dbItem.repoFullName}`;
return new URL(`/${dbItem.repoFullName}`, githubUrl).toString();
default:
return undefined;
}

View File

@@ -135,7 +135,7 @@ class QLDebugAdapterTracker
): Promise<void> {
if (this.localQueryRun !== undefined) {
const results: CoreQueryResults = body;
await this.localQueryRun.complete(results);
await this.localQueryRun.complete(results, (_) => {});
this.localQueryRun = undefined;
}
}

View File

@@ -31,6 +31,7 @@ import {
joinOrderWarningThreshold,
QueryHistoryConfigListener,
QueryServerConfigListener,
VariantAnalysisConfigListener,
} from "./config";
import {
AstViewer,
@@ -109,7 +110,7 @@ import { VariantAnalysisManager } from "./variant-analysis/variant-analysis-mana
import { createVariantAnalysisContentProvider } from "./variant-analysis/variant-analysis-content-provider";
import { VSCodeMockGitHubApiServer } from "./common/mock-gh-api/vscode/vscode-mock-gh-api-server";
import { VariantAnalysisResultsManager } from "./variant-analysis/variant-analysis-results-manager";
import { ExtensionApp } from "./common/vscode/vscode-app";
import { ExtensionApp } from "./common/vscode/extension-app";
import { DbModule } from "./databases/db-module";
import { redactableError } from "./common/errors";
import { QLDebugAdapterDescriptorFactory } from "./debugger/debugger-factory";
@@ -133,6 +134,7 @@ import { OpenReferencedFileCodeLensProvider } from "./local-queries/open-referen
import { LanguageContextStore } from "./language-context-store";
import { LanguageSelectionPanel } from "./language-selection-panel/language-selection-panel";
import { GitHubDatabasesModule } from "./databases/github-databases";
import { DatabaseFetcher } from "./databases/database-fetcher";
/**
* extension.ts
@@ -183,11 +185,11 @@ function getCommands(
const restartQueryServer = async () =>
withProgress(
async (progress: ProgressCallback, token: CancellationToken) => {
async (progress: ProgressCallback) => {
// Restart all of the spawned servers: cli, query, and language.
cliServer.restartCliServer();
await Promise.all([
queryRunner.restartQueryServer(progress, token),
queryRunner.restartQueryServer(progress),
async () => {
if (languageClient.isRunning()) {
await languageClient.restart();
@@ -445,8 +447,9 @@ export async function activate(
}
if (
CliVersionConstraint.OLDEST_SUPPORTED_CLI_VERSION.compare(ver.version) <
0
CliVersionConstraint.OLDEST_SUPPORTED_CLI_VERSION.compare(
ver.version,
) <= 0
) {
return;
}
@@ -714,12 +717,13 @@ async function installOrUpdateThenTryActivate(
return undefined;
}
const PACK_GLOBS = [
const CLEAR_PACK_CACHE_ON_EDIT_GLOBS = [
"**/codeql-pack.yml",
"**/qlpack.yml",
"**/queries.xml",
"**/codeql-pack.lock.yml",
"**/qlpack.lock.yml",
"**/*.dbscheme",
".codeqlmanifest.json",
"codeql-workspace.yml",
];
@@ -766,7 +770,7 @@ async function activateWithInstalledDistribution(
ctx,
);
for (const glob of PACK_GLOBS) {
for (const glob of CLEAR_PACK_CACHE_ON_EDIT_GLOBS) {
const fsWatcher = workspace.createFileSystemWatcher(glob);
ctx.subscriptions.push(fsWatcher);
@@ -799,12 +803,20 @@ async function activateWithInstalledDistribution(
// Let this run async.
void dbm.loadPersistedState();
const databaseFetcher = new DatabaseFetcher(
app,
dbm,
getContextStoragePath(ctx),
cliServer,
);
ctx.subscriptions.push(dbm);
void extLogger.log("Initializing database panel.");
const databaseUI = new DatabaseUI(
app,
dbm,
databaseFetcher,
languageContext,
qs,
getContextStoragePath(ctx),
@@ -855,8 +867,10 @@ async function activateWithInstalledDistribution(
"variant-analyses",
);
await ensureDir(variantAnalysisStorageDir);
const variantAnalysisConfig = new VariantAnalysisConfigListener();
const variantAnalysisResultsManager = new VariantAnalysisResultsManager(
cliServer,
variantAnalysisConfig,
extLogger,
);
@@ -866,6 +880,7 @@ async function activateWithInstalledDistribution(
variantAnalysisStorageDir,
variantAnalysisResultsManager,
dbModule.dbManager,
variantAnalysisConfig,
);
ctx.subscriptions.push(variantAnalysisManager);
ctx.subscriptions.push(variantAnalysisResultsManager);
@@ -881,8 +896,7 @@ async function activateWithInstalledDistribution(
await GitHubDatabasesModule.initialize(
app,
dbm,
getContextStoragePath(ctx),
cliServer,
databaseFetcher,
githubDatabaseConfigListener,
);
@@ -934,7 +948,7 @@ async function activateWithInstalledDistribution(
ctx.subscriptions.push(compareView);
void extLogger.log("Initializing source archive filesystem provider.");
archiveFilesystemProvider_activate(ctx);
archiveFilesystemProvider_activate(ctx, dbm);
const qhelpTmpDir = dirSync({
prefix: "qhelp_",
@@ -953,6 +967,7 @@ async function activateWithInstalledDistribution(
qs,
qhm,
dbm,
databaseFetcher,
cliServer,
databaseUI,
localQueryResultsView,
@@ -977,6 +992,7 @@ async function activateWithInstalledDistribution(
const modelEditorModule = await ModelEditorModule.initialize(
app,
dbm,
databaseFetcher,
variantAnalysisManager,
cliServer,
qs,
@@ -1068,14 +1084,12 @@ async function activateWithInstalledDistribution(
});
// Handle visibility changes in the CodeQL language client.
if (await cliServer.cliConstraints.supportsVisibilityNotifications()) {
Window.onDidChangeVisibleTextEditors((editors) => {
languageClient.notifyVisibilityChange(editors);
});
// Send an inital notification to the language server
// to set the initial state of the visible editors.
languageClient.notifyVisibilityChange(Window.visibleTextEditors);
}
Window.onDidChangeVisibleTextEditors((editors) => {
languageClient.notifyVisibilityChange(editors);
});
// Send an inital notification to the language server
// to set the initial state of the visible editors.
languageClient.notifyVisibilityChange(Window.visibleTextEditors);
// Jump-to-definition and find-references
void extLogger.log("Registering jump-to-definition handlers.");

View File

@@ -92,11 +92,12 @@ export async function runContextualQuery(
void extLogger.log(
`Running contextual query ${query}; results will be stored in ${queryRun.outputDir.querySaveDir}`,
);
const results = await queryRun.evaluate(
progress,
token,
new TeeLogger(qs.logger, queryRun.outputDir.logPath),
);
await cleanup?.();
return results;
const teeLogger = new TeeLogger(qs.logger, queryRun.outputDir.logPath);
try {
return await queryRun.evaluate(progress, token, teeLogger);
} finally {
await cleanup?.();
teeLogger.dispose();
}
}

View File

@@ -53,7 +53,8 @@ import { findLanguage } from "../codeql-cli/query-language";
import type { QueryTreeViewItem } from "../queries-panel/query-tree-view-item";
import { tryGetQueryLanguage } from "../common/query-language";
import type { LanguageContextStore } from "../language-context-store";
import type { ExtensionApp } from "../common/vscode/vscode-app";
import type { ExtensionApp } from "../common/vscode/extension-app";
import type { DatabaseFetcher } from "../databases/database-fetcher";
export enum QuickEvalType {
None,
@@ -69,6 +70,7 @@ export class LocalQueries extends DisposableObject {
private readonly queryRunner: QueryRunner,
private readonly queryHistoryManager: QueryHistoryManager,
private readonly databaseManager: DatabaseManager,
private readonly databaseFetcher: DatabaseFetcher,
private readonly cliServer: CodeQLCliServer,
private readonly databaseUI: DatabaseUI,
private readonly localQueryResultsView: ResultsView,
@@ -319,15 +321,13 @@ export class LocalQueries extends DisposableObject {
private async createSkeletonQuery(): Promise<void> {
await withProgress(
async (progress: ProgressCallback) => {
const contextStoragePath =
this.app.workspaceStoragePath || this.app.globalStoragePath;
const language = this.languageContextStore.selectedLanguage;
const skeletonQueryWizard = new SkeletonQueryWizard(
this.cliServer,
progress,
this.app,
this.databaseManager,
contextStoragePath,
this.databaseFetcher,
this.selectedQueryTreeViewItems,
language,
);
@@ -485,7 +485,7 @@ export class LocalQueries extends DisposableObject {
localQueryRun.logger,
);
await localQueryRun.complete(results);
await localQueryRun.complete(results, progress);
return results;
} catch (e) {

View File

@@ -25,6 +25,9 @@ import { redactableError } from "../common/errors";
import type { LocalQueries } from "./local-queries";
import { tryGetQueryMetadata } from "../codeql-cli/query-metadata";
import { telemetryListener } from "../common/vscode/telemetry";
import type { Disposable } from "../common/disposable-object";
import type { ProgressCallback } from "../common/vscode/progress";
import { progressUpdate } from "../common/vscode/progress";
function formatResultMessage(result: CoreQueryResults): string {
switch (result.resultType) {
@@ -61,7 +64,11 @@ export class LocalQueryRun {
private readonly localQueries: LocalQueries,
private readonly queryInfo: LocalQueryInfo,
private readonly dbItem: DatabaseItem,
public readonly logger: Logger, // Public so that other clients, like the debug adapter, know where to send log output
/**
* The logger is only available while the query is running and will be disposed of when the
* query completes.
*/
public readonly logger: Logger & Disposable, // Public so that other clients, like the debug adapter, know where to send log output
private readonly queryHistoryManager: QueryHistoryManager,
private readonly cliServer: CodeQLCliServer,
) {}
@@ -74,24 +81,34 @@ export class LocalQueryRun {
* This function must be called when the evaluation completes, whether the evaluation was
* successful or not.
* */
public async complete(results: CoreQueryResults): Promise<void> {
public async complete(
results: CoreQueryResults,
progress: ProgressCallback,
): Promise<void> {
const evalLogPaths = await this.summarizeEvalLog(
results.resultType,
this.outputDir,
this.logger,
progress,
);
if (evalLogPaths !== undefined) {
this.queryInfo.setEvaluatorLogPaths(evalLogPaths);
}
progress(progressUpdate(1, 4, "Getting completed query info"));
const queryWithResults = await this.getCompletedQueryInfo(results);
progress(progressUpdate(2, 4, "Updating query history"));
this.queryHistoryManager.completeQuery(this.queryInfo, queryWithResults);
progress(progressUpdate(3, 4, "Showing results"));
await this.localQueries.showResultsForCompletedQuery(
this.queryInfo as CompletedLocalQueryInfo,
WebviewReveal.Forced,
);
// Note we must update the query history view after showing results as the
// display and sorting might depend on the number of results
progress(progressUpdate(4, 4, "Updating query history"));
await this.queryHistoryManager.refreshTreeView();
this.logger.dispose();
}
/**
@@ -102,6 +119,7 @@ export class LocalQueryRun {
QueryResultType.OTHER_ERROR,
this.outputDir,
this.logger,
(_) => {},
);
if (evalLogPaths !== undefined) {
this.queryInfo.setEvaluatorLogPaths(evalLogPaths);
@@ -110,6 +128,8 @@ export class LocalQueryRun {
err.message = `Error running query: ${err.message}`;
this.queryInfo.failureReason = err.message;
await this.queryHistoryManager.refreshTreeView();
this.logger.dispose();
}
/**
@@ -119,10 +139,12 @@ export class LocalQueryRun {
resultType: QueryResultType,
outputDir: QueryOutputDir,
logger: BaseLogger,
progress: ProgressCallback,
): Promise<EvaluatorLogPaths | undefined> {
const evalLogPaths = await generateEvalLogSummaries(
this.cliServer,
outputDir,
progress,
);
if (evalLogPaths !== undefined) {
if (evalLogPaths.endSummary !== undefined) {

View File

@@ -12,7 +12,7 @@ import { UserCancellationException } from "../common/vscode/progress";
import { getErrorMessage } from "../common/helpers-pure";
import { FALLBACK_QLPACK_FILENAME, getQlPackFilePath } from "../common/ql";
import type { App } from "../common/app";
import type { ExtensionApp } from "../common/vscode/vscode-app";
import type { ExtensionApp } from "../common/vscode/extension-app";
import type { QlPackFile } from "../packaging/qlpack-file";
const QUICK_QUERIES_DIR_NAME = "quick-queries";

View File

@@ -47,21 +47,27 @@ export async function runQuery({
undefined,
);
const completedQuery = await queryRun.evaluate(
progress,
token,
new TeeLogger(queryRunner.logger, queryRun.outputDir.logPath),
const teeLogger = new TeeLogger(
queryRunner.logger,
queryRun.outputDir.logPath,
);
if (completedQuery.resultType !== QueryResultType.SUCCESS) {
void showAndLogExceptionWithTelemetry(
extLogger,
telemetryListener,
redactableError`Failed to run ${basename(queryPath)} query: ${
completedQuery.message ?? "No message"
}`,
);
return;
try {
const completedQuery = await queryRun.evaluate(progress, token, teeLogger);
if (completedQuery.resultType !== QueryResultType.SUCCESS) {
void showAndLogExceptionWithTelemetry(
extLogger,
telemetryListener,
redactableError`Failed to run ${basename(queryPath)} query: ${
completedQuery.message ?? "No message"
}`,
);
return;
}
return completedQuery;
} finally {
teeLogger.dispose();
}
return completedQuery;
}

View File

@@ -19,10 +19,7 @@ import {
UserCancellationException,
withProgress,
} from "../common/vscode/progress";
import {
askForGitHubRepo,
downloadGitHubDatabase,
} from "../databases/database-fetcher";
import type { DatabaseFetcher } from "../databases/database-fetcher";
import {
getQlPackLocation,
isCodespacesTemplate,
@@ -62,7 +59,7 @@ export class SkeletonQueryWizard {
private readonly progress: ProgressCallback,
private readonly app: App,
private readonly databaseManager: DatabaseManager,
private readonly databaseStoragePath: string | undefined,
private readonly databaseFetcher: DatabaseFetcher,
private readonly selectedItems: readonly QueryTreeViewItem[],
private language: QueryLanguage | undefined = undefined,
) {}
@@ -363,10 +360,6 @@ export class SkeletonQueryWizard {
}
private async downloadDatabase(progress: ProgressCallback) {
if (this.databaseStoragePath === undefined) {
throw new Error("Database storage path is undefined");
}
if (this.language === undefined) {
throw new Error("Language is undefined");
}
@@ -378,20 +371,10 @@ export class SkeletonQueryWizard {
});
const githubRepoNwo = QUERY_LANGUAGE_TO_DATABASE_REPO[this.language];
const chosenRepo = await askForGitHubRepo(undefined, githubRepoNwo);
if (!chosenRepo) {
throw new UserCancellationException("No GitHub repository provided");
}
await downloadGitHubDatabase(
chosenRepo,
this.app,
this.databaseManager,
this.databaseStoragePath,
await this.databaseFetcher.promptImportGithubDatabase(
progress,
this.cliServer,
this.language,
githubRepoNwo,
);
}

View File

@@ -67,6 +67,9 @@
"$ref": "#/definitions/SuiteInstruction"
}
},
{
"$ref": "#/definitions/SuiteInstruction"
},
{
"type": "null"
}
@@ -93,19 +96,33 @@
"include": {
"type": "object",
"additionalProperties": {
"type": "array",
"items": {
"type": "string"
}
"anyOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
}
},
"exclude": {
"type": "object",
"additionalProperties": {
"type": "array",
"items": {
"type": "string"
}
"anyOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
}
},
"description": {

View File

@@ -15,11 +15,19 @@ export function formatPackName(packName: ExtensionPackName): string {
return `${packName.scope}/${packName.name}`;
}
export function autoNameExtensionPack(
name: string,
language: string,
): ExtensionPackName | undefined {
let packName = `${name}-${language}`;
export function sanitizePackName(userPackName: string): ExtensionPackName {
let packName = userPackName;
packName = packName.trim();
while (packName.startsWith("/")) {
packName = packName.slice(1);
}
while (packName.endsWith("/")) {
packName = packName.slice(0, -1);
}
if (!packName.includes("/")) {
packName = `pack/${packName}`;
}

View File

@@ -2,7 +2,6 @@ import { join } from "path";
import { outputFile, pathExists, readFile } from "fs-extra";
import { dump as dumpYaml, load as loadYaml } from "js-yaml";
import type { CancellationToken } from "vscode";
import { Uri } from "vscode";
import Ajv from "ajv";
import type { CodeQLCliServer } from "../codeql-cli/cli";
import { getOnDiskWorkspaceFolders } from "../common/vscode/workspace-folders";
@@ -14,10 +13,17 @@ import { getErrorMessage } from "../common/helpers-pure";
import type { ExtensionPack } from "./shared/extension-pack";
import type { NotificationLogger } from "../common/logging";
import { showAndLogErrorMessage } from "../common/logging";
import type { ModelConfig } from "../config";
import type { ModelConfig, ModelConfigPackVariables } from "../config";
import type { ExtensionPackName } from "./extension-pack-name";
import { autoNameExtensionPack, formatPackName } from "./extension-pack-name";
import { autoPickExtensionsDirectory } from "./extensions-workspace-folder";
import {
validatePackName,
sanitizePackName,
formatPackName,
} from "./extension-pack-name";
import {
ensurePackLocationIsInWorkspaceFolder,
packLocationToAbsolute,
} from "./extensions-workspace-folder";
import type { ExtensionPackMetadata } from "./extension-pack-metadata";
import extensionPackMetadataSchemaJson from "./extension-pack-metadata.schema.json";
@@ -27,7 +33,7 @@ const extensionPackValidate = ajv.compile(extensionPackMetadataSchemaJson);
export async function pickExtensionPack(
cliServer: Pick<CodeQLCliServer, "resolveQlpacks">,
databaseItem: Pick<DatabaseItem, "name" | "language">,
databaseItem: Pick<DatabaseItem, "name" | "language" | "origin">,
modelConfig: ModelConfig,
logger: NotificationLogger,
progress: ProgressCallback,
@@ -64,29 +70,34 @@ export async function pickExtensionPack(
maxStep,
});
// Get the `codeQL.model.extensionsDirectory` setting for the language
const userExtensionsDirectory = modelConfig.getExtensionsDirectory(
databaseItem.language,
// The default is .github/codeql/extensions/${name}-${language}
const packPath = await packLocationToAbsolute(
modelConfig.getPackLocation(
databaseItem.language,
getModelConfigPackVariables(databaseItem),
),
logger,
);
// If the setting is not set, automatically pick a suitable directory
const extensionsDirectory = userExtensionsDirectory
? Uri.file(userExtensionsDirectory)
: await autoPickExtensionsDirectory(logger);
if (!extensionsDirectory) {
if (!packPath) {
return undefined;
}
// Generate the name of the extension pack
const packName = autoNameExtensionPack(
databaseItem.name,
await ensurePackLocationIsInWorkspaceFolder(packPath, modelConfig, logger);
const userPackName = modelConfig.getPackName(
databaseItem.language,
getModelConfigPackVariables(databaseItem),
);
if (!packName) {
// Generate the name of the extension pack
const packName = sanitizePackName(userPackName);
// Validate that the name isn't too long etc.
const packNameError = validatePackName(formatPackName(packName));
if (packNameError) {
void showAndLogErrorMessage(
logger,
`Could not automatically name extension pack for database ${databaseItem.name}`,
`Invalid model pack name '${formatPackName(packName)}' for database ${databaseItem.name}: ${packNameError}`,
);
return undefined;
@@ -139,14 +150,12 @@ export async function pickExtensionPack(
return undefined;
}
const packPath = join(extensionsDirectory.fsPath, packName.name);
if (await pathExists(packPath)) {
void showAndLogErrorMessage(
logger,
`Directory ${packPath} already exists for extension pack ${formatPackName(
packName,
)}`,
)}, but wasn't returned by codeql resolve qlpacks --kind extension --no-recursive`,
);
return undefined;
@@ -155,6 +164,26 @@ export async function pickExtensionPack(
return writeExtensionPack(packPath, packName, databaseItem.language);
}
function getModelConfigPackVariables(
databaseItem: Pick<DatabaseItem, "name" | "language" | "origin">,
): ModelConfigPackVariables {
const database = databaseItem.name;
const language = databaseItem.language;
let name = databaseItem.name;
let owner = "";
if (databaseItem.origin?.type === "github") {
[owner, name] = databaseItem.origin.repository.split("/");
}
return {
database,
language,
name,
owner,
};
}
async function writeExtensionPack(
packPath: string,
packName: ExtensionPackName,

View File

@@ -1,9 +1,12 @@
import type { WorkspaceFolder } from "vscode";
import { FileType, Uri, workspace } from "vscode";
import { getOnDiskWorkspaceFoldersObjects } from "../common/vscode/workspace-folders";
import { tmpdir } from "../common/files";
import { containsPath, tmpdir } from "../common/files";
import type { NotificationLogger } from "../common/logging";
import { showAndLogErrorMessage } from "../common/logging";
import { isAbsolute, normalize, resolve } from "path";
import { nanoid } from "nanoid";
import type { ModelConfig } from "../config";
/**
* Returns the ancestors of this path in order from furthest to closest (i.e. root of filesystem to parent directory)
@@ -22,26 +25,17 @@ function getAncestors(uri: Uri): Uri[] {
return ancestors;
}
async function getRootWorkspaceDirectory(): Promise<Uri | undefined> {
// If there is a valid workspace file, just use its directory as the directory for the extensions
const workspaceFile = workspace.workspaceFile;
if (workspaceFile?.scheme === "file") {
return Uri.joinPath(workspaceFile, "..");
function findCommonAncestor(uris: Uri[]): Uri | undefined {
if (uris.length === 0) {
return undefined;
}
const allWorkspaceFolders = getOnDiskWorkspaceFoldersObjects();
// Get the system temp directory and convert it to a URI so it's normalized
const systemTmpdir = Uri.file(tmpdir());
const workspaceFolders = allWorkspaceFolders.filter((folder) => {
// Never use a workspace folder that is in the system temp directory
return !folder.uri.fsPath.startsWith(systemTmpdir.fsPath);
});
if (uris.length === 1) {
return uris[0];
}
// Find the common root directory of all workspace folders by finding the longest common prefix
const commonRoot = workspaceFolders.reduce((commonRoot, folder) => {
const folderUri = folder.uri;
const commonRoot = uris.reduce((commonRoot, folderUri) => {
const ancestors = getAncestors(folderUri);
const minLength = Math.min(commonRoot.length, ancestors.length);
@@ -55,10 +49,10 @@ async function getRootWorkspaceDirectory(): Promise<Uri | undefined> {
}
return commonRoot.slice(0, commonLength);
}, getAncestors(workspaceFolders[0].uri));
}, getAncestors(uris[0]));
if (commonRoot.length === 0) {
return await findGitFolder(workspaceFolders);
return undefined;
}
// The path closest to the workspace folders is the last element of the common root
@@ -67,6 +61,54 @@ async function getRootWorkspaceDirectory(): Promise<Uri | undefined> {
// If we are at the root of the filesystem, we can't go up any further and there's something
// wrong, so just return undefined
if (commonRootUri.fsPath === Uri.joinPath(commonRootUri, "..").fsPath) {
return undefined;
}
return commonRootUri;
}
/**
* Finds the root directory of this workspace. It is determined
* heuristically based on the on-disk workspace folders.
*
* The heuristic is as follows:
* 1. If there is a workspace file (`<basename>.code-workspace`), use the directory containing that file
* 2. If there is only 1 workspace folder, use that folder
* 3. If there is a common root directory for all workspace folders, use that directory
* - Workspace folders in the system temp directory are ignored
* - If the common root directory is the root of the filesystem, then it's not used
* 4. If there is a .git directory in any workspace folder, use the directory containing that .git directory
* for which the .git directory is closest to a workspace folder
* 5. If none of the above apply, return `undefined`
*/
export async function getRootWorkspaceDirectory(): Promise<Uri | undefined> {
// If there is a valid workspace file, just use its directory as the directory for the extensions
const workspaceFile = workspace.workspaceFile;
if (workspaceFile?.scheme === "file") {
return Uri.joinPath(workspaceFile, "..");
}
const allWorkspaceFolders = getOnDiskWorkspaceFoldersObjects();
if (allWorkspaceFolders.length === 1) {
return allWorkspaceFolders[0].uri;
}
// Get the system temp directory and convert it to a URI so it's normalized
const systemTmpdir = Uri.file(tmpdir());
const workspaceFolders = allWorkspaceFolders.filter((folder) => {
// Never use a workspace folder that is in the system temp directory
return !folder.uri.fsPath.startsWith(systemTmpdir.fsPath);
});
// The path closest to the workspace folders is the last element of the common root
const commonRootUri = findCommonAncestor(
workspaceFolders.map((folder) => folder.uri),
);
// If there is no common root URI, try to find a .git folder in the workspace folders
if (commonRootUri === undefined) {
return await findGitFolder(workspaceFolders);
}
@@ -126,90 +168,130 @@ async function findGitFolder(
return closestFolder?.[1];
}
/**
* Finds a suitable directory for extension packs to be created in. This will
* always be a path ending in `.github/codeql/extensions`. The parent directory
* will be determined heuristically based on the on-disk workspace folders.
*
* The heuristic is as follows (`.github/codeql/extensions` is added automatically unless
* otherwise specified):
* 1. If there is only 1 workspace folder, use that folder
* 2. If there is a workspace folder for which the path ends in `.github/codeql/extensions`, use that folder
* - If there are multiple such folders, use the first one
* - Does not append `.github/codeql/extensions` to the path
* 3. If there is a workspace file (`<basename>.code-workspace`), use the directory containing that file
* 4. If there is a common root directory for all workspace folders, use that directory
* - Workspace folders in the system temp directory are ignored
* - If the common root directory is the root of the filesystem, then it's not used
* 5. If there is a .git directory in any workspace folder, use the directory containing that .git directory
* for which the .git directory is closest to a workspace folder
* 6. If none of the above apply, return `undefined`
*/
export async function autoPickExtensionsDirectory(
export async function packLocationToAbsolute(
packLocation: string,
logger: NotificationLogger,
): Promise<Uri | undefined> {
const workspaceFolders = getOnDiskWorkspaceFoldersObjects();
): Promise<string | undefined> {
let userPackLocation = packLocation.trim();
// If there are no on-disk workspace folders, we can't do anything
if (workspaceFolders.length === 0) {
if (!isAbsolute(userPackLocation)) {
const rootDirectory = await getRootWorkspaceDirectory();
if (!rootDirectory) {
void logger.log("Unable to determine root workspace directory");
return undefined;
}
userPackLocation = resolve(rootDirectory.fsPath, userPackLocation);
}
userPackLocation = normalize(userPackLocation);
if (!isAbsolute(userPackLocation)) {
// This shouldn't happen, but just in case
void showAndLogErrorMessage(
logger,
`Could not find any on-disk workspace folders. Please ensure that you have opened a folder or workspace.`,
`Invalid pack location: ${userPackLocation}`,
);
return undefined;
}
// If there's only 1 workspace folder, use the `.github/codeql/extensions` directory in that folder
if (workspaceFolders.length === 1) {
return Uri.joinPath(
workspaceFolders[0].uri,
".github",
"codeql",
"extensions",
);
}
// Now try to find a workspace folder for which the path ends in `.github/codeql/extensions`
const workspaceFolderForExtensions = workspaceFolders.find((folder) =>
// Using path instead of fsPath because path always uses forward slashes
folder.uri.path.endsWith(".github/codeql/extensions"),
);
if (workspaceFolderForExtensions) {
return workspaceFolderForExtensions.uri;
}
// Get the root workspace directory, i.e. the common root directory of all workspace folders
const rootDirectory = await getRootWorkspaceDirectory();
if (!rootDirectory) {
void logger.log("Unable to determine root workspace directory");
return undefined;
}
// We'll create a new workspace folder for the extensions in the root workspace directory
// at `.github/codeql/extensions`
const extensionsUri = Uri.joinPath(
rootDirectory,
".github",
"codeql",
"extensions",
// If we are at the root of the filesystem, then something is wrong since
// this should never be the location of a pack
if (userPackLocation === resolve(userPackLocation, "..")) {
void showAndLogErrorMessage(
logger,
`Invalid pack location: ${userPackLocation}`,
);
return undefined;
}
return userPackLocation;
}
/**
* This function will try to add the pack location as a workspace folder if it's not already in a
* workspace folder and the workspace is a multi-root workspace.
*/
export async function ensurePackLocationIsInWorkspaceFolder(
packLocation: string,
modelConfig: ModelConfig,
logger: NotificationLogger,
): Promise<void> {
const workspaceFolders = getOnDiskWorkspaceFoldersObjects();
const existsInWorkspaceFolder = workspaceFolders.some((folder) =>
containsPath(folder.uri.fsPath, packLocation),
);
if (existsInWorkspaceFolder) {
// If the pack location is already in a workspace folder, we don't need to do anything
return;
}
if (workspace.workspaceFile === undefined) {
// If we're not in a workspace, we can't add a workspace folder without reloading the window,
// so we'll not do anything
return;
}
// To find the "correct" directory to add as a workspace folder, we'll generate a few different
// pack locations and find the common ancestor of the directories. This is the directory that
// we'll add as a workspace folder.
// Generate a few different pack locations to get an accurate common ancestor
const otherPackLocations = await Promise.all(
Array.from({ length: 3 }).map(() =>
packLocationToAbsolute(
modelConfig.getPackLocation(nanoid(), {
database: nanoid(),
language: nanoid(),
name: nanoid(),
owner: nanoid(),
}),
logger,
),
),
);
const otherPackLocationUris = otherPackLocations
.filter((loc): loc is string => loc !== undefined)
.map((loc) => Uri.file(loc));
if (otherPackLocationUris.length === 0) {
void logger.log(
`Failed to generate different pack locations, not adding workspace folder.`,
);
return;
}
const commonRootUri = findCommonAncestor([
Uri.file(packLocation),
...otherPackLocationUris,
]);
if (commonRootUri === undefined) {
void logger.log(
`Failed to find common ancestor for ${packLocation} and ${otherPackLocationUris[0].fsPath}, not adding workspace folder.`,
);
return;
}
if (
!workspace.updateWorkspaceFolders(
workspace.workspaceFolders?.length ?? 0,
0,
{
name: "CodeQL Extension Packs",
uri: extensionsUri,
uri: commonRootUri,
},
)
) {
void logger.log(
`Failed to add workspace folder for extensions at ${extensionsUri.fsPath}`,
`Failed to add workspace folder for extensions at ${commonRootUri.fsPath}`,
);
return undefined;
return;
}
return extensionsUri;
}

View File

@@ -0,0 +1,21 @@
import type { ModelsAsDataLanguage } from "../models-as-data";
import { staticLanguage } from "../static";
export const csharp: ModelsAsDataLanguage = {
...staticLanguage,
predicates: {
...staticLanguage.predicates,
sink: {
...staticLanguage.predicates.sink,
},
source: {
...staticLanguage.predicates.source,
supportedKinds: [
...staticLanguage.predicates.source.supportedKinds,
// https://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L122-L123
"file-write",
"windows-registry",
],
},
},
};

View File

@@ -0,0 +1,42 @@
import type { ModelsAsDataLanguage } from "../models-as-data";
import { staticLanguage } from "../static";
export const java: ModelsAsDataLanguage = {
...staticLanguage,
predicates: {
...staticLanguage.predicates,
sink: {
...staticLanguage.predicates.sink,
supportedKinds: [
...staticLanguage.predicates.sink.supportedKinds,
// https://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L32-L37
"bean-validation",
"fragment-injection",
"groovy-injection",
"hostname-verification",
"information-leak",
"intent-redirection",
"jexl-injection",
"jndi-injection",
"mvel-injection",
"notification",
"ognl-injection",
"pending-intents",
"response-splitting",
"trust-boundary-violation",
"template-injection",
"xpath-injection",
"xslt-injection",
],
},
source: {
...staticLanguage.predicates.source,
supportedKinds: [
...staticLanguage.predicates.source.supportedKinds,
// https://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L120-L121
"android-external-storage-dir",
"contentprovider",
],
},
},
};

View File

@@ -3,13 +3,14 @@ import type {
ModelsAsDataLanguage,
ModelsAsDataLanguagePredicates,
} from "./models-as-data";
import { csharp } from "./csharp";
import { java } from "./java";
import { python } from "./python";
import { ruby } from "./ruby";
import { staticLanguage } from "./static";
const languages: Partial<Record<QueryLanguage, ModelsAsDataLanguage>> = {
[QueryLanguage.CSharp]: staticLanguage,
[QueryLanguage.Java]: staticLanguage,
[QueryLanguage.CSharp]: csharp,
[QueryLanguage.Java]: java,
[QueryLanguage.Python]: python,
[QueryLanguage.Ruby]: ruby,
};

View File

@@ -20,7 +20,7 @@ import type { AccessPathSuggestionRow } from "../suggestions";
// This is a subset of the model config that doesn't import the vscode module.
// It only includes settings that are actually used.
export type ModelConfig = {
showTypeModels: boolean;
flowGeneration: boolean;
};
/**
@@ -32,12 +32,12 @@ export type ModelConfig = {
*/
export function createModelConfig(modelConfig: ModelConfig): ModelConfig {
return {
showTypeModels: modelConfig.showTypeModels,
flowGeneration: modelConfig.flowGeneration,
};
}
export const defaultModelConfig: ModelConfig = {
showTypeModels: false,
flowGeneration: false,
};
type GenerateMethodDefinition<T> = (method: T) => DataTuple[];
@@ -105,15 +105,34 @@ type ParseResultsToYaml = (
logger: BaseLogger,
) => ModelExtension[];
export enum AutoModelGenerationType {
/**
* Auto model generation is disabled and will not be run.
*/
Disabled = "disabled",
/**
* The models are generated to a separate file (suffixed with .model.generated.yml).
*/
SeparateFile = "separateFile",
/**
* The models are added as a model in the model editor, but are not automatically saved.
* The user can view them and choose to save them.
*/
Models = "models",
}
type ModelsAsDataLanguageAutoModelGeneration = {
queryConstraints: (mode: Mode) => QueryConstraints;
filterQueries?: (queryPath: string) => boolean;
/**
* This function is only used when type is `separateFile`.
*/
parseResultsToYaml: ParseResultsToYaml;
/**
* By default, auto model generation is enabled for all modes. This function can be used to
* override that behavior.
* This function is only used when type is `models`.
*/
enabled?: (context: GenerationContext) => boolean;
parseResults: ParseGenerationResults;
type: (context: GenerationContext) => AutoModelGenerationType;
};
type ModelsAsDataLanguageAccessPathSuggestions = {

View File

@@ -112,7 +112,10 @@ export function pythonPath(
export function pythonEndpointType(
method: Omit<MethodDefinition, "endpointType">,
): EndpointType {
if (method.methodParameters.startsWith("(self,")) {
if (
method.methodParameters.startsWith("(self,") ||
method.methodParameters === "(self)"
) {
return EndpointType.Method;
}
return EndpointType.Function;

View File

@@ -177,28 +177,49 @@ export const python: ModelsAsDataLanguage = {
// Argument and Parameter are equivalent in Python, but we'll use Argument in the model editor
const argumentsList = getArgumentsList(method.methodParameters).map(
(argument, index): MethodArgument => {
if (argument.endsWith(":")) {
if (
method.endpointType === EndpointType.Method &&
argument === "self" &&
index === 0
) {
return {
path: `Argument[${argument}]`,
label: `Argument[${argument}]`,
path: "Argument[self]",
label: "Argument[self]: self",
};
}
// If this is a method, self does not count as an argument index, so we
// should start at 0 for the second argument
if (method.endpointType === EndpointType.Method) {
index -= 1;
}
// Keyword-only arguments end with `:` in the query
if (argument.endsWith(":")) {
return {
path: `Argument[${argument}]`,
label: `Argument[${argument}]: ${argument.substring(0, argument.length - 1)}`,
};
}
// Positional-only arguments end with `/` in the query
if (argument.endsWith("/")) {
return {
path: `Argument[${index}]`,
label: `Argument[${index}]: ${argument.substring(0, argument.length - 1)}`,
};
}
// All other arguments are both keyword and positional
return {
path: `Argument[${index}]`,
label: `Argument[${index}]: ${argument}`,
path: `Argument[${index},${argument}:]`,
label: `Argument[${index},${argument}:]: ${argument}`,
};
},
);
return {
options: [
{
path: "Argument[self]",
label: "Argument[self]",
},
...argumentsList,
],
options: argumentsList,
// If there are no arguments, we will default to "Argument[self]"
defaultArgumentPath:
argumentsList.length > 0 ? argumentsList[0].path : "Argument[self]",

View File

@@ -1,9 +1,6 @@
import type { BaseLogger } from "../../../common/logging";
import type { DecodedBqrs } from "../../../common/bqrs-cli-types";
import type {
GenerationContext,
ModelsAsDataLanguage,
} from "../models-as-data";
import type { ModelsAsDataLanguage } from "../models-as-data";
import type { ModeledMethod } from "../../modeled-method";
import type { DataTuple } from "../../model-extension-file";
@@ -12,21 +9,10 @@ export function parseGenerateModelResults(
bqrs: DecodedBqrs,
modelsAsDataLanguage: ModelsAsDataLanguage,
logger: BaseLogger,
{ config }: GenerationContext,
): ModeledMethod[] {
const modeledMethods: ModeledMethod[] = [];
for (const resultSetName in bqrs) {
if (
resultSetName ===
modelsAsDataLanguage.predicates.type?.extensiblePredicate &&
!config.showTypeModels
) {
// Don't load generated type results when type models are hidden. These are already
// automatically generated on start-up.
continue;
}
const definition = Object.values(modelsAsDataLanguage.predicates).find(
(definition) => definition.extensiblePredicate === resultSetName,
);

View File

@@ -1,4 +1,5 @@
import type { ModelsAsDataLanguage } from "../models-as-data";
import { AutoModelGenerationType } from "../models-as-data";
import { sharedExtensiblePredicates, sharedKinds } from "../shared";
import { Mode } from "../../shared/mode";
import { parseGenerateModelResults } from "./generate";
@@ -169,7 +170,6 @@ export const ruby: ModelsAsDataLanguage = {
methodParameters: "",
};
},
isHidden: ({ config }) => !config.showTypeModels,
},
},
modelGeneration: {
@@ -209,9 +209,32 @@ export const ruby: ModelsAsDataLanguage = {
},
];
},
parseResults: (queryPath, bqrs, modelsAsDataLanguage, logger) => {
// Only parse type models when automatically generating models
const typePredicate = modelsAsDataLanguage.predicates.type;
if (!typePredicate) {
throw new Error("Type predicate not found");
}
const typeTuples = bqrs[typePredicate.extensiblePredicate];
if (!typeTuples) {
return [];
}
return parseGenerateModelResults(
queryPath,
{
[typePredicate.extensiblePredicate]: typeTuples,
},
modelsAsDataLanguage,
logger,
);
},
// Only enabled for framework mode when type models are hidden
enabled: ({ mode, config }) =>
mode === Mode.Framework && !config.showTypeModels,
type: ({ mode }) =>
mode === Mode.Framework
? AutoModelGenerationType.Models
: AutoModelGenerationType.Disabled,
},
accessPathSuggestions: {
queryConstraints: (mode) => ({

View File

@@ -6,10 +6,13 @@ export const sharedExtensiblePredicates = {
};
export const sharedKinds = {
source: ["local", "remote"],
// https://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L118-L119
source: ["local", "remote", "file", "commandargs", "database", "environment"],
// Bhttps://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L28-L31
sink: [
"code-injection",
"command-injection",
"environment-injection",
"file-content-store",
"html-injection",
"js-injection",
@@ -20,6 +23,8 @@ export const sharedKinds = {
"sql-injection",
"url-redirection",
],
// https://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L142-L143
summary: ["taint", "value"],
// https://github.com/github/codeql/blob/0c5ea975a4c4dc5c439b908c006e440cb9bdf926/shared/mad/codeql/mad/ModelValidation.qll#L155-L156
neutral: ["summary", "source", "sink"],
};

View File

@@ -10,7 +10,7 @@ function readRowToMethod(row: DataTuple[]): string {
return `${row[0]}.${row[1]}#${row[3]}${row[4]}`;
}
export const staticLanguage: ModelsAsDataLanguage = {
export const staticLanguage = {
createMethodSignature: ({
packageName,
typeName,
@@ -168,4 +168,4 @@ export const staticLanguage: ModelsAsDataLanguage = {
argumentsList.length > 0 ? argumentsList[0].path : "Argument[this]",
};
},
};
} satisfies ModelsAsDataLanguage;

View File

@@ -6,7 +6,7 @@ import { telemetryListener } from "../../common/vscode/telemetry";
import { showAndLogExceptionWithTelemetry } from "../../common/logging/notifications";
import type { App } from "../../common/app";
import { redactableError } from "../../common/errors";
import type { Method } from "../method";
import type { Method, MethodSignature } from "../method";
import type { ModelingStore } from "../modeling-store";
import { AbstractWebviewViewProvider } from "../../common/vscode/abstract-webview-view-provider";
import { assertNever } from "../../common/helpers-pure";
@@ -163,7 +163,7 @@ export class MethodModelingViewProvider extends AbstractWebviewViewProvider<
}
}
private async revealInModelEditor(method: Method): Promise<void> {
private async revealInModelEditor(method: MethodSignature): Promise<void> {
if (!this.databaseItem) {
return;
}

View File

@@ -0,0 +1,100 @@
import type { AnalysisAlert } from "../../variant-analysis/shared/analysis-result";
import type { ModeledMethod } from "../modeled-method";
import { EndpointType } from "../method";
import type { ModelAlerts } from "./model-alerts";
import type {
VariantAnalysis,
VariantAnalysisScannedRepositoryResult,
} from "../../variant-analysis/shared/variant-analysis";
/**
* Calculate which model has contributed to each alert.
* @param alerts The alerts to process.
* @param repoResults The analysis results for each repo.
* @returns The alerts grouped by modeled method.
*/
export function calculateModelAlerts(
variantAnalysis: VariantAnalysis,
repoResults: VariantAnalysisScannedRepositoryResult[],
): ModelAlerts[] {
// For now we just return some mock data, but once we have provenance information
// we'll be able to calculate this properly based on the alerts that are passed in
// and potentially some other information.
const modelAlerts: ModelAlerts[] = [];
const repoMap = new Map<number, string>();
for (const scannedRepo of variantAnalysis.scannedRepos || []) {
repoMap.set(scannedRepo.repository.id, scannedRepo.repository.fullName);
}
for (const [i, repoResult] of repoResults.entries()) {
const results = repoResult.interpretedResults || [];
const repository = {
id: repoResult.repositoryId,
fullName: repoMap.get(repoResult.repositoryId) || "",
};
const alerts = results.map(() => {
return {
alert: createMockAlert(),
repository,
};
});
modelAlerts.push({
model: createModeledMethod(i.toString()),
alerts,
});
}
return modelAlerts;
}
function createModeledMethod(suffix: string): ModeledMethod {
return {
libraryVersion: "1.6.0",
signature: `org.sql2o.Connection#createQuery${suffix}(String)`,
endpointType: EndpointType.Method,
packageName: "org.sql2o",
typeName: "Connection",
methodName: `createQuery${suffix}`,
methodParameters: "(String)",
type: "sink",
input: "Argument[0]",
kind: "path-injection",
provenance: "manual",
};
}
function createMockAlert(): AnalysisAlert {
return {
message: {
tokens: [
{
t: "text",
text: "This is an empty block.",
},
],
},
shortDescription: "This is an empty block.",
fileLink: {
fileLinkPrefix:
"https://github.com/expressjs/express/blob/33e8dc303af9277f8a7e4f46abfdcb5e72f6797b",
filePath: "test/app.options.js",
},
severity: "Warning",
codeSnippet: {
startLine: 10,
endLine: 14,
text: " app.del('/', function(){});\n app.get('/users', function(req, res){});\n app.put('/users', function(req, res){});\n\n request(app)\n",
},
highlightedRegion: {
startLine: 12,
startColumn: 41,
endLine: 12,
endColumn: 43,
},
codeFlows: [],
};
}

View File

@@ -18,9 +18,10 @@ import type { ExtensionPack } from "../shared/extension-pack";
import type {
VariantAnalysis,
VariantAnalysisScannedRepositoryResult,
VariantAnalysisScannedRepositoryState,
} from "../../variant-analysis/shared/variant-analysis";
import type { AppEvent, AppEventEmitter } from "../../common/events";
import type { ModeledMethod } from "../modeled-method";
import type { MethodSignature } from "../method";
export class ModelAlertsView extends AbstractWebview<
ToModelAlertsMessage,
@@ -49,12 +50,15 @@ export class ModelAlertsView extends AbstractWebview<
this.onEvaluationRunStopClickedEventEmitter.event;
}
public async showView() {
public async showView(
reposResults: VariantAnalysisScannedRepositoryResult[],
) {
const panel = await this.getPanel();
panel.reveal(undefined, true);
await this.waitForPanelLoaded();
await this.setViewState();
await this.setReposResults(reposResults);
}
protected async getPanelConfig(): Promise<WebviewPanelConfig> {
@@ -91,9 +95,18 @@ export class ModelAlertsView extends AbstractWebview<
case "openModelPack":
await this.app.commands.execute("revealInExplorer", Uri.file(msg.path));
break;
case "openActionsLogs":
await this.app.commands.execute(
"codeQLModelAlerts.openVariantAnalysisLogs",
msg.variantAnalysisId,
);
break;
case "stopEvaluationRun":
await this.stopEvaluationRun();
break;
case "revealInModelEditor":
await this.revealInModelEditor(msg.method);
break;
default:
assertNever(msg);
}
@@ -108,7 +121,7 @@ export class ModelAlertsView extends AbstractWebview<
});
}
public async updateVariantAnalysis(
public async setVariantAnalysis(
variantAnalysis: VariantAnalysis,
): Promise<void> {
if (!this.isShowingPanel) {
@@ -121,21 +134,8 @@ export class ModelAlertsView extends AbstractWebview<
});
}
public async updateRepoState(
repoState: VariantAnalysisScannedRepositoryState,
): Promise<void> {
if (!this.isShowingPanel) {
return;
}
await this.postMessage({
t: "setRepoStates",
repoStates: [repoState],
});
}
public async updateRepoResults(
repositoryResult: VariantAnalysisScannedRepositoryResult,
public async setReposResults(
repoResults: VariantAnalysisScannedRepositoryResult[],
): Promise<void> {
if (!this.isShowingPanel) {
return;
@@ -143,7 +143,7 @@ export class ModelAlertsView extends AbstractWebview<
await this.postMessage({
t: "setRepoResults",
repoResults: [repositoryResult],
repoResults,
});
}
@@ -167,9 +167,39 @@ export class ModelAlertsView extends AbstractWebview<
}
}),
);
this.push(
this.modelingEvents.onRevealInModelAlertsView(async (event) => {
if (event.dbUri === this.dbItem.databaseUri.toString()) {
await this.revealMethod(event.modeledMethod);
}
}),
);
}
private async stopEvaluationRun() {
this.onEvaluationRunStopClickedEventEmitter.fire();
}
private async revealInModelEditor(method: MethodSignature): Promise<void> {
if (!this.dbItem) {
return;
}
this.modelingEvents.fireRevealInModelEditorEvent(
this.dbItem.databaseUri.toString(),
method,
);
}
private async revealMethod(method: ModeledMethod): Promise<void> {
const panel = await this.getPanel();
panel?.reveal();
await this.postMessage({
t: "revealModel",
modeledMethod: method,
});
}
}

View File

@@ -0,0 +1,13 @@
import type { AnalysisAlert } from "../../variant-analysis/shared/analysis-result";
import type { ModeledMethod } from "../modeled-method";
export interface ModelAlerts {
model: ModeledMethod;
alerts: Array<{
alert: AnalysisAlert;
repository: {
id: number;
fullName: string;
};
}>;
}

View File

@@ -32,6 +32,7 @@ import { INITIAL_MODE } from "./shared/mode";
import { isSupportedLanguage } from "./supported-languages";
import { DefaultNotifier, checkConsistency } from "./consistency-check";
import type { VariantAnalysisManager } from "../variant-analysis/variant-analysis-manager";
import type { DatabaseFetcher } from "../databases/database-fetcher";
export class ModelEditorModule extends DisposableObject {
private readonly queryStorageDir: string;
@@ -42,6 +43,7 @@ export class ModelEditorModule extends DisposableObject {
private constructor(
private readonly app: App,
private readonly databaseManager: DatabaseManager,
private readonly databaseFetcher: DatabaseFetcher,
private readonly variantAnalysisManager: VariantAnalysisManager,
private readonly cliServer: CodeQLCliServer,
private readonly queryRunner: QueryRunner,
@@ -65,6 +67,7 @@ export class ModelEditorModule extends DisposableObject {
public static async initialize(
app: App,
databaseManager: DatabaseManager,
databaseFetcher: DatabaseFetcher,
variantAnalysisManager: VariantAnalysisManager,
cliServer: CodeQLCliServer,
queryRunner: QueryRunner,
@@ -73,6 +76,7 @@ export class ModelEditorModule extends DisposableObject {
const modelEditorModule = new ModelEditorModule(
app,
databaseManager,
databaseFetcher,
variantAnalysisManager,
cliServer,
queryRunner,
@@ -236,6 +240,7 @@ export class ModelEditorModule extends DisposableObject {
this.modelingEvents,
this.modelConfig,
this.databaseManager,
this.databaseFetcher,
this.variantAnalysisManager,
this.cliServer,
this.queryRunner,

View File

@@ -29,14 +29,14 @@ import type {
} from "../databases/local-databases";
import type { CodeQLCliServer } from "../codeql-cli/cli";
import { asError, assertNever, getErrorMessage } from "../common/helpers-pure";
import { promptImportGithubDatabase } from "../databases/database-fetcher";
import type { DatabaseFetcher } from "../databases/database-fetcher";
import type { App } from "../common/app";
import { redactableError } from "../common/errors";
import {
externalApiQueriesProgressMaxStep,
runModelEditorQueries,
} from "./model-editor-queries";
import type { Method } from "./method";
import type { MethodSignature } from "./method";
import type { ModeledMethod } from "./modeled-method";
import type { ExtensionPack } from "./shared/extension-pack";
import type { ModelConfigListener } from "../config";
@@ -54,7 +54,11 @@ import { telemetryListener } from "../common/vscode/telemetry";
import type { ModelingStore } from "./modeling-store";
import type { ModelingEvents } from "./modeling-events";
import type { ModelsAsDataLanguage } from "./languages";
import { createModelConfig, getModelsAsDataLanguage } from "./languages";
import {
AutoModelGenerationType,
createModelConfig,
getModelsAsDataLanguage,
} from "./languages";
import { runGenerateQueries } from "./generate";
import { ResponseError } from "vscode-jsonrpc";
import { LSPErrorCodes } from "vscode-languageclient";
@@ -86,6 +90,7 @@ export class ModelEditorView extends AbstractWebview<
private readonly modelingEvents: ModelingEvents,
private readonly modelConfig: ModelConfigListener,
private readonly databaseManager: DatabaseManager,
private readonly databaseFetcher: DatabaseFetcher,
private readonly variantAnalysisManager: VariantAnalysisManager,
private readonly cliServer: CodeQLCliServer,
private readonly queryRunner: QueryRunner,
@@ -273,7 +278,6 @@ export class ModelEditorView extends AbstractWebview<
modeledMethods,
mode,
this.cliServer,
this.modelConfig,
this.app.logger,
);
@@ -347,17 +351,7 @@ export class ModelEditorView extends AbstractWebview<
withProgress((progress) => this.loadMethods(progress), {
cancellable: false,
}),
// Only load access path suggestions if the feature is enabled
this.modelConfig.enableAccessPathSuggestions
? withProgress(
(progress) => this.loadAccessPathSuggestions(progress),
{
cancellable: false,
location: ProgressLocation.Window,
title: "Loading access path suggestions",
},
)
: undefined,
this.loadAccessPathSuggestions(),
]);
void telemetryListener?.sendUIInteraction("model-editor-switch-modes");
@@ -384,6 +378,9 @@ export class ModelEditorView extends AbstractWebview<
case "openModelAlertsView":
await this.modelEvaluator.openModelAlertsView();
break;
case "revealInModelAlertsView":
await this.modelEvaluator.revealInModelAlertsView(msg.modeledMethod);
break;
case "telemetry":
telemetryListener?.sendUIInteraction(msg.action);
break;
@@ -412,14 +409,7 @@ export class ModelEditorView extends AbstractWebview<
await this.generateModeledMethodsOnStartup();
}),
this.loadExistingModeledMethods(),
// Only load access path suggestions if the feature is enabled
this.modelConfig.enableAccessPathSuggestions
? withProgress((progress) => this.loadAccessPathSuggestions(progress), {
cancellable: false,
location: ProgressLocation.Window,
title: "Loading access path suggestions",
})
: undefined,
this.loadAccessPathSuggestions(),
]);
}
@@ -431,7 +421,7 @@ export class ModelEditorView extends AbstractWebview<
this.panel?.reveal();
}
public async revealMethod(method: Method): Promise<void> {
public async revealMethod(method: MethodSignature): Promise<void> {
this.panel?.reveal();
await this.postMessage({
@@ -496,7 +486,6 @@ export class ModelEditorView extends AbstractWebview<
this.extensionPack,
this.language,
this.cliServer,
this.modelConfig,
this.app.logger,
);
this.modelingStore.setModeledMethods(this.databaseItem, modeledMethods);
@@ -564,9 +553,7 @@ export class ModelEditorView extends AbstractWebview<
}
}
protected async loadAccessPathSuggestions(
progress: ProgressCallback,
): Promise<void> {
protected async loadAccessPathSuggestions(): Promise<void> {
const mode = this.modelingStore.getMode(this.databaseItem);
const modelsAsDataLanguage = getModelsAsDataLanguage(this.language);
@@ -575,46 +562,55 @@ export class ModelEditorView extends AbstractWebview<
return;
}
try {
const suggestions = await runSuggestionsQuery(mode, {
parseResults: (results) =>
accessPathSuggestions.parseResults(
results,
modelsAsDataLanguage,
await withProgress(
async (progress) => {
try {
const suggestions = await runSuggestionsQuery(mode, {
parseResults: (results) =>
accessPathSuggestions.parseResults(
results,
modelsAsDataLanguage,
this.app.logger,
),
queryConstraints: accessPathSuggestions.queryConstraints(mode),
cliServer: this.cliServer,
queryRunner: this.queryRunner,
queryStorageDir: this.queryStorageDir,
databaseItem: this.databaseItem,
progress,
token: this.cancellationTokenSource.token,
logger: this.app.logger,
});
if (!suggestions) {
return;
}
const options: AccessPathSuggestionOptions = {
input: parseAccessPathSuggestionRowsToOptions(suggestions.input),
output: parseAccessPathSuggestionRowsToOptions(suggestions.output),
};
await this.postMessage({
t: "setAccessPathSuggestions",
accessPathSuggestions: options,
});
} catch (e: unknown) {
void showAndLogExceptionWithTelemetry(
this.app.logger,
),
queryConstraints: accessPathSuggestions.queryConstraints(mode),
cliServer: this.cliServer,
queryRunner: this.queryRunner,
queryStorageDir: this.queryStorageDir,
databaseItem: this.databaseItem,
progress,
token: this.cancellationTokenSource.token,
logger: this.app.logger,
});
if (!suggestions) {
return;
}
const options: AccessPathSuggestionOptions = {
input: parseAccessPathSuggestionRowsToOptions(suggestions.input),
output: parseAccessPathSuggestionRowsToOptions(suggestions.output),
};
await this.postMessage({
t: "setAccessPathSuggestions",
accessPathSuggestions: options,
});
} catch (e: unknown) {
void showAndLogExceptionWithTelemetry(
this.app.logger,
this.app.telemetry,
redactableError(
asError(e),
)`Failed to fetch access path suggestions: ${getErrorMessage(e)}`,
);
}
this.app.telemetry,
redactableError(
asError(e),
)`Failed to fetch access path suggestions: ${getErrorMessage(e)}`,
);
}
},
{
cancellable: false,
location: ProgressLocation.Window,
title: "Loading access path suggestions",
},
);
}
protected async generateModeledMethods(): Promise<void> {
@@ -706,10 +702,12 @@ export class ModelEditorView extends AbstractWebview<
return;
}
if (
autoModelGeneration.enabled &&
!autoModelGeneration.enabled({ mode, config: this.modelConfig })
) {
const autoModelType = autoModelGeneration.type({
mode,
config: this.modelConfig,
});
if (autoModelType === AutoModelGenerationType.Disabled) {
return;
}
@@ -730,14 +728,37 @@ export class ModelEditorView extends AbstractWebview<
queryConstraints: autoModelGeneration.queryConstraints(mode),
filterQueries: autoModelGeneration.filterQueries,
onResults: (queryPath, results) => {
const extensions = autoModelGeneration.parseResultsToYaml(
queryPath,
results,
modelsAsDataLanguage,
this.app.logger,
);
switch (autoModelType) {
case AutoModelGenerationType.SeparateFile: {
const extensions = autoModelGeneration.parseResultsToYaml(
queryPath,
results,
modelsAsDataLanguage,
this.app.logger,
);
extensionFile.extensions.push(...extensions);
extensionFile.extensions.push(...extensions);
break;
}
case AutoModelGenerationType.Models: {
const modeledMethods = autoModelGeneration.parseResults(
queryPath,
results,
modelsAsDataLanguage,
this.app.logger,
{
mode,
config: this.modelConfig,
},
);
this.addModeledMethodsFromArray(modeledMethods);
break;
}
default: {
assertNever(autoModelType);
}
}
},
cliServer: this.cliServer,
queryRunner: this.queryRunner,
@@ -757,22 +778,24 @@ export class ModelEditorView extends AbstractWebview<
return;
}
progress({
step: 4000,
maxStep: 4000,
message: "Saving generated models",
});
if (autoModelType === AutoModelGenerationType.SeparateFile) {
progress({
step: 4000,
maxStep: 4000,
message: "Saving generated models",
});
const fileContents = `# This file was automatically generated from ${this.databaseItem.name}. Manual changes will not persist.\n\n${modelExtensionFileToYaml(extensionFile)}`;
const filePath = join(
this.extensionPack.path,
"models",
`${this.language}${GENERATED_MODELS_SUFFIX}`,
);
const fileContents = `# This file was automatically generated from ${this.databaseItem.name}. Manual changes will not persist.\n\n${modelExtensionFileToYaml(extensionFile)}`;
const filePath = join(
this.extensionPack.path,
"models",
`${this.language}${GENERATED_MODELS_SUFFIX}`,
);
await outputFile(filePath, fileContents);
await outputFile(filePath, fileContents);
void this.app.logger.log(`Saved generated model file to ${filePath}`);
void this.app.logger.log(`Saved generated model file to ${filePath}`);
}
},
{
cancellable: false,
@@ -810,57 +833,61 @@ export class ModelEditorView extends AbstractWebview<
}
private async modelDependency(): Promise<void> {
return withProgress(async (progress, token) => {
const addedDatabase =
await this.promptChooseNewOrExistingDatabase(progress);
if (!addedDatabase || token.isCancellationRequested) {
return;
}
return withProgress(
async (progress, token) => {
const addedDatabase =
await this.promptChooseNewOrExistingDatabase(progress);
if (!addedDatabase || token.isCancellationRequested) {
return;
}
const addedDbUri = addedDatabase.databaseUri.toString();
if (this.modelingStore.isDbOpen(addedDbUri)) {
this.modelingEvents.fireFocusModelEditorEvent(addedDbUri);
return;
}
const addedDbUri = addedDatabase.databaseUri.toString();
if (this.modelingStore.isDbOpen(addedDbUri)) {
this.modelingEvents.fireFocusModelEditorEvent(addedDbUri);
return;
}
const modelFile = await pickExtensionPack(
this.cliServer,
addedDatabase,
this.modelConfig,
this.app.logger,
progress,
token,
3,
);
if (!modelFile) {
return;
}
const modelFile = await pickExtensionPack(
this.cliServer,
addedDatabase,
this.modelConfig,
this.app.logger,
progress,
token,
3,
);
if (!modelFile) {
return;
}
// Check again just before opening the editor to ensure no model editor has been opened between
// our first check and now.
if (this.modelingStore.isDbOpen(addedDbUri)) {
this.modelingEvents.fireFocusModelEditorEvent(addedDbUri);
return;
}
// Check again just before opening the editor to ensure no model editor has been opened between
// our first check and now.
if (this.modelingStore.isDbOpen(addedDbUri)) {
this.modelingEvents.fireFocusModelEditorEvent(addedDbUri);
return;
}
const view = new ModelEditorView(
this.app,
this.modelingStore,
this.modelingEvents,
this.modelConfig,
this.databaseManager,
this.variantAnalysisManager,
this.cliServer,
this.queryRunner,
this.queryStorageDir,
this.queryDir,
addedDatabase,
modelFile,
this.language,
Mode.Framework,
);
await view.openView();
});
const view = new ModelEditorView(
this.app,
this.modelingStore,
this.modelingEvents,
this.modelConfig,
this.databaseManager,
this.databaseFetcher,
this.variantAnalysisManager,
this.cliServer,
this.queryRunner,
this.queryStorageDir,
this.queryDir,
addedDatabase,
modelFile,
this.language,
Mode.Framework,
);
await view.openView();
},
{ cancellable: true },
);
}
private async promptChooseNewOrExistingDatabase(
@@ -917,13 +944,10 @@ export class ModelEditorView extends AbstractWebview<
// the user to import the library database. We need to have the database
// imported to the query server, so we need to register it to our workspace.
const makeSelected = false;
const addedDatabase = await promptImportGithubDatabase(
this.app,
this.databaseManager,
this.app.workspaceStoragePath ?? this.app.globalStoragePath,
const addedDatabase = await this.databaseFetcher.promptImportGithubDatabase(
progress,
this.cliServer,
this.databaseItem.language,
undefined,
makeSelected,
false,
);

View File

@@ -13,6 +13,7 @@ import {
UserCancellationException,
withProgress,
} from "../common/vscode/progress";
import { VariantAnalysisScannedRepositoryDownloadStatus } from "../variant-analysis/shared/variant-analysis";
import type { VariantAnalysis } from "../variant-analysis/shared/variant-analysis";
import type { CancellationToken } from "vscode";
import { CancellationTokenSource } from "vscode";
@@ -20,6 +21,7 @@ import type { QlPackDetails } from "../variant-analysis/ql-pack-details";
import type { App } from "../common/app";
import { ModelAlertsView } from "./model-alerts/model-alerts-view";
import type { ExtensionPack } from "./shared/extension-pack";
import type { ModeledMethod } from "./modeled-method";
export class ModelEvaluator extends DisposableObject {
// Cancellation token source to allow cancelling of the current run
@@ -126,7 +128,6 @@ export class ModelEvaluator extends DisposableObject {
this.dbItem,
this.extensionPack,
);
await this.modelAlertsView.showView();
this.modelAlertsView.onEvaluationRunStopClicked(async () => {
await this.stopEvaluation();
@@ -148,10 +149,26 @@ export class ModelEvaluator extends DisposableObject {
throw new Error("No variant analysis available");
}
await this.modelAlertsView.updateVariantAnalysis(variantAnalysis);
const reposResults =
this.variantAnalysisManager.getLoadedResultsForVariantAnalysis(
variantAnalysis.id,
);
await this.modelAlertsView.showView(reposResults);
await this.modelAlertsView.setVariantAnalysis(variantAnalysis);
}
}
public async revealInModelAlertsView(modeledMethod: ModeledMethod) {
if (!this.modelingStore.isModelAlertsViewOpen(this.dbItem)) {
await this.openModelAlertsView();
}
this.modelingEvents.fireRevealInModelAlertsViewEvent(
this.dbItem.databaseUri.toString(),
modeledMethod,
);
}
private registerToModelingEvents() {
this.push(
this.modelingEvents.onModelEvaluationRunChanged(async (event) => {
@@ -254,7 +271,7 @@ export class ModelEvaluator extends DisposableObject {
});
// Update model alerts view
await this.modelAlertsView?.updateVariantAnalysis(variantAnalysis);
await this.modelAlertsView?.setVariantAnalysis(variantAnalysis);
}
},
),
@@ -262,8 +279,15 @@ export class ModelEvaluator extends DisposableObject {
this.push(
this.variantAnalysisManager.onRepoStatesUpdated(async (e) => {
if (e.variantAnalysisId === variantAnalysisId) {
await this.modelAlertsView?.updateRepoState(e.repoState);
if (
e.variantAnalysisId === variantAnalysisId &&
e.repoState.downloadStatus ===
VariantAnalysisScannedRepositoryDownloadStatus.Succeeded
) {
await this.readAnalysisResults(
variantAnalysisId,
e.repoState.repositoryId,
);
}
}),
);
@@ -271,9 +295,44 @@ export class ModelEvaluator extends DisposableObject {
this.push(
this.variantAnalysisManager.onRepoResultsLoaded(async (e) => {
if (e.variantAnalysisId === variantAnalysisId) {
await this.modelAlertsView?.updateRepoResults(e);
await this.modelAlertsView?.setReposResults([e]);
}
}),
);
}
private async readAnalysisResults(
variantAnalysisId: number,
repositoryId: number,
) {
const variantAnalysis =
this.variantAnalysisManager.tryGetVariantAnalysis(variantAnalysisId);
if (!variantAnalysis) {
void this.app.logger.log(
`Could not find variant analysis with id ${variantAnalysisId}`,
);
throw new Error(
"There was an error when trying to retrieve variant analysis information",
);
}
const repository = variantAnalysis.scannedRepos?.find(
(r) => r.repository.id === repositoryId,
);
if (!repository) {
void this.app.logger.log(
`Could not find repository with id ${repositoryId} in scanned repos`,
);
throw new Error(
"There was an error when trying to retrieve repository information",
);
}
// Trigger loading the results for the repository. This will trigger a
// onRepoResultsLoaded event that we'll process.
await this.variantAnalysisManager.loadResults(
variantAnalysisId,
repository.repository.fullName,
);
}
}

View File

@@ -12,7 +12,6 @@ import { load as loadYaml } from "js-yaml";
import type { CodeQLCliServer } from "../codeql-cli/cli";
import { pathsEqual } from "../common/files";
import type { QueryLanguage } from "../common/query-language";
import type { ModelConfig } from "./languages";
export const GENERATED_MODELS_SUFFIX = ".model.generated.yml";
@@ -23,14 +22,12 @@ export async function saveModeledMethods(
modeledMethods: Readonly<Record<string, readonly ModeledMethod[]>>,
mode: Mode,
cliServer: CodeQLCliServer,
modelConfig: ModelConfig,
logger: NotificationLogger,
): Promise<void> {
const existingModeledMethods = await loadModeledMethodFiles(
extensionPack,
language,
cliServer,
modelConfig,
logger,
);
@@ -53,14 +50,9 @@ async function loadModeledMethodFiles(
extensionPack: ExtensionPack,
language: QueryLanguage,
cliServer: CodeQLCliServer,
modelConfig: ModelConfig,
logger: NotificationLogger,
): Promise<Record<string, Record<string, ModeledMethod[]>>> {
const modelFiles = await listModelFiles(
extensionPack.path,
cliServer,
modelConfig,
);
const modelFiles = await listModelFiles(extensionPack.path, cliServer);
const modeledMethodsByFile: Record<
string,
@@ -92,7 +84,6 @@ export async function loadModeledMethods(
extensionPack: ExtensionPack,
language: QueryLanguage,
cliServer: CodeQLCliServer,
modelConfig: ModelConfig,
logger: NotificationLogger,
): Promise<Record<string, ModeledMethod[]>> {
const existingModeledMethods: Record<string, ModeledMethod[]> = {};
@@ -101,7 +92,6 @@ export async function loadModeledMethods(
extensionPack,
language,
cliServer,
modelConfig,
logger,
);
for (const modeledMethods of Object.values(modeledMethodsByFile)) {
@@ -120,7 +110,6 @@ export async function loadModeledMethods(
export async function listModelFiles(
extensionPackPath: string,
cliServer: CodeQLCliServer,
modelConfig: ModelConfig,
): Promise<Set<string>> {
const result = await cliServer.resolveExtensions(
extensionPackPath,
@@ -131,11 +120,8 @@ export async function listModelFiles(
for (const [path, extensions] of Object.entries(result.data)) {
if (pathsEqual(path, extensionPackPath)) {
for (const extension of extensions) {
// We only load generated models when type models are shown
if (
!modelConfig.showTypeModels &&
extension.file.endsWith(GENERATED_MODELS_SUFFIX)
) {
// We never load generated models
if (extension.file.endsWith(GENERATED_MODELS_SUFFIX)) {
continue;
}

View File

@@ -1,3 +1,4 @@
import { assertNever } from "../common/helpers-pure";
import type { MethodSignature } from "./method";
import type { ModelingStatus } from "./shared/modeling-status";
@@ -169,3 +170,86 @@ export function calculateNewProvenance(
return "manual";
}
}
export function createModeledMethodKey(modeledMethod: ModeledMethod): string {
const canonicalModeledMethod = canonicalizeModeledMethod(modeledMethod);
return JSON.stringify(
canonicalModeledMethod,
// This ensures the keys are always in the same order
Object.keys(canonicalModeledMethod).sort(),
);
}
/**
* This method will reset any properties which are not used for the specific type of modeled method.
*
* It will also set the `provenance` to `manual` since multiple modelings of the same method with a
* different provenance are not actually different.
*
* The returned canonical modeled method should only be used for comparisons. It should not be used
* for display purposes, saving the model, or any other purpose which requires the original modeled
* method to be preserved.
*
* @param modeledMethod The modeled method to canonicalize
*/
function canonicalizeModeledMethod(
modeledMethod: ModeledMethod,
): ModeledMethod {
const methodSignature: MethodSignature = {
endpointType: modeledMethod.endpointType,
signature: modeledMethod.signature,
packageName: modeledMethod.packageName,
typeName: modeledMethod.typeName,
methodName: modeledMethod.methodName,
methodParameters: modeledMethod.methodParameters,
};
switch (modeledMethod.type) {
case "none":
return {
...methodSignature,
type: "none",
};
case "source":
return {
...methodSignature,
type: "source",
output: modeledMethod.output,
kind: modeledMethod.kind,
provenance: "manual",
};
case "sink":
return {
...methodSignature,
type: "sink",
input: modeledMethod.input,
kind: modeledMethod.kind,
provenance: "manual",
};
case "summary":
return {
...methodSignature,
type: "summary",
input: modeledMethod.input,
output: modeledMethod.output,
kind: modeledMethod.kind,
provenance: "manual",
};
case "neutral":
return {
...methodSignature,
type: "neutral",
kind: modeledMethod.kind,
provenance: "manual",
};
case "type":
return {
...methodSignature,
type: "type",
relatedTypeName: modeledMethod.relatedTypeName,
path: modeledMethod.path,
};
default:
assertNever(modeledMethod);
}
}

View File

@@ -2,7 +2,7 @@ import type { App } from "../common/app";
import { DisposableObject } from "../common/disposable-object";
import type { AppEvent, AppEventEmitter } from "../common/events";
import type { DatabaseItem } from "../databases/local-databases";
import type { Method, Usage } from "./method";
import type { Method, MethodSignature, Usage } from "./method";
import type { ModelEvaluationRun } from "./model-evaluation-run";
import type { ModeledMethod } from "./modeled-method";
import type { Mode } from "./shared/mode";
@@ -58,7 +58,7 @@ interface ModelEvaluationRunChangedEvent {
interface RevealInModelEditorEvent {
dbUri: string;
method: Method;
method: MethodSignature;
}
interface FocusModelEditorEvent {
@@ -69,6 +69,11 @@ interface FocusModelAlertsViewEvent {
dbUri: string;
}
interface RevealInModelAlertsViewEvent {
dbUri: string;
modeledMethod: ModeledMethod;
}
export class ModelingEvents extends DisposableObject {
public readonly onActiveDbChanged: AppEvent<void>;
public readonly onDbOpened: AppEvent<DatabaseItem>;
@@ -84,6 +89,7 @@ export class ModelingEvents extends DisposableObject {
public readonly onRevealInModelEditor: AppEvent<RevealInModelEditorEvent>;
public readonly onFocusModelEditor: AppEvent<FocusModelEditorEvent>;
public readonly onFocusModelAlertsView: AppEvent<FocusModelAlertsViewEvent>;
public readonly onRevealInModelAlertsView: AppEvent<RevealInModelAlertsViewEvent>;
private readonly onActiveDbChangedEventEmitter: AppEventEmitter<void>;
private readonly onDbOpenedEventEmitter: AppEventEmitter<DatabaseItem>;
@@ -99,6 +105,7 @@ export class ModelingEvents extends DisposableObject {
private readonly onRevealInModelEditorEventEmitter: AppEventEmitter<RevealInModelEditorEvent>;
private readonly onFocusModelEditorEventEmitter: AppEventEmitter<FocusModelEditorEvent>;
private readonly onFocusModelAlertsViewEventEmitter: AppEventEmitter<FocusModelAlertsViewEvent>;
private readonly onRevealInModelAlertsViewEventEmitter: AppEventEmitter<RevealInModelAlertsViewEvent>;
constructor(app: App) {
super();
@@ -176,6 +183,12 @@ export class ModelingEvents extends DisposableObject {
app.createEventEmitter<FocusModelAlertsViewEvent>(),
);
this.onFocusModelAlertsView = this.onFocusModelAlertsViewEventEmitter.event;
this.onRevealInModelAlertsViewEventEmitter = this.push(
app.createEventEmitter<RevealInModelAlertsViewEvent>(),
);
this.onRevealInModelAlertsView =
this.onRevealInModelAlertsViewEventEmitter.event;
}
public fireActiveDbChangedEvent() {
@@ -285,7 +298,7 @@ export class ModelingEvents extends DisposableObject {
});
}
public fireRevealInModelEditorEvent(dbUri: string, method: Method) {
public fireRevealInModelEditorEvent(dbUri: string, method: MethodSignature) {
this.onRevealInModelEditorEventEmitter.fire({
dbUri,
method,
@@ -301,4 +314,11 @@ export class ModelingEvents extends DisposableObject {
public fireFocusModelAlertsViewEvent(dbUri: string) {
this.onFocusModelAlertsViewEventEmitter.fire({ dbUri });
}
public fireRevealInModelAlertsViewEvent(
dbUri: string,
modeledMethod: ModeledMethod,
) {
this.onRevealInModelAlertsViewEventEmitter.fire({ dbUri, modeledMethod });
}
}

View File

@@ -0,0 +1,75 @@
import type { ModelAlerts } from "../model-alerts/model-alerts";
export enum SortKey {
Alphabetically = "alphabetically",
NumberOfResults = "numberOfResults",
}
export type ModelAlertsFilterSortState = {
modelSearchValue: string;
repositorySearchValue: string;
sortKey: SortKey;
};
export const defaultFilterSortState: ModelAlertsFilterSortState = {
modelSearchValue: "",
repositorySearchValue: "",
sortKey: SortKey.NumberOfResults,
};
export function filterAndSort(
modelAlerts: ModelAlerts[],
filterSortState: ModelAlertsFilterSortState,
): ModelAlerts[] {
if (!modelAlerts || modelAlerts.length === 0) {
return [];
}
return modelAlerts
.filter((item) => matchesFilter(item, filterSortState))
.sort((a, b) => {
switch (filterSortState.sortKey) {
case SortKey.Alphabetically:
return a.model.signature.localeCompare(b.model.signature);
case SortKey.NumberOfResults:
return (b.alerts.length || 0) - (a.alerts.length || 0);
default:
return 0;
}
});
}
function matchesFilter(
item: ModelAlerts,
filterSortState: ModelAlertsFilterSortState | undefined,
): boolean {
if (!filterSortState) {
return true;
}
return (
matchesRepository(item, filterSortState.repositorySearchValue) &&
matchesModel(item, filterSortState.modelSearchValue)
);
}
function matchesRepository(
item: ModelAlerts,
repositorySearchValue: string,
): boolean {
// We may want to only return alerts that have a repository match
// but for now just return true if the model has any alerts
// with a matching repo.
return item.alerts.some((alert) =>
alert.repository.fullName
.toLowerCase()
.includes(repositorySearchValue.toLowerCase()),
);
}
function matchesModel(item: ModelAlerts, modelSearchValue: string): boolean {
return item.model.signature
.toLowerCase()
.includes(modelSearchValue.toLowerCase());
}

View File

@@ -1,6 +1,5 @@
import { createModeledMethodKey } from "../modeled-method";
import type { ModeledMethod, NeutralModeledMethod } from "../modeled-method";
import type { MethodSignature } from "../method";
import { assertNever } from "../../common/helpers-pure";
export type ModeledMethodValidationError = {
title: string;
@@ -9,80 +8,6 @@ export type ModeledMethodValidationError = {
index: number;
};
/**
* This method will reset any properties which are not used for the specific type of modeled method.
*
* It will also set the `provenance` to `manual` since multiple modelings of the same method with a
* different provenance are not actually different.
*
* The returned canonical modeled method should only be used for comparisons. It should not be used
* for display purposes, saving the model, or any other purpose which requires the original modeled
* method to be preserved.
*
* @param modeledMethod The modeled method to canonicalize
*/
function canonicalizeModeledMethod(
modeledMethod: ModeledMethod,
): ModeledMethod {
const methodSignature: MethodSignature = {
endpointType: modeledMethod.endpointType,
signature: modeledMethod.signature,
packageName: modeledMethod.packageName,
typeName: modeledMethod.typeName,
methodName: modeledMethod.methodName,
methodParameters: modeledMethod.methodParameters,
};
switch (modeledMethod.type) {
case "none":
return {
...methodSignature,
type: "none",
};
case "source":
return {
...methodSignature,
type: "source",
output: modeledMethod.output,
kind: modeledMethod.kind,
provenance: "manual",
};
case "sink":
return {
...methodSignature,
type: "sink",
input: modeledMethod.input,
kind: modeledMethod.kind,
provenance: "manual",
};
case "summary":
return {
...methodSignature,
type: "summary",
input: modeledMethod.input,
output: modeledMethod.output,
kind: modeledMethod.kind,
provenance: "manual",
};
case "neutral":
return {
...methodSignature,
type: "neutral",
kind: modeledMethod.kind,
provenance: "manual",
};
case "type":
return {
...methodSignature,
type: "type",
relatedTypeName: modeledMethod.relatedTypeName,
path: modeledMethod.path,
};
default:
assertNever(modeledMethod);
}
}
export function validateModeledMethods(
modeledMethods: ModeledMethod[],
): ModeledMethodValidationError[] {
@@ -97,12 +22,7 @@ export function validateModeledMethods(
// an error for any duplicates.
const seenModeledMethods = new Set<string>();
for (const modeledMethod of consideredModeledMethods) {
const canonicalModeledMethod = canonicalizeModeledMethod(modeledMethod);
const key = JSON.stringify(
canonicalModeledMethod,
// This ensures the keys are always in the same order
Object.keys(canonicalModeledMethod).sort(),
);
const key = createModeledMethodKey(modeledMethod);
if (seenModeledMethods.has(key)) {
result.push({

View File

@@ -1,6 +1,5 @@
import { QueryLanguage } from "../common/query-language";
import type { ModelConfig } from "../config";
import { isCanary } from "../config";
/**
* Languages that are always supported by the model editor. These languages
@@ -9,6 +8,7 @@ import { isCanary } from "../config";
export const SUPPORTED_LANGUAGES: QueryLanguage[] = [
QueryLanguage.Java,
QueryLanguage.CSharp,
QueryLanguage.Ruby,
];
export function isSupportedLanguage(
@@ -19,11 +19,6 @@ export function isSupportedLanguage(
return true;
}
if (language === QueryLanguage.Ruby) {
// Ruby is only enabled when in canary mode
return isCanary();
}
if (language === QueryLanguage.Python) {
// Python is only enabled when the config setting is set
return modelConfig.enablePython;

View File

@@ -51,6 +51,9 @@
"$ref": "#/definitions/SuiteInstruction"
}
},
{
"$ref": "#/definitions/SuiteInstruction"
},
{
"type": "null"
}
@@ -93,19 +96,33 @@
"include": {
"type": "object",
"additionalProperties": {
"type": "array",
"items": {
"type": "string"
}
"anyOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
}
},
"exclude": {
"type": "object",
"additionalProperties": {
"type": "array",
"items": {
"type": "string"
}
"anyOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
}
},
"description": {

View File

@@ -10,7 +10,7 @@ export interface QlPackFile {
extensionTargets?: Record<string, string> | null;
dbscheme?: string | null;
library?: boolean | null;
defaultSuite?: SuiteInstruction[] | null;
defaultSuite?: SuiteInstruction[] | SuiteInstruction | null;
defaultSuiteFile?: string | null;
dataExtensions?: string[] | string | null;
}

View File

@@ -5,8 +5,8 @@ export interface SuiteInstruction {
qlpack?: string;
query?: string;
queries?: string;
include?: Record<string, string[]>;
exclude?: Record<string, string[]>;
include?: Record<string, string[] | string>;
exclude?: Record<string, string[] | string>;
description?: string;
import?: string;
from?: string;

View File

@@ -7,6 +7,7 @@ import {
getActionsWorkflowRunUrl as getVariantAnalysisActionsWorkflowRunUrl,
} from "../variant-analysis/shared/variant-analysis";
import type { QueryLanguage } from "../common/query-language";
import { getGitHubInstanceUrl } from "../config";
export type QueryHistoryInfo = LocalQueryInfo | VariantAnalysisHistoryItem;
@@ -79,5 +80,8 @@ export function buildRepoLabel(item: VariantAnalysisHistoryItem): string {
export function getActionsWorkflowRunUrl(
item: VariantAnalysisHistoryItem,
): string {
return getVariantAnalysisActionsWorkflowRunUrl(item.variantAnalysis);
return getVariantAnalysisActionsWorkflowRunUrl(
item.variantAnalysis,
getGitHubInstanceUrl(),
);
}

View File

@@ -48,11 +48,6 @@ function mapVariantAnalysisDtoToDto(
): VariantAnalysisDto {
return {
id: variantAnalysis.id,
controllerRepo: {
id: variantAnalysis.controllerRepo.id,
fullName: variantAnalysis.controllerRepo.fullName,
private: variantAnalysis.controllerRepo.private,
},
query: {
name: variantAnalysis.query.name,
filePath: variantAnalysis.query.filePath,

View File

@@ -48,12 +48,12 @@ function mapVariantAnalysisToDomainModel(
): VariantAnalysis {
return {
id: variantAnalysis.id,
controllerRepo: {
id: variantAnalysis.controllerRepo.id,
fullName: variantAnalysis.controllerRepo.fullName,
private: variantAnalysis.controllerRepo.private,
},
language: mapQueryLanguageToDomainModel(variantAnalysis.query.language),
controllerRepo: {
id: 0,
fullName: "",
private: false,
},
query: {
name: variantAnalysis.query.name,
filePath: variantAnalysis.query.filePath,

View File

@@ -15,11 +15,6 @@ export interface QueryHistoryVariantAnalysisDto {
export interface VariantAnalysisDto {
id: number;
controllerRepo: {
id: number;
fullName: string;
private: boolean;
};
query: {
name: string;
filePath: string;

View File

@@ -91,26 +91,15 @@ export class QueryRunner {
return this.qs.logger;
}
async restartQueryServer(
progress: ProgressCallback,
token: CancellationToken,
): Promise<void> {
await this.qs.restartQueryServer(progress, token);
async restartQueryServer(progress: ProgressCallback): Promise<void> {
await this.qs.restartQueryServer(progress);
}
onStart(
callBack: (
progress: ProgressCallback,
token: CancellationToken,
) => Promise<void>,
) {
onStart(callBack: (progress: ProgressCallback) => Promise<void>) {
this.qs.onDidStartQueryServer(callBack);
}
async clearCacheInDatabase(
dbItem: DatabaseItem,
token: CancellationToken,
): Promise<void> {
async clearCacheInDatabase(dbItem: DatabaseItem): Promise<void> {
if (dbItem.contents === undefined) {
throw new Error("Can't clear the cache in an invalid database.");
}
@@ -120,13 +109,10 @@ export class QueryRunner {
dryRun: false,
db,
};
await this.qs.sendRequest(clearCache, params, token);
await this.qs.sendRequest(clearCache, params);
}
async trimCacheInDatabase(
dbItem: DatabaseItem,
token: CancellationToken,
): Promise<void> {
async trimCacheInDatabase(dbItem: DatabaseItem): Promise<void> {
if (dbItem.contents === undefined) {
throw new Error("Can't trim the cache in an invalid database.");
}
@@ -135,7 +121,7 @@ export class QueryRunner {
const params: TrimCacheParams = {
db,
};
await this.qs.sendRequest(trimCache, params, token);
await this.qs.sendRequest(trimCache, params);
}
public async compileAndRunQueryAgainstDatabaseCore(

View File

@@ -14,7 +14,7 @@ import type { ProgressReporter } from "../common/logging/vscode";
import { extLogger } from "../common/logging/vscode";
import type { ProgressMessage, WithProgressId } from "./messages";
import { progress } from "./messages";
import type { ProgressCallback, ProgressTask } from "../common/vscode/progress";
import type { ProgressCallback } from "../common/vscode/progress";
import { withProgress } from "../common/vscode/progress";
import { ServerProcess } from "./server-process";
import type { App } from "../common/app";
@@ -51,12 +51,16 @@ export class QueryServerClient extends DisposableObject {
withProgressReporting: WithProgressReporting;
private readonly queryServerStartListeners = [] as Array<ProgressTask<void>>;
private readonly queryServerStartListeners = [] as Array<
(progress: ProgressCallback) => void
>;
// Can't use standard vscode EventEmitter here since they do not cause the calling
// function to fail if one of the event handlers fail. This is something that
// we need here.
readonly onDidStartQueryServer = (e: ProgressTask<void>) => {
readonly onDidStartQueryServer = (
e: (progress: ProgressCallback) => void,
) => {
this.queryServerStartListeners.push(e);
};
@@ -105,14 +109,11 @@ export class QueryServerClient extends DisposableObject {
* This resets the unexpected termination count. As hopefully it is an indication that the user has fixed the
* issue.
*/
async restartQueryServer(
progress: ProgressCallback,
token: CancellationToken,
): Promise<void> {
async restartQueryServer(progress: ProgressCallback): Promise<void> {
// Reset the unexpected termination count when we restart the query server manually
// or due to config change
this.unexpectedTerminationCount = 0;
await this.restartQueryServerInternal(progress, token);
await this.restartQueryServerInternal(progress);
}
/**
@@ -121,8 +122,7 @@ export class QueryServerClient extends DisposableObject {
private restartQueryServerOnFailure() {
if (this.unexpectedTerminationCount < MAX_UNEXPECTED_TERMINATIONS) {
void withProgress(
async (progress, token) =>
this.restartQueryServerInternal(progress, token),
async (progress) => this.restartQueryServerInternal(progress),
{
title: "Restarting CodeQL query server due to unexpected termination",
},
@@ -144,7 +144,6 @@ export class QueryServerClient extends DisposableObject {
*/
private async restartQueryServerInternal(
progress: ProgressCallback,
token: CancellationToken,
): Promise<void> {
this.stopQueryServer();
await this.startQueryServer();
@@ -152,7 +151,7 @@ export class QueryServerClient extends DisposableObject {
// Ensure we await all responses from event handlers so that
// errors can be properly reported to the user.
await Promise.all(
this.queryServerStartListeners.map((handler) => handler(progress, token)),
this.queryServerStartListeners.map((handler) => handler(progress)),
);
}
@@ -241,8 +240,32 @@ export class QueryServerClient extends DisposableObject {
this.nextCallback = 0;
this.nextProgress = 0;
this.progressCallbacks = {};
child.on("close", () => {
this.restartQueryServerOnFailure();
// 'exit' may or may not fire after 'error' event, so we want to guard against restarting the
// query server twice if both events fire.
let wasExitOrErrorHandled = false;
child.on("error", (err: Error) => {
if (!wasExitOrErrorHandled) {
void this.logger.log(`Query server terminated with error: ${err}.`);
this.restartQueryServerOnFailure();
wasExitOrErrorHandled = true;
}
});
child.on("exit", (code: number, signal: string) => {
if (!wasExitOrErrorHandled) {
if (code !== null) {
void this.logger.log(
`Query server terminated with exit code: ${code}.`,
);
}
if (signal !== null) {
void this.logger.log(
`Query server terminated due to receipt of signal: ${signal}.`,
);
}
this.restartQueryServerOnFailure();
wasExitOrErrorHandled = true;
}
});
}

View File

@@ -31,6 +31,8 @@ import { generateSummarySymbolsFile } from "./log-insights/summary-parser";
import { getErrorMessage } from "./common/helpers-pure";
import { createHash } from "crypto";
import { QueryOutputDir } from "./local-queries/query-output-dir";
import { progressUpdate } from "./common/vscode/progress";
import type { ProgressCallback } from "./common/vscode/progress";
/**
* run-queries.ts
@@ -519,6 +521,7 @@ export async function createInitialQueryInfo(
export async function generateEvalLogSummaries(
cliServer: CodeQLCliServer,
outputDir: QueryOutputDir,
progress: ProgressCallback,
): Promise<EvaluatorLogPaths | undefined> {
const log = outputDir.evalLogPath;
if (!(await pathExists(log))) {
@@ -527,6 +530,7 @@ export async function generateEvalLogSummaries(
}
let humanReadableSummary: string | undefined = undefined;
let endSummary: string | undefined = undefined;
progress(progressUpdate(1, 3, "Generating evaluator log summary"));
if (await generateHumanReadableLogSummary(cliServer, outputDir)) {
humanReadableSummary = outputDir.evalLogSummaryPath;
endSummary = outputDir.evalLogEndSummaryPath;
@@ -535,10 +539,12 @@ export async function generateEvalLogSummaries(
let summarySymbols: string | undefined = undefined;
if (isCanary()) {
// Generate JSON summary for viewer.
progress(progressUpdate(2, 3, "Generating JSON log summary"));
jsonSummary = outputDir.jsonEvalLogSummaryPath;
await cliServer.generateJsonLogSummary(log, jsonSummary);
if (humanReadableSummary !== undefined) {
progress(progressUpdate(3, 3, "Generating summary symbols file"));
summarySymbols = outputDir.evalLogSummarySymbolsPath;
await generateSummarySymbolsFile(humanReadableSummary, summarySymbols);
}

View File

@@ -1,4 +1,4 @@
import { Canvas, Meta, Story } from '@storybook/addon-docs';
import { Canvas, Meta, Story } from '@storybook/blocks';
import { VSCodeButton } from '@vscode/webview-ui-toolkit/react';
@@ -39,23 +39,29 @@ updated manually if new variables are added to VSCode. It can also be updated if
these variables, follow these steps:
1. Make sure you have selected the correct theme. If you want to use a variable which is currently not available and will be committed, please
select the **Dark+** theme. You can use **Preferences: Color Theme** in the *Command Palette* to select the theme.
select the **Dark+** theme. You can use **Preferences: Color Theme** in the *Command Palette* to select the theme.
2. Open a WebView in VSCode (for example the results of a query)
3. Open the *Command Palette* (Ctrl/Cmd+Shift+P)
4. Select **Developer: Open WebView Developer Tools**
5. Now, you will need to find the `<html>` element in the lowest-level `<iframe>`. See the image below:
<img src={iframeImage} alt="The iframe element showing in the VS Code webview developer tools element inspector" />
6. Once you have selected the `<html>` element as in the image above, click on **Show All Properties (... more)** (see image below). This will
expand all CSS variables.
expand all CSS variables.
<img src={stylesImage} alt="The styles tab of the VS Code webview developer tools element inspector" />
7. Copy all variables to the `src/stories/vscode-theme-dark.css` file.
8. Now, select the `<body>` element which is a direct child of the `<html>` element.
9. This time, you do not need to copy the variables. Instead, copy the styles on the `<body>` element to the `src/stories/vscode-theme-dark.css` file.
See the image below for which styles need to be copied.
See the image below for which styles need to be copied.
<img src={bodyImage} alt="The styles on the body element showing in the VS Code webview developer tools element inspector" />

View File

@@ -0,0 +1,29 @@
import { useState } from "react";
import type { Meta } from "@storybook/react";
import { SearchBox as SearchBoxComponent } from "../../view/common/SearchBox";
export default {
title: "Search Box",
component: SearchBoxComponent,
argTypes: {
value: {
control: {
disable: true,
},
},
},
} as Meta<typeof SearchBoxComponent>;
export const SearchBox = () => {
const [value, setValue] = useState("");
return (
<SearchBoxComponent
value={value}
placeholder="Filter by x/y/z..."
onChange={setValue}
/>
);
};

View File

@@ -2,6 +2,9 @@ import type { Meta, StoryFn } from "@storybook/react";
import { ModelAlerts as ModelAlertsComponent } from "../../view/model-alerts/ModelAlerts";
import { createMockVariantAnalysis } from "../../../test/factories/variant-analysis/shared/variant-analysis";
import { VariantAnalysisRepoStatus } from "../../variant-analysis/shared/variant-analysis";
import type { VariantAnalysisScannedRepositoryResult } from "../../variant-analysis/shared/variant-analysis";
import { createMockAnalysisAlert } from "../../../test/factories/variant-analysis/shared/analysis-alert";
export default {
title: "Model Alerts/Model Alerts",
@@ -12,19 +15,94 @@ const Template: StoryFn<typeof ModelAlertsComponent> = (args) => (
<ModelAlertsComponent {...args} />
);
const variantAnalysis = createMockVariantAnalysis({
modelPacks: [
{
name: "Model pack 1",
path: "/path/to/model-pack-1",
},
{
name: "Model pack 2",
path: "/path/to/model-pack-2",
},
],
scannedRepos: [
{
repository: {
id: 1,
fullName: "org/repo1",
private: false,
stargazersCount: 100,
updatedAt: new Date().toISOString(),
},
analysisStatus: VariantAnalysisRepoStatus.InProgress,
resultCount: 0,
artifactSizeInBytes: 0,
},
{
repository: {
id: 2,
fullName: "org/repo2",
private: false,
stargazersCount: 100,
updatedAt: new Date().toISOString(),
},
analysisStatus: VariantAnalysisRepoStatus.Succeeded,
resultCount: 0,
artifactSizeInBytes: 0,
},
{
repository: {
id: 3,
fullName: "org/repo3",
private: false,
stargazersCount: 100,
updatedAt: new Date().toISOString(),
},
analysisStatus: VariantAnalysisRepoStatus.Succeeded,
resultCount: 1,
artifactSizeInBytes: 0,
},
{
repository: {
id: 4,
fullName: "org/repo4",
private: false,
stargazersCount: 100,
updatedAt: new Date().toISOString(),
},
analysisStatus: VariantAnalysisRepoStatus.Succeeded,
resultCount: 3,
artifactSizeInBytes: 0,
},
],
});
const repoResults: VariantAnalysisScannedRepositoryResult[] = [
{
variantAnalysisId: variantAnalysis.id,
repositoryId: 2,
interpretedResults: [createMockAnalysisAlert(), createMockAnalysisAlert()],
},
{
variantAnalysisId: variantAnalysis.id,
repositoryId: 3,
interpretedResults: [
createMockAnalysisAlert(),
createMockAnalysisAlert(),
createMockAnalysisAlert(),
],
},
{
variantAnalysisId: variantAnalysis.id,
repositoryId: 4,
interpretedResults: [createMockAnalysisAlert()],
},
];
export const ModelAlerts = Template.bind({});
ModelAlerts.args = {
initialViewState: { title: "codeql/sql2o-models" },
variantAnalysis: createMockVariantAnalysis({
modelPacks: [
{
name: "Model pack 1",
path: "/path/to/model-pack-1",
},
{
name: "Model pack 2",
path: "/path/to/model-pack-2",
},
],
}),
variantAnalysis,
repoResults,
};

View File

@@ -13,6 +13,12 @@ export default {
disable: true,
},
},
onViewLogsClick: {
action: "view-logs-clicked",
table: {
disable: true,
},
},
stopRunClick: {
action: "stop-run-clicked",
table: {

View File

@@ -0,0 +1,30 @@
import type { Meta, StoryFn } from "@storybook/react";
import { ModelAlertsResults as ModelAlertsResultsComponent } from "../../view/model-alerts/ModelAlertsResults";
import { createSinkModeledMethod } from "../../../test/factories/model-editor/modeled-method-factories";
import { createMockAnalysisAlert } from "../../../test/factories/variant-analysis/shared/analysis-alert";
export default {
title: "Model Alerts/Model Alerts Results",
component: ModelAlertsResultsComponent,
} as Meta<typeof ModelAlertsResultsComponent>;
const Template: StoryFn<typeof ModelAlertsResultsComponent> = (args) => (
<ModelAlertsResultsComponent {...args} />
);
export const ModelAlertsResults = Template.bind({});
ModelAlertsResults.args = {
modelAlerts: {
model: createSinkModeledMethod(),
alerts: [
{
repository: {
id: 1,
fullName: "expressjs/express",
},
alert: createMockAnalysisAlert(),
},
],
},
};

Some files were not shown because too many files have changed in this diff Show More