Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extension Test API - run results are not correctly updated when using multiple vscode.TestRun objects #180041

Closed
jimasp opened this issue Apr 15, 2023 · 7 comments · Fixed by #180746 or #181160
Assignees
Labels
author-verification-requested Issues potentially verifiable by issue author bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders testing Built-in testing support verified Verification succeeded
Milestone

Comments

@jimasp
Copy link

jimasp commented Apr 15, 2023

Does this issue occur when all extensions are disabled?: Yes (with the exception the extension code in question)

  • VS Code Version: 1.77.2 (but this bug is not new)
  • OS Version: Ubuntu 22.04

Imagine you have a multiroot workpace containing 3 project folders.
As an extension author, you want to create a vscode.TestRun object for each project folder, and kick off all three test runs asynchronously (i.e. in parallel) from a single vscode.TestRunRequest.

Unfortunately, this results in:

  • run.passed not being honoured by the UI until the end of a different test run (or potentially all runs)
  • run.skipped not being honoured at all (showing as not run rather than skipped).
    (run.failed works correctly)

Given the above, if the code sequence is:
run.enqueued(test) -> run.started(test) -> run.passed(test) -> run.skipped(test2) -> run.end()
Then what the user will actually see in the UI is as if the code sequence had been:
run.enqueued(test) -> run.started(test) -> run.enqueued(test) -> run.end() -> run.passed(test)
( run.skipped(test2) has no UI effect and the test is shown as not run)

i.e. the test items are stuck in a run.enqueued state until the end of a run (except for run.failed)
What is stranger is that it's not the run that is ended that has its tests updated, but a different run.
The run objects seem to be interacting with each other, i.e. they are not isolated.
This lack of isolation between run objects is confusing as an extension author (and most likely unintended, as it is not mentioned in documentation).
Equally, run.appendOutput also uses an output terminal shared between all run objects and therefore if all tests are run, then the output from all project folders (likely with different test runners) is intertwined and not isolated. This is a bit odd conceptually, given the api method is on the distinct TestRun object and not the shared RunRequest object.

The above issues could be solved by using a single run object for all project folders. However, the docs indicate that creating separate run objects is up to the extension author (without any caveats or warnings). At any rate, this approach would not help in the case of the next example...

Imagine there are two test extensions from different authors in the same workspace.
These extensions create their own vscode.TestRun objects, but what happens is:

  • tests are not fully updated until the other extension ends its run
  • run.appendOutput of the two run objects (and therefore two extensions) is intertwined in the test output terminal window (and testresults view), consequently any test output is not sequential or human-readable, such that the extension authors must use an extension-specific output window instead to isolate their extension test output (especially in the case of BDD output). Alternatively they could buffer the output, but buffering is not a good experience for the user. Guidance on the intended MS design to avoid intertwined test output between extensions would be appreciated, given separate run objects are not sufficient to isolate the output. Possibly the docs should be updated?

The extension author may reasonably, but wrongly, assume that (other than the sharing of vscode.TestRunRequest) the test runs are isolated and do not interact, and may not realise these issues exist during their testing unless they are running all tests and have another active test extension installed with its own tests.
Thus the manifestation of the results not being updated until the end of the run has previously been observed with two of Microsoft's own extensions and raised here.

Here is a gif of the behaviour using a simple (single) extension with three run objects, one per project folder.
We can see when the run result has been updated in the terminal window, but non-failed tests are stuck in a queued state in the UI until a different run or all runs are ended by clicking OK. Additionally we can see that skipped tests are never updated correctly, and that all runs use the same terminal window and so the output is intertwined between the runs.

GIF

Below is the code that produced the above gif.
Note that the code intentionally does not use a real mulitroot workspace, just a simulation of one. This is to show that the problem is not limited/caused by multiroot workspaces (or multiple extensions) but simply because run objects are not isolated from each other.
Another thing that is not shown in the gif that I noticed afterwards is that the "Test Results" window also looks wrong, only the first run (project 1) has expandable nodes.

// extension.ts

import * as vscode from 'vscode';

const projectFolders = ['project1', 'project2', 'project3'];

export function activate(context: vscode.ExtensionContext) {
	const ctrl = vscode.tests.createTestController('runtests', 'runtests');
	context.subscriptions.push(ctrl);
	const runHandler = testRunHandler(ctrl);

	// simulate multiroot workspace with 3 project folders
	for (const name of projectFolders) {
		const projectItem = ctrl.createTestItem(name, name);
		ctrl.items.add(projectItem);		
		createTestsForProjectFolder(ctrl, projectItem);
	}


	ctrl.createRunProfile('Run Tests', vscode.TestRunProfileKind.Run,
		async (request: vscode.TestRunRequest) => {
			await vscode.commands.executeCommand("testing.clearTestResults");			
			await runHandler(request);
		});
}

function createTestsForProjectFolder(ctrl: vscode.TestController, parent: vscode.TestItem) {
	const outcomes = ["pass", "fail", "skip"];
	for (const outcome of outcomes) {
		const id = `${parent.label} ${outcome}`;
		const test = ctrl.createTestItem(id, id);
		ctrl.items.add(test);
		parent.children.add(test);
	}
}

