You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by no...@apache.org on 2020/12/29 12:25:03 UTC
[buildstream] 15/15: _ostree.py: Remove unused __list_remote_refs
function
This is an automated email from the ASF dual-hosted git repository.
not-in-ldap pushed a commit to branch jennis/136-clean-remote-cache
in repository https://gitbox.apache.org/repos/asf/buildstream.git
commit f6cab6410e52f6e18a9e72bc4cf16c7d9185ac2b
Author: James Ennis <ja...@codethink.com>
AuthorDate: Tue May 22 10:41:15 2018 +0100
_ostree.py: Remove unused __list_remote_refs function
---
buildstream/_ostree.py | 20 --------------------
1 file changed, 20 deletions(-)
diff --git a/buildstream/_ostree.py b/buildstream/_ostree.py
index 93fad13..72685a8 100644
--- a/buildstream/_ostree.py
+++ b/buildstream/_ostree.py
@@ -596,23 +596,3 @@ def __list_all_refs(repo):
return refs
except GLib.GError as e:
raise OSTreeError(message=e.message) from e
-
-
-# __list_remote_refs():
-#
-# Fetch list of refs from a remote.
-#
-# Args:
-# repo (OSTree.Repo): The repo
-# remote (str): An optional remote name, defaults to 'origin'
-#
-# Returns:
-# (dict): A dict of refs to checksums.
-#
-def __list_remote_refs(repo, remote="origin"):
- try:
- _, refs = repo.remote_list_refs(remote)
- return refs
- except GLib.GError as e:
- (_, remote_url) = repo.remote_get_url(remote)
- raise OSTreeError(message="{} when attempting to fetch from {}".format(e.message, remote_url)) from e