Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F7066180
D3727.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
D3727.id.diff
View Options
diff --git a/swh/model/model.py b/swh/model/model.py
--- a/swh/model/model.py
+++ b/swh/model/model.py
@@ -736,6 +736,8 @@
"""Represents an entity that provides metadata about an origin or
software artifact."""
+ object_type: Final = "metadata_authority"
+
type = attr.ib(type=MetadataAuthorityType, validator=type_validator())
url = attr.ib(type=str, validator=type_validator())
metadata = attr.ib(
@@ -762,6 +764,8 @@
"""Represents a software component used to fetch metadata from a metadata
authority, and ingest them into the Software Heritage archive."""
+ object_type: Final = "metadata_fetcher"
+
name = attr.ib(type=str, validator=type_validator())
version = attr.ib(type=str, validator=type_validator())
metadata = attr.ib(
@@ -791,6 +795,8 @@
@attr.s(frozen=True)
class RawExtrinsicMetadata(BaseModel):
+ object_type: Final = "raw_extrinsic_metadata"
+
# target object
type = attr.ib(type=MetadataTargetType, validator=type_validator())
id = attr.ib(type=Union[str, SWHID], validator=type_validator())
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Nov 4 2024, 8:54 PM (9 w, 2 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3224213
Attached To
D3727: model: Add final object_type field on metadata related model objects
Event Timeline
Log In to Comment