function testRunHandler(ctrl: vscode.TestController) {
	// kick off each project folder test run async (i.e. in parallel)
	return async (request: vscode.TestRunRequest) => {
		for (const name of projectFolders) {
			const run = ctrl.createTestRun(request, name);
			const projectQueue = getProjectQueue(ctrl, name);
			ctrl.items.forEach(test => {if(test.id.startsWith(name + " ")) projectQueue.push(test);});
			projectQueue.forEach(test => run.enqueued(test));
			runProjectQueueAsync(run, projectQueue);
		}		
	};
}

async function runProjectQueueAsync(run:vscode.TestRun, projectQueue:vscode.TestItem[]) {
	for(const item of projectQueue) {
		// run queue sequentially
		if(run.token.isCancellationRequested)
			break;
		run.started(item);			
		await new Promise(r => setTimeout(r, Math.random() * 5000));
		switch(item.label.split(" ")[1]) {
			case "pass": run.passed(item); break;
			case "fail": run.failed(item, new vscode.TestMessage("failed")); break;
			case "skip": run.skipped(item); break;
		}
		run.appendOutput(item.label + " result updated\r\n", undefined, item);
	}
	await vscode.window.showInformationMessage(`all tests updated for ${run.name}. click OK to end run ${run.name}`, "OK");	
	run.end();
}

function getProjectQueue(ctrl:vscode.TestController, projectFolerName:string) {
	const pqItem = ctrl.items.get(projectFolerName);
	const queue: vscode.TestItem[] = [];
	pqItem?.children.forEach(c => queue.push(c));
	return queue;
}

Full repo for the above example is here, but note that the repo is basically a duplicate of the MS "test-provider-sample" except that extension.ts is replaced with the above code, so alternatively you can just copy/paste the above code into that file if you already have the MS repo locally.

@connor4312
Copy link
Member

connor4312 commented Apr 21, 2023

I really appreciated the detailed issue and reproduction here! I think there was an issue that was probably the same root cause from a while ago, but the reporter never provided a repro and I don't think I was doing the right steps that you've laid out here. (And I can't seem to find it right now.)

I'll get it fixed.

@connor4312 connor4312 added bug Issue identified by VS Code Team member as probable bug testing Built-in testing support labels Apr 21, 2023
@connor4312 connor4312 added this to the April 2023 milestone Apr 21, 2023
connor4312 added a commit that referenced this issue Apr 21, 2023
This is an old artifact that caused problems in the issue this fixes #180041

When we get a new 'task' from a test run request, we automatically
marked all tests as being enqueued with it. However, tests are now lazily
added to the test run states, so this would only affect tests that
_already_ had their state set to something (e.g. in another task). And
therefore it was also ineffective for its original purpose of marking
all included tests as being Queued, since extensions have had to do that
themselves anyway.

So just remove this code! Also, adjust priorities such that "skipped"
priorities are shown above unset ones.
connor4312 added a commit that referenced this issue Apr 24, 2023
Previously, test output was handled for an entire TestRunRequest into
a single stream. This didn't match what the public API implied, nor what
the real intentions were.

This makes output be stored correctly on a per-test run (called "tasks"
internally). It changes the order of the Test Results view so that tests
nested under their task, and also improves some of the tree handling
there to update nodes more specifically.

Clicking on the "terminal" button in the test view continues to show
output from the last test run request, but if there were multiple tasks,
the user is asked to choose which they want to view output for.

Finally I removed some old unused code that dealt with storing test
results on disk, which we no longer do, and moved to a simpler interface
instead.

Fixes #180041
connor4312 added a commit that referenced this issue Apr 24, 2023
…80746)

* testing: don't enqueue tests into tasks that are created

This is an old artifact that caused problems in the issue this fixes #180041

When we get a new 'task' from a test run request, we automatically
marked all tests as being enqueued with it. However, tests are now lazily
added to the test run states, so this would only affect tests that
_already_ had their state set to something (e.g. in another task). And
therefore it was also ineffective for its original purpose of marking
all included tests as being Queued, since extensions have had to do that
themselves anyway.

So just remove this code! Also, adjust priorities such that "skipped"
priorities are shown above unset ones.

* testing: tie test output correctly to runs, rework ui accordingly

Previously, test output was handled for an entire TestRunRequest into
a single stream. This didn't match what the public API implied, nor what
the real intentions were.

This makes output be stored correctly on a per-test run (called "tasks"
internally). It changes the order of the Test Results view so that tests
nested under their task, and also improves some of the tree handling
there to update nodes more specifically.

Clicking on the "terminal" button in the test view continues to show
output from the last test run request, but if there were multiple tasks,
the user is asked to choose which they want to view output for.

Finally I removed some old unused code that dealt with storing test
results on disk, which we no longer do, and moved to a simpler interface
instead.

