Summary:
We have identified an issue with the handling of secret variables in nested templates within Harness. Specifically, when a step template that accepts an input variable of type "secret" is used within a stage template, the secret value is not passed correctly.
Current Behavior:
A step template accepts an input variable of type "secret".
When this step template is used directly in a stage and a Harness secret is selected as the input value, the secret value is correctly retrieved and used within the step template.
However, when the step template is used within a stage template, and an input variable of type "secret" is defined for the stage template, the step template receives the string secrets.getValue('*******') instead of the actual secret value when populated with <+stage.variables.secretInput>.
Enhanced Behavior:
Correct Secret Handling in Nested Templates: Ensure that when a step template within a stage template receives an input variable of type "secret", the actual secret value is correctly passed and not the string secrets.getValue('*******').