Comment 1 for bug 1770400

Revision history for this message
Colin Watson (cjwatson) wrote :

Thanks for filing this. I'm currently waiting for the snapcraft team to send me back the core logic we need to integrate into the Launchpad build manager for this (subject "snapcraft architectures and LP", last email in thread sent 2018-05-03). Quoting the top of that thread:

"""
Perhaps the most economical approach to getting this implemented would be for somebody on the snapcraft side to give us a suitable implementation of a function that has a signature something like this:

  def determine_architectures_to_build(snapcraft_yaml, allowed_arches):
      """Return architectures to build.

      :param snapcraft_yaml: The contents of the snapcraft.yaml file, as
          a string.
      :param allowed_arches: An ordered list of all architecture tags
          that we can create builds for. In cases where any one of
          several build architectures might be suitable, we pick the
          earliest in this list.
      :return: A dict mapping architecture tags to an ignore flag for
          each build that should be created; if the ignore flag is true,
          then the build for that architecture should not cause the
          whole build set to fail.
      """

This is roughly patterned after a similar bit of code we have for .deb builds.

That's the bit that most needs input from the snapcraft team. We could then do the integration with LP on our side, since that will involve a good deal of specialist knowledge of our data model. Does that sound reasonable?

(We're missing other things that would be needed for build sets to work, but we might as well start laying the groundwork for them here.)
"""