def metapackage_check(self, path, pkg):
        if pkg.is_metapackage():
            try:
                metapackage.validate_metapackage(path, pkg)
            except metapackage.InvalidMetapackage as e:
                warning("Invalid metapackage:")
                warning("  %s\n" % str(e))
                error(fmt("Refusing to release invalid metapackage '@|%s@{rf}@!', metapackage requirements:\n  @|%s" %
                      (pkg.name, metapackage.DEFINITION_URL)), exit=True)
dataset/ETHPy150Open ros-infrastructure/bloom/bloom/generators/release.py/ReleaseGenerator.metapackage_check/original