Charis Kyriakou
424520613e
Initial setup around GitHub API mock server ( #1629 )
2022-10-19 12:05:28 +00:00
Charis Kyriakou
baf1b70460
Add GitHub API requests that will be mocked ( #1626 )
2022-10-19 11:38:41 +01:00
shati-patel
986749b40f
Open query text as a .ql file
...
This fixes a minor bug (introduced in https://github.com/github/vscode-codeql/pull/1115/files#diff-cf43a74569f5e6eea483a9178f5de8fc372f8ca652017d3f1451dd2640876874L603 ) where we accidentally removed the `.ql` file extension. I've hard-coded it here, and tested it works for the local, remote, and variant-analysis cases.
2022-10-18 17:10:08 +01:00
shati-patel
9c2821a418
Unit tests for getQueryText
2022-10-18 17:10:08 +01:00
shati-patel
93a6f50c0e
Create query history items at start of test
2022-10-18 17:10:08 +01:00
shati-patel
0413b01990
Implement getQueryText for variant analysis items
...
Also moved this to the `query-history-info` helper file
2022-10-18 17:10:08 +01:00
Shati Patel
6b27a4209a
Merge pull request #1614 from github/shati-patel/query-history-get-id
...
Get query ID for query history items (incl `VariantAnalysisHistoryItem`)
2022-10-18 12:40:04 +01:00
shati-patel
1bb68d65f9
Merge branch 'main' into shati-patel/query-history-get-id
2022-10-18 11:59:22 +01:00
shati-patel
fd13c35b5d
Rename queryId -> historyItemId
2022-10-18 11:58:55 +01:00
shati-patel
77deea77fc
Rename: queryId -> historyItemId
2022-10-18 11:39:16 +01:00
shati-patel
2eaa923019
Rename function: getQueryId -> getQueryHistoryItemId
2022-10-18 11:31:46 +01:00
shati-patel
ad9b46e494
Use a generated queryId on VariantAnalysisHistoryItem
2022-10-18 11:29:17 +01:00
Elena Tanasoiu
fa4766fe91
Merge pull request #1599 from github/elenatanasoiu/add-batching-to-download-take-two
...
Download variant analysis results in batches - take two
2022-10-18 10:32:18 +01:00
Shati Patel
28eb9ead01
Merge pull request #1606 from github/shati-patel/query-history-info-tests
...
Add unit tests for `query-history-info`
2022-10-18 10:17:33 +01:00
Shati Patel
0013a0f1b2
Clean-up: Remove unsupported CLI version from testing matrix
...
We officially only support the previous 4 minor versions of the CLI, so v2.6.3 can go.
2022-10-18 09:50:13 +01:00
Elena Tanasoiu
25b71e8651
Merge branch 'main' into elenatanasoiu/add-batching-to-download-take-two
2022-10-17 16:20:31 +01:00
Elena Tanasoiu
31a97897c8
Use fewer async/awaits
2022-10-17 16:13:46 +01:00
Elena Tanasoiu
bf7509e3df
Add test to check results are being downloaded
...
Previously we were only checking whether we're triggering the download
command in the extension.
Now we're mocking `autoDownloadVariantAnalysisResult` on the
variantAnalysisManager and checking that it's being called for all repos
that have available results.
2022-10-17 15:58:01 +01:00
Charis Kyriakou
4fd9b54c58
Remove debug log entry ( #1616 )
2022-10-17 14:52:26 +00:00
Elena Tanasoiu
7d2bae1f1b
Remove extra parentheses
2022-10-17 14:55:09 +01:00
Elena Tanasoiu
1f4e1f27ae
Make queue private and one-line initiatialization for it
2022-10-17 14:51:06 +01:00
Elena Tanasoiu
3a1800319a
Move guts for adding task to a queue into a method
...
So that the extension command doesn't need to know how to push to a queue.
2022-10-17 14:51:06 +01:00
Elena Tanasoiu
f2fe1063d9
Rename maxConcurrentTasks to maxConcurrentDownloads
2022-10-17 14:51:06 +01:00
Elena Tanasoiu
7e1b35eae4
Don't use Promise.all
...
Since we're only adding one task at a time.
2022-10-17 14:51:05 +01:00
Elena Tanasoiu
3283b68ff9
Download results in batches
...
This makes use of the p-queue package to download our variant analysis
results in batches of 3 at a time.
2022-10-17 14:51:05 +01:00
Elena Tanasoiu
aaf21d35f6
Install p-queue
2022-10-17 14:51:05 +01:00
Elena Tanasoiu
67a6ab5c8e
Test that we only download results once per repo
...
To make us confident that we're not repeatedly downloading results.
2022-10-17 14:51:05 +01:00
Elena Tanasoiu
64994d7c03
Extract downloadVariantAnalysisResults method
...
In the next commit we'll start changing this method to support batching.
2022-10-17 14:51:05 +01:00
Elena Tanasoiu
362094b8de
Extract getReposToDownload method
2022-10-17 14:51:04 +01:00
Elena Tanasoiu
e791e77ef9
Extract shouldDownload method
2022-10-17 14:51:04 +01:00
Elena Tanasoiu
0009114f7b
Extract scheduleForDownload method
...
Before we make any changes, let's extract some of the monitor code into
smaller methods.
Since we have test coverage, we're able to do this quite comfortably.
2022-10-17 14:51:04 +01:00
aeisenberg
3b644fea7b
Bump version to v1.7.3
2022-10-17 10:03:25 +01:00
shati-patel
04c9f17398
Get query ID for query history items (incl VariantAnalysisHistoryItem)
2022-10-17 09:53:34 +01:00
shati-patel
60e9f552db
Add unit tests for query-history-info
2022-10-17 09:51:56 +01:00
Dave Bartolomeo
38caad032b
Merge pull request #1604 from github/dbartol/join-order-threshold
...
Make bad join order warning threshold configurable
2022-10-14 18:20:42 -04:00
Andrew Eisenberg
7c1a8b3bc9
Merge pull request #1612 from github/revert-1586-koesie10/upgrade-vscode-test
...
Revert "Upgrade from vscode-test to @vscode/test-electron"
2022-10-14 14:50:51 -07:00
Andrew Eisenberg
c7c709b366
Revert "Upgrade from vscode-test to @vscode/test-electron"
2022-10-14 14:15:18 -07:00
Andrew Eisenberg
bf662354fe
Merge pull request #1609 from github/v1.7.2
...
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
v1.7.2
v1.7.2
2022-10-14 12:55:51 -07:00
Dave Bartolomeo
131e72b162
Decouple join-order.ts from VS Code for testing purposes
2022-10-14 15:32:03 -04:00
Dave Bartolomeo
4b875e7e42
Merge remote-tracking branch 'origin/main' into dbartol/join-order-threshold
2022-10-14 15:01:41 -04:00
Andrew Eisenberg
6ea36867a2
v1.7.2
2022-10-14 10:44:07 -07:00
Andrew Eisenberg
8df061f443
Merge pull request #1607 from github/aeisenberg/fix-failing-tests
...
`loadPersistedState` should happen outside of dbm constructor
2022-10-14 10:13:10 -07:00
Andrew Eisenberg
0885a22984
loadPersistedState should happen outside of dbm constructor
...
Also, add stub to logger in tests.
This fixes some occasionally failing tests on main.
2022-10-14 09:29:47 -07:00
Andrew Eisenberg
0354b1caac
Merge pull request #1605 from github/aeisenberg/fix-missing-success
...
Fix deserialization error
2022-10-14 08:29:37 -07:00
Koen Vlaswinkel
d32a3a0deb
Merge pull request #1601 from github/koesie10/completed-status
...
Add display of duration and completion status
2022-10-14 17:25:10 +02:00
shati-patel
e41dba7627
Move createMockRemoteQueryHistoryItem into shared location
2022-10-14 16:14:22 +01:00
shati-patel
b2f4fecfb4
Move createMockLocalQueryInfo into shared location
2022-10-14 16:14:22 +01:00
Koen Vlaswinkel
21b6adb92c
Merge pull request #1575 from github/koesie10/reset-config
...
Reset VSCode configuration between tests
2022-10-14 16:52:46 +02:00
Andrew Eisenberg
90577f516f
Update changelog
2022-10-14 07:42:11 -07:00
Andrew Eisenberg
a2825162ac
Fix deserialization error
...
We added a `successful` property to serialized local queries. But, this
property does not exist on older serialized queries. This change ensures
older queries get a `successful` property when deserialized.
2022-10-14 07:39:02 -07:00