Skip to content

Commit 1cb4cf9

Browse files
Add a few basic tests and require >= Python 3.10
1 parent 7fa49bd commit 1cb4cf9

5 files changed

Lines changed: 357 additions & 42 deletions

File tree

arachnid_shield_sdk/models/scanned_pdq.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,11 @@ def from_dict(cls, src_dict: typing.Dict[str, typing.Any]) -> "PDQMatch":
3636
near_match_details=near_match_details,
3737
)
3838

39+
@property
40+
def matches_known_media(self) -> bool:
41+
"""Determine whether the scanned media matches any known media."""
42+
return self.classification is not None and self.classification != MediaClassification.NoKnownMatch
43+
3944

4045
@dataclasses.dataclass
4146
class ScannedPDQHashes:

0 commit comments

Comments
 (0)