From 612efb3ba3ba399465ad0ab52a68d4226b2898f0 Mon Sep 17 00:00:00 2001 From: Aman Date: Wed, 22 May 2024 10:45:05 +0000 Subject: [PATCH] add fareportal/avoid_print_example.py --- fareportal/avoid_print_example.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 fareportal/avoid_print_example.py diff --git a/fareportal/avoid_print_example.py b/fareportal/avoid_print_example.py new file mode 100644 index 0000000000..56825227ce --- /dev/null +++ b/fareportal/avoid_print_example.py @@ -0,0 +1,15 @@ +print("Welcome to Semgrep!" + "Use our Run button to start experimenting -->") + + +print("Example") + +# To detect ALL calls to the print() function, change the Semgrep Rule from print("...") to print(...) +print("Example") +print(not_a_string) + +print(first_var, second_var) +print("Example") +print() + +# print("This is commented out so it will never be found") +print("Example") \ No newline at end of file