-
-
Notifications
You must be signed in to change notification settings - Fork 29
[BUG] Keyword not recognized when prefixed in same file #590
Description
Describe the bug
RobotCode reports KeywordNotFound and cannot Go to Definition for a keyword call that uses a qualified prefix referencing the same resource file.
Steps To Reproduce
Create a file "myresouce.robot" in VS Code with RobotCode enabled.
Define a keyword in the same file and call it using a namespace prefix, e.g. MyResource.keyword name
Ctrl+Click on the prefixed call -> See error No keyword with name 'MyResource....' found. robotcode(KeywordNotFound) and navigation fails.
Expected behavior
RobotCode should resolve this call and allow Go to Definition to jump to the local keyword definition in the same resource file
Example
*** Settings ***
Library Collections
*** Keywords ***
Login Keyword
[Documentation] this is a login keyword
Log hello
Login Keyword Is Opened
MyResource.Login Keyword <-- keyword not found (prefix of the same file)
Login Keyword <-- ok (no prefix)
BuiltIn.Log To Console test 1 <-- ok (prefix other file)
Desktop
VS Code Version: 1.113.0
RobotCode Version: 2.4.0
OS: Ubuntu 24.04.4 LTS
Python Version: 3.10.6
RobotFramework Version: 6.1.1
