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

[main] Update dependencies from dotnet/arcade #8698

Merged
merged 9 commits into from
Feb 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@
</Dependency>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="10.0.0-beta.25074.4">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="10.0.0-beta.25080.7">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>e89f8b1239360cafca490aa3bfee89e84df72186</Sha>
<Sha>bbea86c614fcf4380c58c80eacd279a0b8305a79</Sha>
</Dependency>
<!-- Intermediate is necessary for source build. -->
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="10.0.0-beta.25074.4">
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="10.0.0-beta.25080.7">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>e89f8b1239360cafca490aa3bfee89e84df72186</Sha>
<Sha>bbea86c614fcf4380c58c80eacd279a0b8305a79</Sha>
<SourceBuild RepoName="arcade" ManagedOnly="true" />
</Dependency>
<!-- Dependencies required for source build. We'll still update manually -->
Expand Down
6 changes: 3 additions & 3 deletions eng/common/native/install-dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ case "$os" in
apt update

apt install -y build-essential gettext locales cmake llvm clang lld lldb liblldb-dev libunwind8-dev libicu-dev liblttng-ust-dev \
libssl-dev libkrb5-dev zlib1g-dev pigz cpio
libssl-dev libkrb5-dev pigz cpio

localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
elif [ "$ID" = "fedora" ] || [ "$ID" = "rhel" ]; then
dnf install -y cmake llvm lld lldb clang python curl libicu-devel openssl-devel krb5-devel zlib-devel lttng-ust-devel pigz cpio
dnf install -y cmake llvm lld lldb clang python curl libicu-devel openssl-devel krb5-devel lttng-ust-devel pigz cpio
elif [ "$ID" = "alpine" ]; then
apk add build-base cmake bash curl clang llvm-dev lld lldb krb5-dev lttng-ust-dev icu-dev zlib-dev openssl-dev pigz cpio
apk add build-base cmake bash curl clang llvm-dev lld lldb krb5-dev lttng-ust-dev icu-dev openssl-dev pigz cpio
else
echo "Unsupported distro. distro: $ID"
exit 1
Expand Down
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"tools": {
"dotnet": "10.0.100-alpha.1.25064.3"
"dotnet": "10.0.100-alpha.1.25077.2"
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "10.0.0-beta.25074.4"
"Microsoft.DotNet.Arcade.Sdk": "10.0.0-beta.25080.7"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -113,19 +113,19 @@ public DateTime LastChangeTime
public string? Reserved
{
get => Details.TryGetValue(ReservedKey, out string reserved) ? reserved : false.ToString();
set => UpdateOrRemoveValue(Details, ReservedKey, value, (string entry) => !string.IsNullOrEmpty(entry));
set => UpdateOrRemoveValue(Details, ReservedKey, value, (entry) => !string.IsNullOrEmpty(entry));
}

public string? Author
{
get => Details.TryGetValue(AuthorKey, out string author) ? author : null;
set => UpdateOrRemoveValue(Details, AuthorKey, value, (string entry) => !string.IsNullOrEmpty(entry));
set => UpdateOrRemoveValue(Details, AuthorKey, value, (entry) => !string.IsNullOrEmpty(entry));
}

public string? Owners
{
get => Details.TryGetValue(OwnersKey, out string owners) ? owners : null;
set => UpdateOrRemoveValue(Details, OwnersKey, value, (string entry) => !string.IsNullOrEmpty(entry));
set => UpdateOrRemoveValue(Details, OwnersKey, value, (entry) => !string.IsNullOrEmpty(entry));
}

public bool IsLocalPackage
Expand All @@ -138,19 +138,19 @@ public bool IsLocalPackage
}
return false;
}
set => UpdateOrRemoveValue(Details, LocalPackageKey, value.ToString(), (string value) => value == true.ToString());
set => UpdateOrRemoveValue(Details, LocalPackageKey, value.ToString(), (value) => value == true.ToString());
}

public string? NuGetSource
{
get => Details.TryGetValue(NuGetSourceKey, out string nugetSource) ? nugetSource : null;
set => UpdateOrRemoveValue(Details, NuGetSourceKey, value, (string entry) => !string.IsNullOrEmpty(entry));
set => UpdateOrRemoveValue(Details, NuGetSourceKey, value, (entry) => !string.IsNullOrEmpty(entry));
}

public string? Version
{
get => Details.TryGetValue(PackageVersionKey, out string version) ? version : null;
set => UpdateOrRemoveValue(Details, PackageVersionKey, value, (string entry) => !string.IsNullOrEmpty(entry));
set => UpdateOrRemoveValue(Details, PackageVersionKey, value, (entry) => !string.IsNullOrEmpty(entry));
}

