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

Make CTRL signal able to take multiple contexts #1172

Merged
merged 2 commits into from
Jun 16, 2021

Conversation

JohnMcPMS
Copy link
Member

@JohnMcPMS JohnMcPMS commented Jun 16, 2021

Related to #1009 , fixes one of the problems but there are many listed.

Change

Update the CTRL signal handler to be able to fan out to multiple contexts, and make all cases of using sub-contexts both connected to the signal handler and better handle cancellation.

Additionally, improve the COM API install method to properly cancel any in progress task rather than just terminating the context.

Validation

Manually ensured that CTRL+C cancels various multi-step commands.

Microsoft Reviewers: Open in CodeFlow

…nces of subcontexts to it. Also handle cancellation during looped subcontext usage.
@JohnMcPMS JohnMcPMS requested a review from a team as a code owner June 16, 2021 01:05
@github-actions
Copy link

Misspellings found, please review:

  • subcontext
To accept these changes, run the following commands from this repository on this branch
pushd $(git rev-parse --show-toplevel)
perl -e '
my @expect_files=qw('".github/actions/spelling/expect.txt"');
@ARGV=@expect_files;
my @stale=qw('"abifind bcp cdn CLSID combaseapi compschema cppwinrtprocess Debian Globals google IApp idl IFind IGet iinstall INET Langs MIDL oss Packageend pseudocode REINSTALLMODE smartscreen sourc Standalone vamus Wunused Xaml "');
my $re=join "|", @stale;
my $suffix=".".time();
my $previous="";
sub maybe_unlink { unlink($_[0]) if $_[0]; }
while (<>) {
  if ($ARGV ne $old_argv) { maybe_unlink($previous); $previous="$ARGV$suffix"; rename($ARGV, $previous); open(ARGV_OUT, ">$ARGV"); select(ARGV_OUT); $old_argv = $ARGV; }
  next if /^(?:$re)(?:(?:\r|\n)*$| .*)/; print;
}; maybe_unlink($previous);'
perl -e '
my $new_expect_file=".github/actions/spelling/expect.txt";
use File::Path qw(make_path);
make_path ".github/actions/spelling";
open FILE, q{<}, $new_expect_file; chomp(my @words = <FILE>); close FILE;
my @add=qw('"clsid debian globals inet langs midl standalone subcontext "');
my %items; @items{@words} = @words x (1); @items{@add} = @add x (1);
@words = sort {lc($a) cmp lc($b)} keys %items;
open FILE, q{>}, $new_expect_file; for my $word (@words) { print FILE "$word\n" if $word =~ /\w/; };
close FILE;'
popd

Copy link
Contributor

@yao-msft yao-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@JohnMcPMS JohnMcPMS merged commit e03eb11 into microsoft:master Jun 16, 2021
@JohnMcPMS JohnMcPMS deleted the multictrl branch June 16, 2021 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants