Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 175df38e authored by Tao Bao's avatar Tao Bao
Browse files

releasetools: Remove two dead functions in ota_from_target_files.py.

GetBuildProp() and GetVendorBuildProp() have been factored into
BuildInfo class. These two functions were meant to be deleted in commit
481bab8d.

Test: python -m unittest test_ota_from_target_files
Test: No users of these two functions.
Change-Id: Id590a46d597939973ef2339cdfea4f5163548d4d
parent 08dc8498
Loading
Loading
Loading
Loading
+0 −17
Original line number Original line Diff line number Diff line
@@ -683,23 +683,6 @@ def WriteMetadata(metadata, output_zip):
                     compress_type=zipfile.ZIP_STORED)
                     compress_type=zipfile.ZIP_STORED)




def GetBuildProp(prop, info_dict):
  """Returns the inquired build property from a given info_dict."""
  try:
    return info_dict.get("build.prop", {})[prop]
  except KeyError:
    raise common.ExternalError("couldn't find %s in build.prop" % (prop,))


def GetVendorBuildProp(prop, info_dict):
  """Returns the inquired vendor build property from a given info_dict."""
  try:
    return info_dict.get("vendor.build.prop", {})[prop]
  except KeyError:
    raise common.ExternalError(
        "couldn't find %s in vendor.build.prop" % (prop,))


def HandleDowngradeMetadata(metadata, target_info, source_info):
def HandleDowngradeMetadata(metadata, target_info, source_info):
  # Only incremental OTAs are allowed to reach here.
  # Only incremental OTAs are allowed to reach here.
  assert OPTIONS.incremental_source is not None
  assert OPTIONS.incremental_source is not None