

def getfullargspec(func):
    'Compatibility function to provide inspect.getfullargspec in Python 2\n\n    This should be rewritten using a backport of Python 3 signature\n    once we drop support for Python 2.6. We went for a simpler\n    approach at the time of writing because signature uses OrderedDict\n    which is not available in Python 2.6.\n    '
    try:
        return inspect.getfullargspec(func)
    except AttributeError:
        arg_spec = inspect.getargspec(func)
        import collections
        tuple_fields = 'args varargs varkw defaults kwonlyargs kwonlydefaults annotations'
        tuple_type = collections.namedtuple('FullArgSpec', tuple_fields)
        return tuple_type(args=arg_spec.args, varargs=arg_spec.varargs, varkw=arg_spec.keywords, defaults=arg_spec.defaults, kwonlyargs=[], kwonlydefaults=None, annotations={
            
        })

dataset/ETHPy150Open scikit-learn/scikit-learn/sklearn/externals/joblib/func_inspect.py getfullargspec/original