def test(a, b, *args, **kwargs): print a, b, args, kwargs >>> test(1, 2, 3, 4, aa=5, bb=6) 1 2 (3, 4) {'aa': 5, 'bb': 6}