fix: SHA256-based dedup — same version different file now re-scans
This commit is contained in:
@@ -3,17 +3,7 @@
|
||||
import datetime
|
||||
from enum import Enum
|
||||
|
||||
from sqlalchemy import (
|
||||
JSON,
|
||||
Boolean,
|
||||
DateTime,
|
||||
ForeignKey,
|
||||
Integer,
|
||||
String,
|
||||
Text,
|
||||
UniqueConstraint,
|
||||
func,
|
||||
)
|
||||
from sqlalchemy import JSON, Boolean, DateTime, ForeignKey, Integer, String, Text, func
|
||||
from sqlalchemy.orm import Mapped, mapped_column, relationship
|
||||
|
||||
from guarddog_nexus.database import Base
|
||||
@@ -28,9 +18,6 @@ class ScanStatus(str, Enum):
|
||||
|
||||
class Scan(Base):
|
||||
__tablename__ = "scans"
|
||||
__table_args__ = (
|
||||
UniqueConstraint("package_name", "package_version", "repository", name="uq_scan_pkg"),
|
||||
)
|
||||
|
||||
id: Mapped[int] = mapped_column(Integer, primary_key=True, autoincrement=True)
|
||||
package_name: Mapped[str] = mapped_column(String(255), nullable=False)
|
||||
|
||||
Reference in New Issue
Block a user