gen_hooks.py: too many arguments were being passed for string formatting