Skip to content

Add a uniqueness constraint for source packages #1169

Open

Description

@daviddavis

Unlike other content types, there's no uniqueness constraint for SourcePackages. There's some code that does check for other source packages by source/version but since this is enforced in the code and not the db, it's possible to end up with duplicate source packages though if the package is uploaded a second time before it's saved to the db.

For a unique index, one option might be to use source/version fields which the code is using now. Another option is to use the relative_path and sha256 of the dsc file which would be somewhat consistent with other Package types (see the discussion here).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions