Skip to content

Commit

Permalink
[Predictor] Removing Survey (Azure#19268)
Browse files Browse the repository at this point in the history
Co-authored-by: Juan Aguirre <[email protected]>
  • Loading branch information
jjaguirre394 and Juan Aguirre authored Aug 19, 2022
1 parent 620c548 commit cd2adc5
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 160 deletions.
13 changes: 0 additions & 13 deletions tools/Az.Tools.Predictor/Az.Tools.Predictor/AzPredictor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ private struct ParsedCommandLineHistory

private List<IDisposable> _externalDisposableObjects = new List<IDisposable>();

private ISurveyHelper _surveyHelper;
private PowerShellRuntime _powerShellRuntime;

private bool _isInitialized;
Expand All @@ -88,7 +87,6 @@ private struct ParsedCommandLineHistory
public AzPredictor()
{
_powerShellRuntime = new PowerShellRuntime();
_surveyHelper = new AzPredictorSurveyHelper(_powerShellRuntime);

// To make import-module fast, we'll do all the initialization in a task.
// Slow initialization may make opening a PowerShell window slow if "Import-Module" is added to the user's profile.
Expand Down Expand Up @@ -134,12 +132,6 @@ public void Dispose()
_predictionRequestCancellationSource = null;
}

if (_surveyHelper is IDisposable disposableSurveyHelper)
{
disposableSurveyHelper.Dispose();
_surveyHelper = null;
}

if (_powerShellRuntime != null)
{
_powerShellRuntime.Dispose();
Expand Down Expand Up @@ -287,11 +279,6 @@ public void OnCommandLineExecuted(PredictionClient client, string commandLine, b
parsedResult = GetAstAndMaskedCommandLine(commandLine);
}

if (parsedResult.IsSupported && _surveyHelper?.ShouldPromptSurvey() == true)
{
_surveyHelper.PromptSurvey();
}

_telemetryClient.OnHistory(new HistoryTelemetryData(client, parsedResult.MaskedCommandLine ?? AzPredictorConstants.CommandPlaceholder, success));
_commandLineExecutedCompletion?.SetResult();
});
Expand Down
115 changes: 0 additions & 115 deletions tools/Az.Tools.Predictor/Az.Tools.Predictor/AzPredictorSurveyHelper.cs

This file was deleted.

32 changes: 0 additions & 32 deletions tools/Az.Tools.Predictor/Az.Tools.Predictor/ISurveyHelper.cs

This file was deleted.

0 comments on commit cd2adc5

Please sign in to comment.