I am trying to skip multiple line queries using bandit in my python query. I have tried to use #nosec but still there is bandit issue showing
Example:
"""#nosec""" ;Query = f"""Select username,id,email_id,address from User where username ='John'"""
The example code you show doesn’t handle Bandit warnings: the first part is a string expression
"""#nosec"""followed by an assignment statement (and I can’t see why Bandit would complain about that.Anyway, according to the docs you can exclude specific lines of code using a special comment: