def is_ambiguous(at):
 if isinstance(at, datetime):
  return False
 return any(((getattr(at, attr) is None) for attr in adatetime.units))

def is_ambiguous ( at ) : if isinstance ( at , datetime ) : return False return any ( ( ( getattr ( at , attr ) is None ) for attr in adatetime . units ) )
returns true if the given object is an adatetime with any of its attributes equal to none .