No elements generated in python code

I found this script on an earlier post and modified it. Question is nothing happens when I run it. I have a couple bars that are QTY=14. It works when I change it to the Mark parameter

If you remove the IF statement do u get all the rebar, or still no values?

Also it says completed with warnings, but I don’t see warning. Can you share that info?

no the error in the first pic I sent is from different nodes not showing. If I remove the IF it shows up with errors.

Its something to do with the parameters. If I replace it with Mark it works fine

Solved. The first looks up the parameter as string, I need it as an integer