Skip to main content
Version: 2.13.14

Troubleshoot Humanizer

Orientation​

Start with the resolved Humanizer 2.13.14 package, target framework, culture, exact API call, and platform. Most apparent failures come from following documentation for another version, resolving a different package asset, leaving ambient culture implicit, or treating locale-dependent presentation text as invariant data.

Example​

Capture a minimal reproduction before changing configuration:

using System.Globalization;
using Humanizer;
using Humanizer.Configuration;

var culture = CultureInfo.GetCultureInfo("en-US");
var value = 42.ToWords(culture);
Console.WriteLine($"{typeof(Configurator).Assembly.GetName().Version}: {value}");

Run dotnet list package --include-transitive, inspect the target in project.assets.json, and select Humanizer 2.13.14 in this site.

Symptoms and actions​

SymptomEvidence to collectAction
API page or method is missingPackage version, selected docs version, TFMKeep the site on 2.13.14; check the page’s version notes and selected API root.
MissingMethodException or TypeLoadExceptionAll direct/transitive Humanizer versionsAlign Humanizer, Humanizer.Core, and locale packages; clean bin/obj, restore, and rebuild.
Output is English or the wrong regional formCurrentCulture, CurrentUICulture, explicit argument, package versionPass culture directly where possible; otherwise set both ambient cultures at the request/job boundary and check locale capability.
Output differs on Windows, Linux, or macOSOS, TFM, culture, globalization modeCompare platform globalization data and the selected release’s formatting coverage; avoid asserting platform-owned text without an explicit override.
A selected-version parser rejects inputExact text and culture/providerConfirm the parser and overload exist in the 2.13.14 API and inspect the first unrecognized token or unit.
Enum input throws NoMatchFoundExceptionEnum members/metadata and inputUse an unambiguous label; pass OnNoMatch.ReturnsNull when failure is expected. Matching is case-insensitive.
CS8032 or AD0001 from a Humanizer analyzer after migrationSDK/MSBuild and package versionFollow the Humanizer 3 analyzer migration guide, clear stale build outputs, and restore. Humanizer 2.13.14 does not bundle that analyzer.
Search or a copied URL opens another API versionCurrent selector and URLRe-select 2.13.14, then navigate from its API root. Narrative and API routes are versioned together.

Reduce culture issues​

Set culture explicitly in a one-file reproduction. If the wrong result persists, compare the 2.13.14 capability page and note whether the culture resolves directly or through a parent. Include platform and TFM when reporting a locale issue.

Reduce package issues​

Use dotnet restore --force-evaluate after aligning versions. Inspect direct and transitive Humanizer packages together before changing application code.

Pitfall​

Do not “fix” a localized output difference by persisting the current humanized string or by setting process-wide culture inside a request. That hides the input boundary and creates concurrent, version-dependent behavior. Keep typed values, scope culture, and assert only output the application intentionally owns.

Version notes​

Package layout, target frameworks, locale implementation, and API routes on this page are scoped to Humanizer 2.13.14.