code: def get_quantity_info(self, quantity, key=None, default=None):
          
          d = self._get_quantity_info_dict(quantity, default if key is None else dict())
  
          if key is None:
              return d
  
          return d.get(key, default)
docs: Get information of a certain quantity.
          If *key* is `None`, return the full dict for that quantity.