Help, How to execute SeleniumLibrary with Remote

I tried it using Remote ExampleLibrary.py
But, It Occured Error.

What is the problem?
Is there any way to fix it?

python ExampleLibrary.py TestIP PORT
#!/usr/bin/env python

from future import print_function

import os
import sys

from robotremoteserver import RobotRemoteServer
from SeleniumLibrary import SeleniumLibrary

try:
basestring
except NameError: # Python 3
basestring = str

class ExampleLibrary(SeleniumLibrary):
“”“Example library to be used with Robot Framework’s remote server.
This documentation is visible in docs generated by Libdoc.
“””
def init(self):
SeleniumLibrary.init(self)

if name == ‘main’:
RobotRemoteServer(ExampleLibrary(), *sys.argv[1:])

Outout


Traceback (most recent call last):
File “selen.py”, line 26, in
RobotRemoteServer(ExampleLibrary(), *sys.argv[1:])
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\robotremoteserver.py”, line 73, in init
self._library = RemoteLibraryFactory(library)
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\robotremoteserver.py”, line 259, in RemoteLibraryFactory
return DynamicRemoteLibrary(library, get_keyword_names, run_keyword)
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\robotremoteserver.py”, line 362, in init
HybridRemoteLibrary.init(self, library, get_keyword_names)
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\robotremoteserver.py”, line 355, in init
StaticRemoteLibrary.init(self, library)
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\robotremoteserver.py”, line 280, in init
self._names, self._robot_name_index = self._get_keyword_names(library)
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\robotremoteserver.py”, line 285, in get_keyword_names
for name, kw in inspect.getmembers(library):
File “C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\inspect.py”, line 350, in getmembers
value = getattr(object, key)
File "C:\Users\test\AppData\Local\Programs\Python\Python38-32\lib\site-packages\SeleniumLibrary_init
.py", line 563, in driver
raise NoOpenBrowser(“No browser is open.”)
SeleniumLibrary.errors.NoOpenBrowser: No browser is open.

  • robotframework 4.0
  • robotframework-autoitlibrary 1.2.7
  • robotframework-pythonlibcore 2.2.1
  • robotframework-ride 2.0b1
  • robotframework-seleniumlibrary 5.1.3
  • robotremoteserver 1.1
  • selenium 4.0.0b2.post1

Look here

SeleniumLibrary can not be used with Python remote server, because bug in Python remote server. SeleniumLibrary uses dynamic library API, but Python remove server tries to discover keywords with static library API. This should be fixes in Python remote server side.

Please raise an issue to the Python remote server issue tracker if one does not already exist.

Hi, pls let me know if there is a solution for this or at least point to the direction.

or still SeleniumLibrary can not be used with Python remote server

Trying to use SeleniumLibrary with RobotRemoteServer.