ctx.log_entry(*info, ACTION_DROP, SOURCE_LOCAL, None, RCODE_SERVFAIL, 0, rep.security, rep.ttl)
This line specifically shows the module is pre-23.1. In case you haven't you should probably restart Unbound so the template generation has a chance to kick in.