def satisfy(self, *requirements):
        """
        Checks whether the given requirements are satisfiable within the given
        execution context

        Parameter
        ---------
        requirements : list(Requirement)
            List of requirements to check whether they are satisfiable
        """
        versions = []
        for req_range in requirements:
            try:
                version = self._detected_versions[req_range.name]
            except KeyError:
                try:
                    version = req_range.requirement.detect_version()
                except ArcanaRequirementNotFoundError as e:
                    if self._fail_on_missing:
                        raise
                    else:
                        logger.warning(e)
                except ArcanaVersionNotDetectableError as e:
                    if self._fail_on_undetectable:
                        raise
                    else:
                        logger.warning(e)
                else:
                    self._detected_versions[req_range.name] = version
            if not req_range.within(version):
                raise ArcanaVersionError(
                    "Detected {} version {} is not within requested range {}"
                    .format(req_range.requirement, version, req_range))
            versions.append(version)
        return versions
def satisfy ( self , * requirements ) : versions = [ ] for req_range in requirements : try : version = self . _detected_versions [ req_range . name ] except KeyError : try : version = req_range . requirement . detect_version ( ) except ArcanaRequirementNotFoundError as e : if self . _fail_on_missing : raise else : logger . warning ( e ) except ArcanaVersionNotDetectableError as e : if self . _fail_on_undetectable : raise else : logger . warning ( e ) else : self . _detected_versions [ req_range . name ] = version if not req_range . within ( version ) : raise ArcanaVersionError ( "Detected {} version {} is not within requested range {}" . format ( req_range . requirement , version , req_range ) ) versions . append ( version ) return versions
Checks whether the given requirements are satisfiable within the given
        execution context

        Parameter
        ---------
        requirements : list(Requirement)
            List of requirements to check whether they are satisfiable