Variable + Argument Name Shadowing

Scenario: Arguments and Variables can have the same name which causes likely unintended behavior.

Steps to reproduce: Create a sequence or workflow with a variable name the same as an argument name

Current Behavior: Allows the creation of both a variable and an argument with the same name. In this instance, the variable is used but not the argument. When trying to get information

Expected Behavior: Disallow the creation of variable or argument names that shadow each other

Studio/Robot/Orchestrator Version: 2018.2.3 (For all)

OS Version: Windows 10
Others if Relevant: (workflow, logs, .net version, service pack, etc): Please see attached workflow:

Test_SameName.xaml (5.4 KB)

1 Like

Change the out_String variable from “sequence” to “Test_SameName” . It will work.

But i will suggest , use variable with one name either in variable or in argument.

That’s not the point. I know how to avoid such a thing, but it likely should not be allowed in the first place.

Hi @dmccammond

I can confirm that this bug has been registered. I cannot give the deadline for when it will be fixed, but it will happen. It will most likely arrive with more improvements in the area of verifying the workflow.

1 Like

Hi @dmccammond

You can now use a Workflow Analyzer rule to find out these conflicts :slight_smile: