Get information about arguments passed into a particular frame. A tuple of four things is returned: (args, varargs, varkw, locals). 'args' is a list of the argument names. 'varargs' and 'varkw' are the names of the * and ** arguments or None. 'locals' is the locals dictionary o
(frame)
| 1425 | ArgInfo = namedtuple('ArgInfo', 'args varargs keywords locals') |
| 1426 | |
| 1427 | def getargvalues(frame): |
| 1428 | """Get information about arguments passed into a particular frame. |
| 1429 | |
| 1430 | A tuple of four things is returned: (args, varargs, varkw, locals). |
| 1431 | 'args' is a list of the argument names. |
| 1432 | 'varargs' and 'varkw' are the names of the * and ** arguments or None. |
| 1433 | 'locals' is the locals dictionary of the given frame.""" |
| 1434 | args, varargs, varkw = getargs(frame.f_code) |
| 1435 | return ArgInfo(args, varargs, varkw, frame.f_locals) |
| 1436 | |
| 1437 | def formatannotation(annotation, base_module=None): |
| 1438 | if getattr(annotation, '__module__', None) == 'typing': |