@SFA Would you mind sharing the answer, It will be helpful if someone come across similar error.
I am honestly not sure. I re did the same steps and placed the code in a different line ie just below the below line, before it was below the commented lines
and then build and also ran the pluginpackager in administrator mode..Prior to doing all this , I had upgraded the lab setup to 24.3 version as well but the error didn't go, so re did the plugin generation.
Badge Earners
GroSanhas earned the badge BCA: Privileged Remote Access
Ahmed Butthas earned the badge Core Concepts - Privileged Remote Access