-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Variable files imported as modules are not resolved #699
Labels
Comments
Note: I've just published a pre-release ( |
Thanks, works fine in my installation of VS Code. Now there's just one more thing, which is that class names are not recognized as variables... I'll create a new issue about that #704. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
Since Robot Framework 5.0, variable files can be imported as modules, as described in the release notes. This new syntax does not seem to be recognized by the Language Server. The error 'Unresolved variable import' is shown instead.
To Reproduce
If a variable file is imported like
Variables module/subfolder/varfile.py
,then changing the line to use the new 'import as module' syntax will reproduce the error:
Variables module.subfolder.varfile
.Expected behavior
Both ways of defining the import should work. The import should be resolved correctly and variables that are defined in the imported file should hence not be marked as 'undefined variables'.
The new syntax is explained in more detail in the Robot Framework User Guide, section 2.8.2 Variable Files -> Taking variable files into use.
Versions:
The text was updated successfully, but these errors were encountered: