Skip to content

Consider removing #[non_exhaustive] from ValidationResult or making fields private #487

@avifenesh

Description

@avifenesh

Audit Finding (API Design, Low)

Location: crates/agnix-core/src/pipeline.rs:38

ValidationResult is #[non_exhaustive] with public fields. The attribute only prevents struct literal construction but doesn't protect field access. This is inconsistent with the builder pattern used for LintConfig.

Fix: Either make fields private with getter methods, or remove #[non_exhaustive] since the struct is simple.

Found by /audit-project

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions