The problem is the keywords. You are not allowed positional arguments after keyword arguments.
f(3, 5, *[1,2,3])
works fine, in that it passes a tuple with the values 1,2,3. The same as:
f(3, 5, *(1,2,3))
Keywords must always come after positional arguments, so it is your function declaration which is incorrect:
def f(*args, a, b):
return (a, b, args)
print(f(a=3, b=5))
print(f(*[1,2,3], a=3, b=5))
Gives:
(3, 5, ())
(3, 5, (1, 2, 3))