Fixes #180041
@VSCodeTriageBot VSCodeTriageBot added unreleased Patch has not yet been released in VS Code Insiders insiders-released Patch has been released in VS Code Insiders and removed unreleased Patch has not yet been released in VS Code Insiders labels Apr 24, 2023
@TylerLeonhardt TylerLeonhardt added the author-verification-requested Issues potentially verifiable by issue author label Apr 28, 2023
@VSCodeTriageBot
Copy link
Collaborator

This bug has been fixed in the latest release of VS Code Insiders!

@jimasp, you can help us out by commenting /verified if things are now working as expected.

If things still don't seem right, please ensure you're on version d6290ef of Insiders (today's or later - you can use Help: About in the command palette to check), and leave a comment letting us know what isn't working as expected.

Happy Coding!

@lramos15
Copy link
Member

@connor4312 Any verification steps here? I copied the example code into the sample test provider as suggested and then ran the sample. I see this which doesn't seem right.

Image

@lramos15 lramos15 added the verification-steps-needed Steps to verify are needed for verification label Apr 28, 2023
@connor4312
Copy link
Member

Ah, yep, one more spot that needed nuking

@connor4312 connor4312 reopened this Apr 28, 2023
@connor4312 connor4312 modified the milestones: April 2023, May 2023 Apr 28, 2023
@connor4312 connor4312 removed the verification-steps-needed Steps to verify are needed for verification label Apr 28, 2023
@VSCodeTriageBot VSCodeTriageBot removed the insiders-released Patch has been released in VS Code Insiders label Apr 28, 2023
connor4312 added a commit that referenced this issue Apr 28, 2023
@VSCodeTriageBot VSCodeTriageBot added the unreleased Patch has not yet been released in VS Code Insiders label Apr 28, 2023
connor4312 added a commit that referenced this issue Apr 28, 2023
…181163)

* testing: another fix to avoid automatically queuing

Fixes #180041 again

* cli: only show other interactive attach commands when in a terminal

Fixes #178091
@jimasp
Copy link
Author

jimasp commented Apr 29, 2023

@connor4312 @lramos15

I've tried these changes (1.78.0-insider).

Are all the changes in 1.78.0-insider?

The good:

  • run.skipped no longer shows as not run
  • test run output is now separated in the terminal

The bad:

I still get the UI behaviour shown in the above gif, for example:

project 2 updates all tests -> project 2 test UI is not updated -> project 3 run is ended -> project 2 test UI is updated

i.e. I still don't understand why I have to run.end(project3) to get project2 to update its test results?

In an attempt to workaround this issue, I've tried using the modified code below.
This uses:

  • a separate TestController for each workspace folder
  • a separate runHandler for each workspace folder
  • a separate TestRunProfile for each workspace folder
  • a separate TestRun for each workspace folder (unchanged from previous code)

But this doesn't help. The behaviour is unchanged.
Tests are still stuck in a queued state until a different test run is ended, or until all test runs are ended.

What can I do to stop these test runs from blocking each other's test results?

Sidenote: this modified code is presumably the same in terms of vscode instance object isolation as would be the case with a separate extension acting on each folder, i.e. separate extensions can currently block each other's test run results.

// extension.ts

import * as vscode from 'vscode';

export function activate(context: vscode.ExtensionContext) {
  // simulate multiroot workspace with 3 project folders
  for (const name of ['project1', 'project2', 'project3']) {
    const ctrl = vscode.tests.createTestController(name, name);
    context.subscriptions.push(ctrl);
    const runHandler = testRunHandler(ctrl, name);
    createTestsForProjectFolder(ctrl);

    ctrl.createRunProfile(`Run Tests:${name}`, vscode.TestRunProfileKind.Run,
      async (request: vscode.TestRunRequest) => {
        await UI.clearTestResults();
        await runHandler(request);
      });
  }
}

function createTestsForProjectFolder(ctrl: vscode.TestController) {
  for (const outcome of ["pass", "fail", "skip"]) {
    ctrl.items.add(ctrl.createTestItem(outcome, outcome));
  }
}

function testRunHandler(ctrl: vscode.TestController, name: string) {
  return async (request: vscode.TestRunRequest) =>
    runProjectQueueAsync(ctrl.createTestRun(request, name), ctrl);
}

async function runProjectQueueAsync(run: vscode.TestRun, ctrl: vscode.TestController) {
  const projectQueue: vscode.TestItem[] = [];
  ctrl.items.forEach(c => projectQueue.push(c));

  for (const item of projectQueue) {
    // run queue sequentially
    if (run.token.isCancellationRequested)
      break;
    run.started(item);
    await new Promise(r => setTimeout(r, Math.random() * 5000));
    switch (item.label) {
      case "pass": run.passed(item); break;
      case "fail": run.failed(item, new vscode.TestMessage("failed")); break;
      case "skip": run.skipped(item); break;
    }
    run.appendOutput(item.label + " result updated\r\n", undefined, item);
  }

  await vscode.window.showInformationMessage(`\nAll tests have been updated for ${run.name}\n\nClick OK to call run.end() on ${run.name}'s TestRun`, { modal: true });
  run.end();
}


