Merged PR 10798: Update dependencies needed by Azure PowerShell and patch for Newtonsoft.Json

This commit is contained in:
Aditya Patwardhan
2020-01-23 01:29:34 +00:00
parent 3e28403c20
commit e35a4654dd
6 changed files with 29 additions and 15 deletions
+18
View File
@@ -408,6 +408,24 @@ Fix steps:
}
New-Item -Path $refDestFolder -ItemType Directory -Force -ErrorAction Stop > $null
Copy-Item -Path $refAssemblies -Destination $refDestFolder -Force -ErrorAction Stop
## We need to explicitly add these assemblies which ship with netcoreapp runtime, but we use a higher version in the modules.
$assembliesToAdd = @(
"System.Diagnostics.DiagnosticSource.dll"
)
# Get path to the reference dlls.
$netCoreAppRefAssembliesPath = Get-Content -Path $incFileName | Where-Object { $_ -like "*microsoft.netcore.app*netstandard.dll;" } | ForEach-Object { $_.TrimEnd(';') } | Split-Path -Parent
foreach ($assembly in $assembliesToAdd) {
$srcPath = Join-Path $netCoreAppRefAssembliesPath $assembly
if (Test-Path $srcPath) {
Copy-Item -Path $srcPath -Destination $refDestFolder -Force -ErrorAction Stop
} else {
throw "Expected assembly was not found: $srcPath"
}
}
} finally {
Pop-Location
}
@@ -9,7 +9,7 @@
<ItemGroup>
<ProjectReference Include="..\System.Management.Automation\System.Management.Automation.csproj" />
<!-- the following package(s) are from https://github.com/microsoft/applicationinsights-??? -->
<PackageReference Include="Microsoft.ApplicationInsights" Version="2.10.0" />
<PackageReference Include="Microsoft.ApplicationInsights" Version="2.12.0" />
</ItemGroup>
<PropertyGroup>
@@ -31,12 +31,6 @@ namespace Microsoft.PowerShell
// PSCoreInsight2 telemetry key
private const string _psCoreTelemetryKey = "ee4b2115-d347-47b0-adb6-b19c2c763808";
static ApplicationInsightsTelemetry()
{
TelemetryConfiguration.Active.InstrumentationKey = _psCoreTelemetryKey;
TelemetryConfiguration.Active.TelemetryChannel.DeveloperMode = _developerMode;
}
private static bool GetEnvironmentVariableAsBool(string name, bool defaultValue) {
var str = Environment.GetEnvironmentVariable(name);
if (string.IsNullOrEmpty(str))
@@ -75,7 +69,13 @@ namespace Microsoft.PowerShell
if (_telemetryClient == null)
{
_telemetryClient = new TelemetryClient();
TelemetryConfiguration configuration = TelemetryConfiguration.CreateDefault();
configuration.InstrumentationKey = _psCoreTelemetryKey;
// Set this to true to reduce latency during development
configuration.TelemetryChannel.DeveloperMode = _developerMode;
_telemetryClient = new TelemetryClient(configuration);
}
_telemetryClient.TrackEvent(eventName, payload, null);
@@ -20,7 +20,7 @@
<!-- the following package(s) are from https://github.com/dotnet/corefx -->
<PackageReference Include="System.IO.Packaging" Version="4.5.0" />
<PackageReference Include="System.Net.Http.WinHttpHandler" Version="4.5.4" />
<PackageReference Include="System.Text.Encodings.Web" Version="4.5.0" />
<PackageReference Include="System.Text.Encodings.Web" Version="4.7.0" />
<!-- the following package(s) are from https://github.com/dotnet/wcf -->
<PackageReference Include="System.ServiceModel.Duplex" Version="4.5.3" />
<PackageReference Include="System.ServiceModel.Http" Version="4.5.3" />
@@ -9,14 +9,14 @@
<ItemGroup>
<ProjectReference Include="..\Microsoft.PowerShell.CoreCLR.Eventing\Microsoft.PowerShell.CoreCLR.Eventing.csproj" />
<!-- the following package(s) are from https://github.com/JamesNK/Newtonsoft.Json -->
<PackageReference Include="Newtonsoft.Json" Version="12.0.2" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
<!-- the following package(s) are from https://github.com/dotnet/corefx -->
<PackageReference Include="Microsoft.Win32.Registry.AccessControl" Version="4.5.0" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="4.5.0" />
<PackageReference Include="System.DirectoryServices" Version="4.5.0" />
<PackageReference Include="System.IO.FileSystem.AccessControl" Version="4.5.0" />
<PackageReference Include="System.Management" Version="4.5.0" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="4.5.2" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="4.7.0" />
<PackageReference Include="System.Security.AccessControl" Version="4.5.0" />
<PackageReference Include="System.Security.Cryptography.Pkcs" Version="4.5.2" />
<PackageReference Include="System.Security.Permissions" Version="4.5.0" />
-4
View File
@@ -4,7 +4,6 @@
Describe "Validate start of console host" -Tag CI {
BeforeAll {
$allowedAssemblies = @(
'Microsoft.ApplicationInsights.dll'
'Microsoft.Management.Infrastructure.dll'
'Microsoft.PowerShell.ConsoleHost.dll'
'Microsoft.PowerShell.Security.dll'
@@ -43,7 +42,6 @@ Describe "Validate start of console host" -Tag CI {
'System.Private.CoreLib.dll'
'System.Private.Uri.dll'
'System.Private.Xml.dll'
'System.Private.Xml.Linq.dll'
'System.Reflection.Emit.ILGeneration.dll'
'System.Reflection.Emit.Lightweight.dll'
'System.Reflection.Primitives.dll'
@@ -68,9 +66,7 @@ Describe "Validate start of console host" -Tag CI {
'System.Threading.Tasks.dll'
'System.Threading.Tasks.Parallel.dll'
'System.Threading.Thread.dll'
'System.Threading.Timer.dll'
'System.Xml.ReaderWriter.dll'
'System.Xml.XDocument.dll'
)
if ($IsWindows) {