Skip to content

Commit f26414f

Browse files
OSS-Fuzz Teamcopybara-github
authored andcommitted
The Manifest now includes a dictionary field metadata to store arbitrary key-value pairs. This allows for attaching additional information to snapshots.
PiperOrigin-RevId: 893467858
1 parent ec12d23 commit f26414f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

infra/base-images/base-builder/indexer/manifest_types.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,6 +285,8 @@ class Manifest:
285285
# Version of the index database schema.
286286
index_db_version: int | None = None
287287

288+
metadata: dict[str, str] = dataclasses.field(default_factory=dict)
289+
288290
@classmethod
289291
def from_dict(cls, data: dict[str, Any]) -> Self:
290292
"""Creates a Manifest object from a deserialized dict."""
@@ -332,6 +334,7 @@ def from_dict(cls, data: dict[str, Any]) -> Self:
332334
data, "reproducibility", Reproducibility.from_dict
333335
),
334336
binary_config=binary_config,
337+
metadata=data.get("metadata", {}),
335338
)
336339

337340
def to_dict(self) -> dict[str, Any]:

0 commit comments

Comments
 (0)