def get_ratefactor(self, base, code):
        """
        Return the Decimal currency exchange rate factor of 'code' compared to 1 'base' unit, or RuntimeError
        Yahoo currently uses USD as base currency, but here we detect it with get_baserate
        """
        raise RuntimeError("%s Deprecated: API withdrawn in February 2018" % self.name)
        try:
            rate = self.get_rate(code)
        except RuntimeError:
            # fallback
            return self.get_singlerate(base, code)

        self.check_ratebase(rate)
        ratefactor = Decimal(rate['price'])

        if base == self.base:
            return ratefactor
        else:
            return self.ratechangebase(ratefactor, self.base, base)
def get_ratefactor ( self , base , code ) : raise RuntimeError ( "%s Deprecated: API withdrawn in February 2018" % self . name ) try : rate = self . get_rate ( code ) except RuntimeError : return self . get_singlerate ( base , code ) self . check_ratebase ( rate ) ratefactor = Decimal ( rate [ 'price' ] ) if base == self . base : return ratefactor else : return self . ratechangebase ( ratefactor , self . base , base )
Return the Decimal currency exchange rate factor of 'code' compared to 1 'base' unit, or RuntimeError
        Yahoo currently uses USD as base currency, but here we detect it with get_baserate