File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -336,7 +336,8 @@ def __post_init__(self): # hack to make BlobLfsInfo backward compatible
336336
337337@dataclass
338338class BlobSecurityInfo (dict ):
339- safe : bool
339+ safe : bool # duplicate information with "status" field, keeping it for backward compatibility
340+ status : str
340341 av_scan : Optional [Dict ]
341342 pickle_import_scan : Optional [Dict ]
342343
@@ -656,10 +657,14 @@ def __init__(self, **kwargs):
656657 oid = last_commit ["id" ], title = last_commit ["title" ], date = parse_datetime (last_commit ["date" ])
657658 )
658659 self .last_commit = last_commit
659- security = kwargs .pop ("security " , None )
660+ security = kwargs .pop ("securityFileStatus " , None )
660661 if security is not None :
662+ safe = security ["status" ] == "safe"
661663 security = BlobSecurityInfo (
662- safe = security ["safe" ], av_scan = security ["avScan" ], pickle_import_scan = security ["pickleImportScan" ]
664+ safe = safe ,
665+ status = security ["status" ],
666+ av_scan = security ["avScan" ],
667+ pickle_import_scan = security ["pickleImportScan" ],
663668 )
664669 self .security = security
665670
You can’t perform that action at this time.
0 commit comments