3 ms·
3. It prevents the developer from trying db.execute(f"QUERY WHERE name = {name}") or db.execute("QUERY WHERE name = %s" % name, ()) or other ways of man
by zahlman 2y ago
3. It prevents the developer from trying
db.execute(f"QUERY WHERE name = {name}")
or
db.execute("QUERY WHERE name = %s" % name, ())
or other ways of manually interpolating the string - because `db.execute` can flag a `TypeError` if given a string (no matter how it was constructed) rather than a `Template` instance.