def _getargs(func):
    # Use this instead of importing inspect for less mem overhead.
    import types
    if sys.version_info >= (3, 0):
        if isinstance(func, types.MethodType):
            func = func.__func__
        co = func.__code__
    else:
        if isinstance(func, types.MethodType):
            func = func.im_func
        co = func.func_code
    return co.co_varnames[:co.co_argcount]
Return the names of all static arguments to the given function.
dataset/ETHPy150Open clips/pattern/pattern/server/cherrypy/cherrypy/_cptools.py/_getargs