Skip to content

Commit 24e014d

Browse files
committed
New API: Add a TODO comments
Signed-off-by: Martin Vrachev <mvrachev@vmware.com>
1 parent 2b6f2d9 commit 24e014d

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tuf/api/metadata.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -560,6 +560,8 @@ def update(
560560
hashes: Optional[Mapping[str, Any]] = None,
561561
) -> None:
562562
"""Assigns passed info about snapshot metadata to meta dict. """
563+
# TODO: Consider renaming this function:
564+
# see: https://github.com/theupdateframework/tuf/issues/1230
563565
self.meta["snapshot.json"] = MetadataInfo(version, length, hashes)
564566

565567

@@ -618,6 +620,8 @@ def update(
618620
hashes: Optional[Mapping[str, Any]] = None,
619621
) -> None:
620622
"""Assigns passed (delegated) targets role info to meta dict. """
623+
# TODO: Consider renaming this function:
624+
# see: https://github.com/theupdateframework/tuf/issues/1230
621625
metadata_fn = f"{rolename}.json"
622626
self.meta[metadata_fn] = MetadataInfo(version, length, hashes)
623627

@@ -768,6 +772,8 @@ def to_dict(self) -> Dict[str, Any]:
768772
# Modification.
769773
def update(self, filename: str, fileinfo: Mapping[str, Any]) -> None:
770774
"""Assigns passed target file info to meta dict. """
775+
# TODO: Consider renaming this function:
776+
# see: https://github.com/theupdateframework/tuf/issues/1230
771777
self.targets[filename] = TargetInfo(
772778
fileinfo["length"], fileinfo["hashes"], fileinfo.get("custom")
773779
)

0 commit comments

Comments
 (0)