class UI {
  private static clearing = false;
  private constructor() {/**/ }
  static async clearTestResults() {
    // clear test UI results ONCE per TestRunRequest  (this is important when testing this bug, because otherwise you could be looking at the UI results of the previous run)
    if (!UI.clearing) {
      UI.clearing = true;
      await vscode.commands.executeCommand("testing.clearTestResults");
      UI.clearing = false;
    }
    while (UI.clearing) {
      await new Promise(r => setTimeout(r, 10));
    }
  }
}

updated gif with the above code running in 1.78.0-insider

in this gif, we can see that:

  • project1 does not update until project2's run is ended
  • project3 does not update until project1's run is ended

GIF

@VSCodeTriageBot VSCodeTriageBot added insiders-released Patch has been released in VS Code Insiders and removed unreleased Patch has not yet been released in VS Code Insiders labels May 3, 2023
@joyceerhl joyceerhl added the verified Verification succeeded label Jun 1, 2023
@connor4312
Copy link
Member

connor4312 commented Jun 1, 2023

Apologies, I missed the followup comment. Insiders builds happen during CET mornings Mon-Fri, and since this got merged on Friday the next build wasn't until the following Monday, which was after you commented. I've tried your updated code sample and it looks like the issue is fixed. Please let us know if you hit any other snags, and once again thank you for the very nice bug reports and repro steps!

@joyceerhl
Copy link
Contributor

Looks good now with the code from #180041 (comment)
image

