Importing an library in Robot Framework comes in RED color.

Issue: – We tried adding the Selenium2Libray in robot framework but its shown in red color(in settings) and we are not able to implement any of the keywords.

library comes in red in robot framework

Root cause: – Anything coming in red in settings after importing generally means that particular library is not properly installed.

Let’s check whether we were able to install selenium2library.
Type python in cmd and type “import selenium2library”, in our case it would give the error message something call stack error.
We can visualize the same error after importing selenium2library in ride and going to Tools > View in ride.

View log in Robot framework

We found some files were missing like in our case its decorator dependency that RIDE is not able to locate when loading “Selenium2Library”
No module decorator robot framework
Note: – Most of the time it’s some missing files that are not installed which results in libraries name coming in red on adding to RIDE. Like same can happen on importing “ExcelLibrary” or “Database library”

Go ahead and install the missing dependency, in our case its “decorator”
Download the dependency
Open the command prompt to the extracted downloaded file install

And we are done.

Note:- As discussed same solution can be applied to any external library that is coming as red on importing into RIDE inside settings tab.

Learn Robot Framework

One reply on “Importing an library in Robot Framework comes in RED color.”


I have installed below things but still selenium2Library is not properly importing


Could you please help me to resolve this?

Leave a Reply

Your email address will not be published. Required fields are marked *