microsoft/aspire · error · InvalidOperationException

Integration package probe manifest entry is missing…

Error message

Integration package probe manifest entry is missing required property '{propertyName}'.

What it means

NormalizeRequiredValue validates that a required string property from a probe-manifest entry has a non-whitespace value, trimming and returning it. If the value is null, empty, or whitespace-only, it throws InvalidOperationException naming the missing property. This is the normalization-stage guard complementing the JSON-level check in ReadStringProperty.

Solutions

  1. Open the manifest JSON and supply a real value for the property named in the message.
  2. Regenerate the manifest so required fields are populated from the package contents.
  3. Validate the manifest schema before loading (all required properties non-empty strings).

Example fix

// before
{ "name": "", "path": "lib.so" }

// after
{ "name": "MyLib", "path": "lib.so" }
Defensive patterns

Strategy: validation

Validate before calling

static void EnsureNonEmpty(JsonElement e, string prop)
{
    if (!e.TryGetProperty(prop, out var v) || v.ValueKind != JsonValueKind.String || string.IsNullOrWhiteSpace(v.GetString()))
        throw new InvalidOperationException($"Manifest entry property '{prop}' must be a non-empty string.");
}

Try / catch

try { LoadManifest(path); }
catch (InvalidOperationException ex) when (ex.Message.Contains("missing required property"))
{ logger.LogError(ex, "Probe manifest has an empty required property"); throw; }

Prevention

When it happens

Trigger: A manifest entry passes JSON parsing but a required property (e.g. 'name', 'path') is present yet null, empty (""), or whitespace-only (" ").

Common situations: Hand-edited manifests with "path": ""; generated manifests where an upstream tool emitted empty strings for missing values; copy-paste of a template entry without filling values.

Understand the failure class

Background: "must not be empty", "cannot be empty" — required-field validation errors across open-source libraries — this error's family across 41 libraries.

Related errors


AI-assisted analysis of microsoft/aspire@25830f84bd (2026-09-16). Data as JSON: /api/errors/1a4f41b7e78352af. Report an issue: GitHub.

Appendix: source

Thrown at src/Shared/IntegrationPackageProbeManifest.cs:377

        }
        catch (Exception ex) when (ex is ArgumentException or NotSupportedException or PathTooLongException)
        {
            throw new InvalidOperationException(invalidPathMessage, ex);
        }
    }

    private static string? NormalizeCulture(string? culture)
    {
        return string.IsNullOrWhiteSpace(culture) || string.Equals(culture, "neutral", StringComparison.OrdinalIgnoreCase)
            ? null
            : culture.Trim();
    }

    private static string NormalizeRequiredValue(string? value, string propertyName)
    {
        if (string.IsNullOrWhiteSpace(value))
        {
            throw new InvalidOperationException($"Integration package probe manifest entry is missing required property '{propertyName}'.");
        }

        return value.Trim();
    }

    private static string? NormalizeOptionalValue(string? value)
    {
        return string.IsNullOrWhiteSpace(value) ? null : value.Trim();
    }

    private static IReadOnlyList<IntegrationPackageManagedAssembly> ReadManagedAssemblies(JsonElement rootElement)
    {
        if (!rootElement.TryGetProperty("managedAssemblies", out var managedAssembliesElement) ||
            managedAssembliesElement.ValueKind != JsonValueKind.Array)
        {
            return [];
        }

View on GitHub (pinned to 25830f84bd)