@github-actions github-actions bot locked and limited conversation to collaborators Jun 12, 2023
daniel-wachira added a commit to trilogy-group/openvscode-server that referenced this issue Jul 6, 2023
* cli: add new control server messages for wsl (microsoft#180438)

* cli: add new control server messages for wsl

* support cwd in spawn

* use auth session id for sync when enabled by embedder (microsoft#180444)

* add plan-items to release notes section (microsoft#180445)

* Oops

* Render both debug frame indicator and breakpoint (microsoft#180448)

* clean up extension recommendations (microsoft#180450)

* clean up extension recommendations

* retain editor config extension

* Add API that exposes interactive session provider name (microsoft#180437)

* Add API that exposes interactive session provider name

* Update command label

* Suppress default text drop if there's also a uri list (microsoft#180452)

* Support markdown string

* Fix search result count again (microsoft#180453)

* Add comment

* Allow description map to be optional

* Add extension based tests

* Fix test

* Try

* Use custom node-gyp for SDL pipeline (microsoft#179723)

* Use custom node-gyp
* Avoid using relative cd
* Remove ia32 for Linux
* Bump gulp-atom-electron; unblocks downloading PDBs
* Add native-is-elevated to the scan

* Allow new codeblock actions to be shown at the top level of the toolbar (microsoft#180460)

* Make description optional when reading storage

* debug session: use queue to make sure debugee status get processed in correct order (microsoft#180410)

Similarly to fed69ad, this adds a queue to serialize the processing
of pause/continue events. Without this, if a pause and continue events
are sent really fast, the pause handler will take longer to process than
the continue handler and the state of the debugger UI will be paused
when the debuggee is actually running.

Fixes microsoft#180409

* No more raw IPC in the Issue Reporter (microsoft#180449)

This is the initial implementation of the issue reporter no longer having raw IPC calls in it.

I think there's plenty more to clean up, but this is a start...

cc @bpasero

cc @Tyriar if you wanna do this for the process explorer

* fix run selected text

* Fix Interactive Session widget role (microsoft#180463)

Fix Interactive Session widget

* cleanup save API (microsoft#180476)

* Revert "add accessibility verbosity settings for terminal and diff editor aria hints" (microsoft#180477)

* changed the weight to workbench contrib

* cancel code lens resolve requests when document is being edited (microsoft#180485)

https://github.com/microsoft/vscode-internalbacklog/issues/3884

* show commands only when having reply, proper type for different edit modes

* Fixes microsoft#3928 (microsoft#180404)

* Fixes microsoft#3928

* Fixes CI

* [debt] extract Session object which holds useful state for commands

* Fixes microsoft#153754. (microsoft#180490)

* Fixes microsoft#153754.

* Fixes microsoft#159479

* allow for default sash ratio in diff editor (side-by-side) and use it for inline diff'ing

* Fixes microsoft#173495 (microsoft#180492)

* Fix no tree view error when view is disposed during refresh (microsoft#180415)

Fixes microsoft/vscode-pull-request-github#4002

* add missing monaco.d.ts file

* Remove comments when a comment provider is unregistered (microsoft#180502)

Fixes microsoft/vscode-pull-request-github#4566

* Observed deriveds are now recomputed lazily. (microsoft#180487)

* Observed deriveds are now recomputed lazily.

* Fixes CI

* Fixes observable bug

* Fixes microsoft#173209 (microsoft#180505)

* Fixes accept next word bug

* Fixes microsoft#173209

* Don't dispose model in separate transactions, as deriveds are now computed lazily. (microsoft#180507)

* Fixes microsoft#180224 (microsoft#180511)

* in notebooks cancel inline chat sessions from sibling editors when starting a new session (microsoft#180509)

https://github.com/microsoft/vscode-internalbacklog/issues/3897

* extension host - allow to veto stopping (microsoft#179224) (microsoft#180513)

* changing the code so that view in chat is an additional button in the toolbar and the text appears below the toolbar

* adding the context key while waiting for the merge

* changing the css

* Improve selected row checkbox style (microsoft#180515)

Fixes microsoft#180506

* cleanup preview styles and keep status bar consistent (microsoft#180518)

* add `CTX_INTERACTIVE_EDITOR_LAST_RESPONSE_TYPE` and use that to control visiblity accept, cancel, and toggle inline action (microsoft#180517)

* add `CTX_INTERACTIVE_EDITOR_LAST_RESPONSE_TYPE` and use that to control visiblity accept, cancel, and toggle inline action

* fix compile errors

* cleaning the code

* cleaning the code

* Add command for expanding unresolved comments (microsoft#180521)

Fixes microsoft#169928

* adopt tunnel mutex name change (microsoft#180524)

* chore: update electron@22.4.8 (microsoft#180526)

* joh/passive barracuda (microsoft#180530)

* tweak inline diff editor options, make sure livePreview and notebooks is pretty

* tweak logging

* handle 403 and bail out immediately (microsoft#180547)

* Also wait for user data init

* wait only when init is required

* make sure rename disposes it `EditorStateCancellationTokenSource` so that its down-level context key is correctly updated (microsoft#180545)

this is part two of https://github.com/microsoft/vscode-internalbacklog/issues/3928

* Don't run chat codeblocks in task terminals (microsoft#180552)

* Add command/keybinding to change drop type (microsoft#180556)

* Add command/keybinding to change drop type

Adds a command/keybinding to toggle the post drop widget

* Also show keybinding

* Code review

* Fix drop widget having transparent background on hover (microsoft#180562)

We now overlay the button-secondaryHoverBackground over editor-widgetBackground

* Update distro

* Oops

* Iios

* Re microsoft#178715. Wait for notebook model to be ready for dispose (microsoft#180560)

* remove unnecessary ? (microsoft#180564)

* ensure focus is set correctly in output, enable keyboard scrolling for outputs

* report telemetry (microsoft#180567)

* Instrument Microsoft account type (microsoft#180573)

So we can see if folks are using MSA or AAD accounts. Also, this cleans up some dead code.

Fixes https://github.com/microsoft/vscode-internalbacklog/issues/3903

* Specify codeActionKinds (microsoft#180576)

Avoids extra calls and lets us show this info in the UI

* Also search injected text decorations tree for margin decorations (microsoft#180620)

* Also search injected text decorations tree for margin decorations

* Simplify fix

* quick access - allow a `Promise<FastAndSlowPicks<T>>` and adopt for commands (microsoft#180664)

* quick access - allow a `Promise<FastAndSlowPicks<T>>` and adopt for commands

* fix telemetry

* Change the way the InteractiveSessionModel is loaded into the widget (microsoft#180668)

* Change the way the InteractiveSessionModel is loaded into the widget
And the way viewState is managed. Fixes a bunch of general issues with this flow between views and editors

* Fix reloading editor after clear

* don't terminate IE session when observing outside edits (microsoft#180680)

Only when they earase everything cancel IE session, otherwise just live with it

* hide ghost text when invoking IE session (microsoft#180682)

https://github.com/microsoft/vscode-internalbacklog/issues/3573

* Fixes microsoft#180222 (microsoft#180681)

* Fixes microsoft#180538 (microsoft#180683)

* Fixes microsoft#180489 (microsoft#180684)

* add jsdoc comment for trackFocus (microsoft#180690)

* work in propgress, adding the fix for the feedback bug also

* Show hover message for diff revert arrow (microsoft#180378)

* fixes microsoft#177444 (microsoft#180704)

* prioritize images over text in accessiblity mode

* Fix microsoft#180588 (microsoft#180708)

* fix microsoft#180670

* cleaning the code

* split out event propagation handling

* using the toggle functionality instead

* pre saving the old data

* use editor options

* polishing the code

* remove true

* Allow negative numbers for `go to match` (microsoft#180479)

Fixes microsoft#180475

Also fixes the case where there are zero matches, which previously resulted in a non-functional quick input

* Pick up latest TS for building VS code (microsoft#180706)

* SCM - ActionBar rendering optimization (microsoft#180712)

* SCM - ActionBar rendering optimization

* address PR comments

---------

Co-authored-by: João Moreno <joao.moreno@microsoft.com>

* add some padding to MD message, restore right alignment of status label

* show accept/discard btns even when last response was a message response

* check the scroll height of the correct element

* Use readonly editor instead of an untitled buffer when showing environment changes

* Use view state to restore InteractiveSessionViewPane session by id (microsoft#180732)

* remove escape to container hotkey

* Organize Errors in GitHub Auth and make sure no double prompting happens (microsoft#180734)

* Organize Errors in GitHub Auth and make sure no double prompting happens

This mostly just moves some strings into variables... but this also fixes the GH Auth side of microsoft#180697 so you should only be asked once if you want to try a different way to log in.

* add comments

* Initial support for notebook CodeActions (microsoft#180740)

* support cmd codeActions on nb save

* add setting

* rm comment

* add log + add await command

* missed a space in setting description

* Improves observable docs

* fix class selection query

* fix message formatting

* fix: Double pasting in webview(using russian keyboard layout) (microsoft#161001) (microsoft#178120)

Co-authored-by: Matt Bierner <matb@microsoft.com>

* Use custom command to open JS doc links (microsoft#180737)

Fixes microsoft#162507

Prevents incorrect auto transform of the uri

* testing: tie test output correctly to runs, rework ui accordingly (microsoft#180746)

* testing: don't enqueue tests into tasks that are created

This is an old artifact that caused problems in the issue this fixes microsoft#180041

When we get a new 'task' from a test run request, we automatically
marked all tests as being enqueued with it. However, tests are now lazily
added to the test run states, so this would only affect tests that
_already_ had their state set to something (e.g. in another task). And
therefore it was also ineffective for its original purpose of marking
all included tests as being Queued, since extensions have had to do that
themselves anyway.

So just remove this code! Also, adjust priorities such that "skipped"
priorities are shown above unset ones.

* testing: tie test output correctly to runs, rework ui accordingly

Previously, test output was handled for an entire TestRunRequest into
a single stream. This didn't match what the public API implied, nor what
the real intentions were.

This makes output be stored correctly on a per-test run (called "tasks"
internally). It changes the order of the Test Results view so that tests
nested under their task, and also improves some of the tree handling
there to update nodes more specifically.

Clicking on the "terminal" button in the test view continues to show
output from the last test run request, but if there were multiple tasks,
the user is asked to choose which they want to view output for.

Finally I removed some old unused code that dealt with storing test
results on disk, which we no longer do, and moved to a simpler interface
instead.

Fixes microsoft#180041

* Apply buffer copy optimization to `updateOutput` oto (microsoft#180755)

For microsoft#168142

Follow up on 9fd77b4. Applies the same optimization to `updateOutput` as well

* Restore welcome message when restoring chat session (microsoft#180756)

* Change the shape of persisted sessions

* Also backup sessions that were not restored in this window

* Restore welcome message when restoring chat session

* add F20-F24 key support for keyboard shortcuts

* remove unused keyCodeOrd from key mappings list

* Feed 📓 error to interactive session. (microsoft#180766)

* Add command to show chat session history (microsoft#180770)

* testing: avoid including individual children in run at cursor if their parent is already included (microsoft#180763)

For #180760

* Add maximum number of persisted chat sessions (microsoft#180775)

* fix microsoft#180721

* build: quieter node module cache logging (microsoft#180709)

* Default Themes: Rename Experimental to Dark Modern (microsoft#180785)

Default Themes: Rename Experimental to Modern

* Merge user port changes with extension forwarded ports (microsoft#180694)

* Merge user port changes with extension forwards

* Actually add port to unrestoredExtensionTunnels

* nit

* context keys: fix: add serialize() support for ContextKeyNotRegexExpr

Fixes microsoft#180012

* update third party notices (microsoft#180788)

* Update ThirdPartyNotices.txt

* update distro

* new default theme: check setting when patching initial colors (microsoft#180687)

* new default theme: check setting when patching initial colors

* remove unneeded imports

* json/css/html: update dependencies (microsoft#180714)

* json/css/html: update dependencies

* update services

* add nls message to preserve link syntax (microsoft#180821)

* add lint rule to prevent type discrimination properties in API types (microsoft#180829)

re microsoft#63943 and other

* remove nb.codeactiononsave setting, add `nb.experimental` to command ID

* update wording

* cli: fix problem restarting tunnel with uppercase letter in name (microsoft#180881)

Fixes microsoft#180693

* Fix drop mime type wildcard regexp (microsoft#180883)

For microsoft#180878

* Disable breakpoint hint when a test loading icon is present (microsoft#180884)

* Add extra notes on `files` drop mime type (microsoft#180886)

Fixes microsoft#180878

* Fix enumItem labels (microsoft#180889)

`javascript.preferences.importModuleSpecifierEnding` and `typescript.preferences.importModuleSpecifierEnding` got out of sync here

* Fix markdown settings localization (microsoft#180891)

The syntax backtick hash str hash backtick was getting mangled.... but it probably should be extracted out so translators don't have the potential for changing it.

* Bump distro (microsoft#180895)

* Fix microsoft#180797. Fine tune edit mode switch. (microsoft#180900)

Fix microsoft#180797.

* Update terminal status even if it is already present

* Fix microsoft#180857. Empty cmd+f should not unset search keyword. (microsoft#180901)

* Fix microsoft#180861. Cell stays in editing mode if it is not modified by find. (microsoft#180902)

* API 💄 (microsoft#180911)

* more cursor overrides: style and blinking

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3864

* making the css selectable by changing the css file

* make sure to restore diff editor focus after repositioning the zone widget

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3964

* back to `computeHumanReadableDiff` diff

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3962

* simplify code for demo (microsoft#180932)

* disable inline completions for inline chat input

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3961

* disabe cmd/ctrl+z for "special undo" of inline chat

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3966

* don't show release notes on web (microsoft#180937)

fixes microsoft#179536

* Fix initial comment expand state (microsoft#180941)

Fixes microsoft#169928

* prevent endless autoSend loop of inline chat (microsoft#180945)

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3990

* "Show Next Change" doesn't show the right change (microsoft#180951)

Fixes microsoft#180744

* make sure EditModeStrategy#apply/cancel isn't called twice, keep reference onto editor model to prevent dispose before reset (microsoft#180952)

fixes https://github.com/microsoft/vscode-internalbacklog/issues/3963

* Enables experiments for diffEditor.diffAlgorithm (microsoft#180954)

* update distro (microsoft#180953)

* Fix typo in vscode.d.ts (microsoft#177377)

"of" -> "or"

Co-authored-by: Matt Bierner <matb@microsoft.com>

* fix multi range formatting (microsoft#180955)

fixes microsoft#178825

* update distro (microsoft#180957)

* Fix microsoft#177405. Treat error as plain text. (microsoft#180960)

* Fix microsoft#180290. Tweak wording accurately for install/enable missing extension. (microsoft#180961)

* Fix microsoft#163383 (microsoft#180963)

* Fix copying a suggested followup question in chat (microsoft#180965)

* add workspaceTrust to nb "codeaction" infra (microsoft#180968)

* Fix Issue Reporter API (microsoft#180971)

* Fix Issue Reporter API

CancellationTokens aren't hydrated over ProxyChannels so I've removed cancellation logic.

Additionally, there was a bad string compare that needed toLower when checking if an extension has a handler.

Additionally, added docs.

Fixes microsoft#180890
Fixes microsoft#180920
Fixes microsoft#180887

* remove import

* remove another import

* [json] update service (microsoft#180972)

* fix microsoft#180899

* Notification marker color turns grey when selected (microsoft#180973)

* Add mode to the notification (microsoft#180977)

ref microsoft#180803 (comment)

* Add overrideCategory back (microsoft#180975)

* Update getting started theme picker images to reflect new themes (microsoft#180976)

* Update getting started theme picker assets to reflect new themes

* Update theme names

* Fixes bug in observable utility

* Fixes microsoft#180792

* Fixes CI

* Update vscode.d.ts for clearSessionPreference (microsoft#180979)

Fixes microsoft#180860

* Use a colon instead of quotes to handle long queries better (microsoft#180980)

Fixes https://github.com/microsoft/vscode-internalbacklog/issues/4021

* fix microsoft#172465

* undo some changes

* Allow clicking to remove breakpoint even alongside non debug decorations (microsoft#180986)

* Load chat username/icon from current session, not persisted data (microsoft#180981)

* update distro (microsoft#180992)

* Avoid double encoding vscode.dev links (microsoft#181002)

* Fixes microsoft#181007 (microsoft#181008)

* Fixes microsoft#181009 (microsoft#181011)

* Fixes microsoft#181009

* Use isMeasurement: true for boolean

* Use correct key for hybrid port unforwarding (microsoft#181005)

* Use correct key for hybrid port unforwarding

* Use forwarded host for closing

* Delete key from this.autoForwarded

* Adds telemetry to understand how long the diff editor was visible to the user. (microsoft#181021)

* Adds telemetry to understand how long the diff editor was visible to the user.

* Uses StopWatch utility.

* Fixes CI

* 💄

* 💄

---------

Co-authored-by: Benjamin Pasero <benjamin.pasero@gmail.com>

* enable live preview for last line of document. for that... (microsoft#181029)

- support `ordinal` and `showInHiddenAreas` for `IViewZone`
- adopt in zoneWidget
- adopt for inline chat widgets
- remove code that isn't needed anymore 👯‍♂️

fixes https://github.com/microsoft/vscode-internalbacklog/issues/4024

* fix microsoft#175014

* fix tab order for hidden status element when a message shows

fixes https://github.com/microsoft/vscode-internalbacklog/issues/4039

* don't use role or aria-label attributes so that contents get read out

fixes https://github.com/microsoft/vscode-internalbacklog/issues/4035

* Add a couple teammates to my-endgame notebook (microsoft#181059)

* Add a couple teammates to my-endgame notebook

friends :)

* Add @Yoyokrazy

* Add @paulacamargo25

* debug: bump js-debug (microsoft#181049)

Fixes microsoft#181047

* Revert "Fix: diff editor arrow click enables breakpoint " (microsoft#181040)

* Set glyph margin decoration width appropriately (microsoft#181071)

* Move opening default built-in walkthrough to after built-in walkthrough initialization (microsoft#181066)

* chore: bump distro (microsoft#181104)

* Unexpected theme name showing up in web (microsoft#181091)

* Unexpected theme name showing up in web

* incorperate feedback

* Install extension in the right server (microsoft#181110)

* Fixes `PieceTreeBase.equal` (microsoft#181125)

Fixes `PieceTreeBase.equal` (fixes microsoft/vscode-internalbacklog#4025)

* Revert "Fixes `PieceTreeBase.equal` (microsoft#181125)" (microsoft#181270)

This reverts commit 3862229.

* cli: tunnels can sporadically become unresponsive (microsoft#181286)

Last iteration I moved some RPC logic to use Tokios "codecs" to give
them cancellation safety. These operate on streams of input data.

While this worked at first, I failed to take into account that the byte
buffer we read from the stream could have _more_ data than just the
current message under load scenarios. We were discarding any extra data
from the subsequent message. In most cases caused the next message
"length" to be read from the middle of the next message, which usually
(when parsed as a u32) was some number of gigabytes, then causing the
connection to stall forever.

Fixes microsoft#181284

* Add temporary nodeJS walkthrough (microsoft#181442)

* bump version

* unc - adopt setting and handling of allow list (gitpod-io#5)

* unc - adopt setting and handling of allow list

* unc - set allow list on server too

* unc - pick our patched node.js for now

* bump electron

* unc - ignore sync is not needed with machine scope

* unc - use process set directly

* 🆙 22.5.1

* code web server initial commit

* Don't test the Feedback component

* enable prebuilds for all branches

* Add example guide for pre-installing vscode extensions with docker installation

* 💄

* Update deprecated example in README 

Option 'connection-secret' is deprecated: Use connection-token-file instead.

* Fix default image destroyed in merge

* Port the delayed signal patch to gp-code-1.78

* Fix build

* Remove access token requirement as we're running in a sandbox

* Revert "Remove access token requirement as we're running in a sandbox"

This reverts commit 8a7a90c.
Use the --without-connection-token arg instead

---------

Co-authored-by: Connor Peet <connor@peet.io>
Co-authored-by: Sandeep Somavarapu <sasomava@microsoft.com>
Co-authored-by: First <karraj@microsoft.com>
Co-authored-by: Joyce Er <joyce.er@microsoft.com>
Co-authored-by: Rob Lourens <roblourens@gmail.com>
Co-authored-by: Matt Bierner <matb@microsoft.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
Co-authored-by: Florent Revest <revestflo@gmail.com>
Co-authored-by: Tyler James Leonhardt <me@tylerleonhardt.com>
Co-authored-by: Megan Rogge <merogge@microsoft.com>
Co-authored-by: Johannes Rieken <johannes.rieken@gmail.com>
Co-authored-by: Benjamin Pasero <benjamin.pasero@microsoft.com>
Co-authored-by: Alexandru Dima <alexdima@microsoft.com>
Co-authored-by: Aiday Marlen Kyzy <amarlenkyzy@microsoft.com>
Co-authored-by: Henning Dieterichs <hdieterichs@microsoft.com>
Co-authored-by: Alex Ross <alros@microsoft.com>
Co-authored-by: Martin Aeschlimann <martinae@microsoft.com>
Co-authored-by: Robo <hop2deep@gmail.com>
Co-authored-by: Peng Lyu <penn.lv@gmail.com>
Co-authored-by: aamunger <aamunger@microsoft.com>
Co-authored-by: João Moreno <joao.moreno@microsoft.com>
Co-authored-by: meganrogge <megan.rogge@microsoft.com>
Co-authored-by: Ladislau Szomoru <3372902+lszomoru@users.noreply.github.com>
Co-authored-by: Michael Lively <milively@microsoft.com>
Co-authored-by: dongfang <wb.yindongfang@mesg.corp.netease.com>
Co-authored-by: Ilia Pozdnyakov <ilia.pozdnyakov@ya.ru>
Co-authored-by: Ulugbek Abdullaev <ulugbekna@gmail.com>
Co-authored-by: Lakshya A Agrawal <lakshya18242@iiitd.ac.in>
Co-authored-by: Bhavya U <bhavyau@microsoft.com>
Co-authored-by: David Dossett <ddossett@microsoft.com>
Co-authored-by: SteVen Batten <steven.m.batten@outlook.com>
Co-authored-by: Benjamin Pasero <benjamin.pasero@gmail.com>
Co-authored-by: Filip Troníček <filip@gitpod.io>
Co-authored-by: Anton Kosyakov <anton@gitpod.io>
Co-authored-by: AXON <axonasif@gmail.com>
Co-authored-by: Jean Pierre <jeanp413@hotmail.com>
Co-authored-by: Bjarne Sievers <jellyfishcoding@live.de>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
author-verification-requested Issues potentially verifiable by issue author bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders testing Built-in testing support verified Verification succeeded
Projects
None yet
6 participants