You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Variables which are composed of both a partial string and an environmental variable are not recognized, even if both variables are populated and accessible to RobotCode. This is documented in the Variables inside variables section in the official guide.
Example
robot.toml
[env]
ENV_ALIAS = "STAGING"
test.robot
*** Variables ***${TENANT_PROD}123456${TENANT_STAGING}654321***Test Cases***We Are In Staging
Log To Console ${TENANT_%{ENV_ALIAS}}
Should Be Equal As Integers ${TENANT_%{ENV_ALIAS}}654321
Playground example Note: Due to limitations of the Playground environment, I could not replicate my inline example directly, but the essence of the correct behavior should be observable.
Steps To Reproduce
Re-create an example as above (either inline code or the Playground example)
Note how RobotCode flags the first portion of the variable name as well as the compounded name as not found.
Error Examples
Variable '${TENANT_}' not found.robotcode.namespace(VariableNotFound)
Variable '${TENANT_%{ENV_ALIAS}}' not found.
Expected behavior
RobotCode should be able to resolve the combination as a singular variable and not flag these components as unfound variables.
Note that Robot Framework understands the compound correctly and the expected combination is evaluated properly.
Desktop
VS Code Version: 1.93.1
RobotCode Version: 0.93.1
OS: Windows 11 Enterprise
Python Version: 3.12.3
RobotFramework Version: 6.1.1
Robocop: 5.4.0
Robotidy: 4.14.0
The text was updated successfully, but these errors were encountered:
d-biehl
changed the title
[BUG] Variables Which Are Compounds of Scalars and Environmental Variables Not Recognized
[Enhancement] Variables Which Are Compounds of Scalars and Environmental Variables Not Recognized
Oct 17, 2024
Description
Variables which are composed of both a partial string and an environmental variable are not recognized, even if both variables are populated and accessible to RobotCode. This is documented in the Variables inside variables section in the official guide.
Example
robot.toml
test.robot
Steps To Reproduce
Error Examples
Expected behavior
RobotCode should be able to resolve the combination as a singular variable and not flag these components as unfound variables.
Note that Robot Framework understands the compound correctly and the expected combination is evaluated properly.
Desktop
1.93.1
0.93.1
Windows 11 Enterprise
3.12.3
6.1.1
5.4.0
4.14.0
The text was updated successfully, but these errors were encountered: