For *args and **kwargs Locals globals tricks
def foo(*args, **kwargs): locals().update(**kwargs) print locals() In [54]: foo(a=10) {'a': 10, 'args': (), 'kwargs': {'a': 10}}