Skip to content

String-to-bool normalization treats "false" as true #1466

@erensunerr

Description

@erensunerr

Affected file: sk/microsoft-agent-framework/skills/azure-architecture-autopilot/scripts/cli.py

What I hit

I passed in a service payload with {"private": "false"} and the generated output still flagged it as private.

I’m thinking this comes from svc["private"] = bool(svc["private"]) where any non-empty string is cast to True.

Repro

  1. Pass {"private": "false"} into the service normalization path.
  2. Inspect output and confirm private remains True.

Expected

String booleans should map semantically ("true", "false", etc.), not by truthy casting.

Actual

"false" and other non-empty values are interpreted as true.

Suggested fix

Implement explicit string normalization for true/false inputs before assignment.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions