code: def _validate_platforms_in_image(self, image):
          
          expected_platforms = get_platforms(self.workflow)
          if not expected_platforms:
              self.log.info('Skipping validation of available platforms '
                            'because expected platforms are unknown')
              return
          if len(expected_platforms) == 1:
              self.log.info('Skipping validation of available platforms for base image '
                            'because this is a single platform build')
              return
  
          if not image.registry:
              self.log.info('Cannot validate available platforms for base image '
                            'because base image registry is not defined')
              return
  
          try:
              platform_to_arch = get_platform_to_goarch_mapping(self.workflow)
          except KeyError:
              self.log.info('Cannot validate available platforms for base image '
                            'because platform descriptors are not defined')
              return
  
          manifest_list = self._get_manifest_list(image)
  
          if not manifest_list:
              raise RuntimeError('Unable to fetch manifest list for base image')
  
          all_manifests = manifest_list.json()['manifests']
          manifest_list_arches = set(
              manifest['platform']['architecture'] for manifest in all_manifests)
  
          expected_arches = set(
              platform_to_arch[platform] for platform in expected_platforms)
  
          self.log.info('Manifest list arches: %s, expected arches: %s',
                        manifest_list_arches, expected_arches)
          assert manifest_list_arches >= expected_arches, \
              'Missing arches in manifest list for base image'
  
          self.log.info('Base image is a manifest list for all required platforms')
docs: Ensure that the image provides all platforms expected for the build.