Skip to main content

Common issues

1. Z3 solver errors

Error: Z3Exception: ... Cause: Typical z3 installation issues or complex logical contradictions. Fix: Ensure z3-solver>=4.12.0 is installed. Check for contradictory policy statements (e.g., Allow and Deny on the same resource/action without conditions).

2. Terraform parsing failures

Error: ParseError Cause: Syntax error in .tf files, a directory with no .tf files, or input the parser refuses: .tf.json files, Terraform override files, module calls, an unmodelled resource that may grant access, or template directives in a policy document. See TerraformParser and unmodelled declarations. Fix: Validate your terraform code with terraform validate. The parser fails closed — it raises ParseError with a full error list rather than silently skipping problematic blocks.

3. Missing pricing data

Error: CostEstimate.has_unknown_types=True or CostEstimate.within_budget=False with unknown types. Cause: An instance or volume type not in the embedded static catalogue, provisioned IOPS or throughput the catalogue can’t price, an invalid count or size_gb, or an entry in the model’s unmodelled list (for example an aws_instance without root_block_device). The reason lists each problem, and the breakdown keys (unknown-..., invalid-count-..., invalid-size-..., unpriced-..., unmodelled-...) name the resources. Fix: Update qwed-infra or check CostGuard.INSTANCE_PRICING and CostGuard.VOLUME_PRICING (which replace CostGuard.PRICING_CATALOG from v0.4.0) to verify coverage. Declare root_block_device with a size and type so the root volume can be priced. Unknown types and unmodelled declarations always produce a BLOCKED diagnostic — never a silent zero-cost estimate.

4. NetworkGuard unsupported topology

Error: ComputedPath.unsupported_topology=True Cause: The topology uses a key, route target or rule field outside the modelled topology, such as NAT Gateways, VPC Peering, NACLs, Transit Gateway or protocol-scoped rules, or an input the guard refuses, such as a duplicate subnet id or an invalid port. reason says which check refused the topology. Fix: Restructure the network to avoid these constructs, or implement a manual review gate for those topologies. The guard returns UNVERIFIABLE (not a silent pass).

5. ArtifactBoundaryGuard blocks with unknown boundary

Error: ArtifactBoundaryFinding.finding_type="unknown_boundary" Cause: Missing or invalid [tool.hatch.build.targets.wheel] in pyproject.toml, a hatchling input the guard doesn’t model (see Hatchling inputs; wheel force-include is reported as missing_control instead), or no TOML parser available. Fix: Add an explicit wheel packages configuration to your pyproject.toml, and remove the unmodelled input named in the finding’s reason. Install tomli for Python <3.11.

6. Diagnostic serialization errors

Error: InfraDiagnosticResult.from_dict() raises ValueError Cause: Missing or invalid status field. Fix: Ensure the serialized dict has a status key with one of VERIFIED, UNVERIFIABLE, or BLOCKED. Use diag.to_dict() for canonical serialization.

Support

For issues not listed here, please open an issue on GitHub.