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

Add Ubuntu 24.10 image #111504

Merged
merged 4 commits into from
Jan 21, 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
2 changes: 1 addition & 1 deletion eng/pipelines/libraries/helix-queues-setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:

# Linux arm64
- ${{ if eq(parameters.platform, 'linux_arm64') }}:
- (Ubuntu.2204.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:ubuntu-22.04-helix-arm64v8
- (Ubuntu.2410.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:ubuntu-24.10-helix-arm64v8
Copy link
Member

@filipnavara filipnavara Jan 20, 2025

Choose a reason for hiding this comment

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

Could someone enlighten me about the naming scheme? I am bit confused about Ubuntu 24.10 still having Ubuntu.2204.ArmArch.Open in the name. (Same for the other entries.)

Copy link
Member

Choose a reason for hiding this comment

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

This is Ubuntu 24.10 container running on Ubuntu 22.04 physical machine (ie the kernel is from Ubuntu 22.04).

Copy link
Member

Choose a reason for hiding this comment

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

Thanks!

Copy link
Member

Choose a reason for hiding this comment

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

this comes from "fixes" we put in for #67353 @filipnavara.
Do you want to disable the test as part of this PR @richlander?
NTLM was broken on Ubuntu for a while and it seems like it is finally fixed.

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't have context to make that decision. Can you elaborate?

Copy link
Member

Choose a reason for hiding this comment

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

@tarekgh already pushed the change @richlander. No need to worry. We will make proper change later after more testing on new images.

Copy link
Member Author

Choose a reason for hiding this comment

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

Sounds good. I will be bringing in Debian 13, shortly. 24.10 will be replaced by 25.04 before long. My intent is to keep us closer to tip.

- ${{ if or(ne(parameters.jobParameters.isExtraPlatformsBuild, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- (Debian.12.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:debian-12-helix-arm64v8

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public static partial class PlatformDetection
public static bool IsOpenSUSE => IsDistroAndVersion("opensuse");
public static bool IsUbuntu => IsDistroAndVersion("ubuntu");
public static bool IsUbuntu2004 => IsDistroAndVersion("ubuntu", 20, 4);
public static bool IsUbuntu24 => IsDistroAndVersion("ubuntu", 24);
public static bool IsDebian => IsDistroAndVersion("debian");
public static bool IsAlpine => IsDistroAndVersion("alpine");
public static bool IsRaspbian10 => IsDistroAndVersion("raspbian", 10);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ public void Package_Supported_NTLM()
}

[ConditionalFact(nameof(IsNtlmUnavailable))]
[ActiveIssue("https://github.com/dotnet/runtime/issues/111639", typeof(PlatformDetection), nameof(PlatformDetection.IsUbuntu24))]
public void Package_Unsupported_NTLM()
{
NegotiateAuthenticationClientOptions clientOptions = new NegotiateAuthenticationClientOptions { Package = "NTLM", Credential = s_testCredentialRight, TargetName = "HTTP/foo" };
Expand Down Expand Up @@ -274,7 +275,7 @@ public void NtlmSignatureTest()
fakeNtlmServer.Unwrap(output.WrittenSpan, temp);
Assert.Equal(s_Hello, temp);

// Test creating signature on server side and decoding it with VerifySignature on client side
// Test creating signature on server side and decoding it with VerifySignature on client side
byte[] serverSignedMessage = new byte[16 + s_Hello.Length];
fakeNtlmServer.Wrap(s_Hello, serverSignedMessage);
output.Clear();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2434,12 +2434,31 @@ public static IEnumerable<object[]> SystemTimeZonesTestData()
}
}

// In recent Linux distros like Ubuntu 24.04, removed the legacy Time Zone names and not mapping it any more. User can still have a way to install it if they need to.
// UCT is one of the legacy aliases for UTC which we use here to detect if the legacy names is support at the runtime.
// https://discourse.ubuntu.com/t/ubuntu-24-04-lts-noble-numbat-release-notes/39890#p-99950-tzdata-package-split
private static bool SupportLegacyTimeZoneNames { get; } = IsSupportedLegacyTimeZones();
private static bool IsSupportedLegacyTimeZones()
{
try
{
TimeZoneInfo.FindSystemTimeZoneById("UCT");
}
catch (TimeZoneNotFoundException)
{
return false;
}

return true;
}

[GeneratedRegex(@"^(?:[A-Z][A-Za-z]+|[+-]\d{2}|[+-]\d{4})$")]
private static partial Regex IanaAbbreviationRegex { get; }

// UTC aliases per https://github.com/unicode-org/cldr/blob/master/common/bcp47/timezone.xml
// (This list is not likely to change.)
private static readonly string[] s_UtcAliases = new[] {
private static readonly string[] s_UtcAliases = SupportLegacyTimeZoneNames ?
[
"Etc/UTC",
"Etc/UCT",
"Etc/Universal",
Expand All @@ -2448,7 +2467,13 @@ public static IEnumerable<object[]> SystemTimeZonesTestData()
"UTC",
"Universal",
"Zulu"
};
] : [
"Etc/UTC",
"Etc/UCT",
"Etc/Universal",
"Etc/Zulu",
"UTC"
];

// On Android GMT, GMT+0, and GMT-0 are values
private static readonly string[] s_GMTAliases = new[] {
Expand Down Expand Up @@ -2849,22 +2874,31 @@ public static void EnsureUtcObjectSingleton()
Assert.True(ReferenceEquals(tz, TimeZoneInfo.Utc));
}

public static IEnumerable<object[]> AlternativeName_TestData()
{
yield return new object[] { "Pacific Standard Time", "America/Los_Angeles" };
yield return new object[] { "AUS Eastern Standard Time", "Australia/Sydney" };
yield return new object[] { "GMT Standard Time", "Europe/London" };
yield return new object[] { "Tonga Standard Time", "Pacific/Tongatapu" };
yield return new object[] { "W. Australia Standard Time", "Australia/Perth" };
yield return new object[] { "E. South America Standard Time", "America/Sao_Paulo" };
yield return new object[] { "E. Africa Standard Time", "Africa/Nairobi" };
yield return new object[] { "W. Europe Standard Time", "Europe/Berlin" };
yield return new object[] { "Russian Standard Time", "Europe/Moscow" };
yield return new object[] { "Libya Standard Time", "Africa/Tripoli" };
yield return new object[] { "South Africa Standard Time", "Africa/Johannesburg" };
yield return new object[] { "Morocco Standard Time", "Africa/Casablanca" };
yield return new object[] { "Newfoundland Standard Time", "America/St_Johns" };
yield return new object[] { "Iran Standard Time", "Asia/Tehran" };

if (SupportLegacyTimeZoneNames)
{
yield return new object[] { "Argentina Standard Time", "America/Argentina/Catamarca" };
}
}

[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotBrowser))]
[InlineData("Pacific Standard Time", "America/Los_Angeles")]
[InlineData("AUS Eastern Standard Time", "Australia/Sydney")]
[InlineData("GMT Standard Time", "Europe/London")]
[InlineData("Tonga Standard Time", "Pacific/Tongatapu")]
[InlineData("W. Australia Standard Time", "Australia/Perth")]
[InlineData("E. South America Standard Time", "America/Sao_Paulo")]
[InlineData("E. Africa Standard Time", "Africa/Nairobi")]
[InlineData("W. Europe Standard Time", "Europe/Berlin")]
[InlineData("Russian Standard Time", "Europe/Moscow")]
[InlineData("Libya Standard Time", "Africa/Tripoli")]
[InlineData("South Africa Standard Time", "Africa/Johannesburg")]
[InlineData("Morocco Standard Time", "Africa/Casablanca")]
[InlineData("Argentina Standard Time", "America/Argentina/Catamarca")]
[InlineData("Newfoundland Standard Time", "America/St_Johns")]
[InlineData("Iran Standard Time", "Asia/Tehran")]
[MemberData(nameof(AlternativeName_TestData))]
public static void UsingAlternativeTimeZoneIdsTest(string windowsId, string ianaId)
{
if (PlatformDetection.ICUVersion.Major >= 52 && !PlatformDetection.IsiOS && !PlatformDetection.IstvOS)
Expand Down
Loading