Skip to content

BUG: Missing validation for empty or whitespace image_ids in Album requests #1254

@Varun-JP

Description

@Varun-JP

Is there an existing issue for this?

  • I have searched the existing issues

What happened?

Currently, the ImageIdsRequest schema allows empty lists or lists containing only whitespace strings (e.g., [" ", ""]). This can lead to database inconsistencies or unhandled 500 errors in the album management logic.

Proposed Fix: Add a Pydantic @field_validator to sanitize input and ensure the list contains valid, non-empty strings.

Record

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions