Skip to content

Conversation

@baronfel
Copy link
Contributor

@baronfel baronfel commented Oct 29, 2024

Bug

Fixes: NuGet/Home#12253

Description

Per NuGet/Home#12253 (comment), I found that all cultures known to .NET on my Windows and Linux hosts used 2 or 3-character language codes, so I expanded the heuristic in the Locale_Parser to this to enable handling of resources for these locales in .NET packages. I also added comments explaining why these decisions were made and a note about future fully-correct implementations if those become required.

PR Checklist

  • Meaningful title, helpful description and a linked NuGet/Home issue
  • Added tests - I would appreciate some pointers where to add tests for this
  • Link to an issue or pull request to update docs if this PR changes settings, environment variables, new feature, etc.

@baronfel baronfel requested a review from a team as a code owner October 29, 2024 01:16
@microsoft-github-policy-service microsoft-github-policy-service bot added the Community PRs created by someone not in the NuGet team label Oct 29, 2024
@baronfel baronfel force-pushed the support-three-character-locale-prefixes branch from 7c3e4a0 to 3cf400c Compare October 29, 2024 21:11
@baronfel baronfel force-pushed the support-three-character-locale-prefixes branch from 3cf400c to d0a4d36 Compare October 29, 2024 21:11
nkolev92
nkolev92 previously approved these changes Oct 29, 2024
@jeffkl jeffkl self-assigned this Oct 29, 2024
Copy link
Contributor

@jeffkl jeffkl left a comment

Choose a reason for hiding this comment

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

Thanks for the fix!

@jeffkl jeffkl merged commit edb1d2f into NuGet:dev Oct 31, 2024
@baronfel baronfel deleted the support-three-character-locale-prefixes branch November 1, 2024 14:09
@clairernovotny
Copy link

@baronfel What .NET SDK version did this make it into?

@baronfel
Copy link
Contributor Author

baronfel commented Oct 9, 2025

9.0.200+ for sure, perhaps 9.0.100 but I'm not certain given the backport bar...

@nkolev92
Copy link
Member

nkolev92 commented Oct 9, 2025

Issue says 6.13, so that's 9.0.200

https://learn.microsoft.com/en-us/nuget/release-notes/nuget-6.13

@clairernovotny
Copy link

Fantastic, thank you. I've been preparing to release Humanizer 3.0 -- an RC is currently live now -- and I added the fil locale back into the default metapackage. I'll give it a go on SDK 8 and see if/how it breaks 😅.

What is the current story with the .NET Framework version of MSBuild w.r.t. NuGet client versions? I'm trying to understand the potential impact of this as I do not want to suddenly break people! :)

@nkolev92
Copy link
Member

17.13 and newer should have this fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Community PRs created by someone not in the NuGet team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Satellite assemblies for three-letter languages are not copied from NuGet package

4 participants