internal Dictionary<string, string> Details { get; }
Expand All @@ -169,10 +169,10 @@ public IReadOnlyDictionary<string, string> GetDetails()
{
var details = new Dictionary<string, string>();

details.TryAdd(AuthorKey, Author ?? string.Empty, (string entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(OwnersKey, Owners ?? string.Empty, (string entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(ReservedKey, Reserved ?? string.Empty, (string entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(NuGetSourceKey, NuGetSource ?? string.Empty, (string entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(AuthorKey, Author ?? string.Empty, (entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(OwnersKey, Owners ?? string.Empty, (entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(ReservedKey, Reserved ?? string.Empty, (entry) => !string.IsNullOrEmpty(entry));
details.TryAdd(NuGetSourceKey, NuGetSource ?? string.Empty, (entry) => !string.IsNullOrEmpty(entry));

return details;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ private async Task<TemplateCache> UpdateTemplateCacheAsync(bool needsRebuild, Ca
}

var scanResults = new ScanResult?[allTemplatePackages.Count];
Parallel.For(0, allTemplatePackages.Count, async (int index) =>
Parallel.For(0, allTemplatePackages.Count, async (index) =>
{
try
{
Expand Down
8 changes: 4 additions & 4 deletions src/Microsoft.TemplateEngine.Edge/ValidationUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,10 @@ private static void LogValidationEntries(ILogger logger, string header, IReadOnl
{
Action<string> log = severity switch
{
IValidationEntry.SeverityLevel.None => (string s) => throw new NotSupportedException($"{IValidationEntry.SeverityLevel.None} severity is not supported."),
IValidationEntry.SeverityLevel.Info => (string s) => logger.LogDebug(s),
IValidationEntry.SeverityLevel.Warning => (string s) => logger.LogWarning(s),
IValidationEntry.SeverityLevel.Error => (string s) => logger.LogError(s),
IValidationEntry.SeverityLevel.None => (s) => throw new NotSupportedException($"{IValidationEntry.SeverityLevel.None} severity is not supported."),
IValidationEntry.SeverityLevel.Info => (s) => logger.LogDebug(s),
IValidationEntry.SeverityLevel.Warning => (s) => logger.LogWarning(s),
IValidationEntry.SeverityLevel.Error => (s) => logger.LogError(s),
_ => throw new InvalidOperationException($"{severity} is not expected value for {nameof(IValidationEntry.SeverityLevel)}."),
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ public void VerifyConsumeWholeLine()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.ConsumeWholeLine(ref length, ref position);
return 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public void VerifyTrimWhitespaceForward()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.TrimWhitespace(true, false, ref length, ref position);
return 0;
Expand All @@ -50,7 +50,7 @@ public void VerifyTrimWhitespaceBackward()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.TrimWhitespace(false, true, ref length, ref position);
return 0;
Expand All @@ -75,7 +75,7 @@ public void VerifyTrimWhitespaceBothDirections()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.TrimWhitespace(true, true, ref length, ref position);
return 0;
Expand All @@ -100,7 +100,7 @@ public void VerifyTrimWhitespaceNeitherDirection()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.TrimWhitespace(false, false, ref length, ref position);
return 0;
Expand All @@ -125,7 +125,7 @@ public void VerifyConsumeWholeLine()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.ConsumeWholeLine(ref length, ref position);
return 0;
Expand Down Expand Up @@ -158,7 +158,7 @@ public void VerifyWhitespaceHandlerConsumeWholeLine(bool trim, bool trimForward,
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.WhitespaceHandler(ref length, ref position, true, trim, trimForward, trimBackward);
return 0;
Expand Down Expand Up @@ -187,7 +187,7 @@ public void VerifyWhitespaceHandlerTrim(bool trimForward, bool trimBackward)
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.WhitespaceHandler(ref length, ref position, false, true, trimForward, trimBackward);
return 0;
Expand All @@ -213,7 +213,7 @@ public void VerifyWhitespaceHandlerTrimForwardButNotBack()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.WhitespaceHandler(ref length, ref position, false, false, true, false);
return 0;
Expand All @@ -238,7 +238,7 @@ public void VerifyWhitespaceHandlerTrimBackButNotForward()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.WhitespaceHandler(ref length, ref position, false, false, false, true);
return 0;
Expand All @@ -263,7 +263,7 @@ public void VerifyWhitespaceHandlerTrimBackAndForward()
{
MockOperation o = new MockOperation(
null,
(IProcessorState state, int length, ref int position, int token) =>
(state, length, ref position, token) =>
{
state.WhitespaceHandler(ref length, ref position, false, false, true, true);
return 0;
Expand Down
8 changes: 4 additions & 4 deletions test/Microsoft.TemplateEngine.Core.UnitTests/TrieTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public void VerifyThatTrieMatchesAtTheBeginning()
new MockOperationProvider(
new MockOperation(
null,
(IProcessorState processor, int bufferLength, ref int currentBufferPosition, int token) =>
(processor, bufferLength, ref currentBufferPosition, token) =>
{
testActivated = true;
return 0;
Expand Down Expand Up @@ -58,7 +58,7 @@ public void VerifyThatTrieMatchesAtTheEnd()
new MockOperationProvider(
new MockOperation(
null,
(IProcessorState processor, int bufferLength, ref int currentBufferPosition, int token) =>
(processor, bufferLength, ref currentBufferPosition, token) =>
{
testActivated = true;
return 0;
Expand All @@ -83,7 +83,7 @@ public void VerifyThatTrieMatchesInTheInterior()
new MockOperationProvider(
new MockOperation(
null,
(IProcessorState processor, int bufferLength, ref int currentBufferPosition, int token) =>
(processor, bufferLength, ref currentBufferPosition, token) =>
{
testActivated = true;
return 0;
Expand All @@ -108,7 +108,7 @@ public void VerifyThatTrieMatchesAsTheWholeContents()
new MockOperationProvider(
new MockOperation(
null,
(IProcessorState processor, int bufferLength, ref int currentBufferPosition, int token) =>
(processor, bufferLength, ref currentBufferPosition, token) =>
{
testActivated = true;
return 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ public TemplateDiscoveryCommand() : base("template-discovery", "Generates the te
Options.Add(_diffOverrideNonPackagesOption);

TreatUnmatchedTokensAsErrors = true;
SetAction(async (ParseResult parseResult, CancellationToken cancellationToken) =>
SetAction(async (parseResult, cancellationToken) =>
{
var config = new CommandArgs(parseResult.GetValue(_basePathOption) ?? throw new Exception("Output path is not set"))
{
Expand Down
Loading