RIDE icon indicating copy to clipboard operation
RIDE copied to clipboard

AttributeError: module 'robotide.pluginapi' has no attribute 'RideLogMessage'

Open JFoederer opened this issue 4 years ago • 1 comments

After installing RIDE from Master (dd 30 April 2021) on Linux I tried to run my first simple test case. Somehow RIDE was unable to detect my Robot installation and while trying to tell me that RIDE raises this exception:

Traceback (most recent call last):
  File "/home/user/.local/lib/python3.8/site-packages/robotide/contrib/testrunner/testrunnerplugin.py", line 553, in OnTimer
    self.OnProcessEnded(None)
  File "/home/user/.local/lib/python3.8/site-packages/robotide/contrib/testrunner/testrunnerplugin.py", line 504, in OnProcessEnded
    output, errors, log_message = self._test_runner.get_output_and_errors(
  File "/home/user/.local/lib/python3.8/site-packages/robotide/contrib/testrunner/testrunner.py", line 173, in get_output_and_errors
    error, log_message = profile.format_error(stderr, returncode)
  File "/home/user/.local/lib/python3.8/site-packages/robotide/contrib/testrunner/runprofiles.py", line 117, in format_error
    return error, self._create_error_log_message(error, returncode)
  File "/home/user/.local/lib/python3.8/site-packages/robotide/contrib/testrunner/runprofiles.py", line 323, in _create_error_log_message
    return pluginapi.RideLogMessage(
AttributeError: module 'robotide.pluginapi' has no attribute 'RideLogMessage'

This exception keeps repeating in a live-lock and RIDE needs to be shut down to recover.

This is the code snippet that raises the exception in runprofiles.py:

        if b'not found' in error \
                or returncode == 127 or \
                b'system cannot find the file specified' in error:
            return pluginapi.RideLogMessage(
                RF_INSTALLATION_NOT_FOUND, notify_user=True)

JFoederer avatar Apr 30 '21 12:04 JFoederer

I have a fix in place by including this line in the __init__.py of the pluginapi package. from ..publish import RideLogMessage

I am not sure if that is correct place to include the import though.

JFoederer avatar Apr 30 '21 12:04 JFoederer

@JFoederer Please retest on new version 2.0b2.

HelioGuilherme66 avatar Sep 05 '22 11:09 HelioGuilherme66

@HelioGuilherme66 Can you please remind me where the RIDE logfile can be found on Linux? I installed the latest master, but now I have a hangup during startup. I'd like to check what is going on.

JFoederer avatar Sep 08 '22 09:09 JFoederer

Now I get a clear message informing me that Robot framework is not installed, plus a link to their website. Perfect!

JFoederer avatar Sep 30 '22 12:09 JFoederer