robotcodedev / robotcode

RobotFramework support for Visual Studio Code
https://robotcode.io
Apache License 2.0
168 stars 13 forks source link

[QUESTION] Why the test starts on terminal but not from vscode/robotcode? #181

Closed Markspace83 closed 7 months ago

Markspace83 commented 8 months ago

Please describe.

When I run a robot test case that uses Firefox geckodriver, inside a container, from the vstudio code terminal everything runs fine. When trying to use robotcode GUI, clicking on the "play" button of the same test case, we get an error as Firefox won't load any webpage. (that is on the same environment, same python version, same container)

For running cases inside a container we use studio code with dev-containers plugin, along with robotcode.

The question is what is different running from terminal (robot command) vs running using the robotcode GUI in studio code that could cause this error?

Some additional info, The error I see in geckodriver.log (Firefox log) is the following:

DevTools listening on ws://127.0.0.1:35795/devtools/browser/341ea008-762b-4602-a652-7cf251fb74f4
1700221454475   Marionette  INFO    Stopped listening on port 35951
WARNING: A blocker encountered an error while we were waiting.
          Blocker:  Waiting for ping task
          Phase: TelemetryController: Waiting for pending ping activity
          State: (none)
WARNING: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange"
WARNING: addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:727:15
addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:523:26
addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:458:15
setupShutdown@resource://gre/modules/osfile/osfile_async_front.jsm:1548:28
@resource://gre/modules/osfile/osfile_async_front.jsm:1568:16
@resource://gre/modules/osfile.jsm:12:30
@resource://gre/modules/TelemetryStorage.sys.mjs:10:28
_checkPendingPings@resource://gre/modules/TelemetrySend.sys.mjs:863:17
setup@resource://gre/modules/TelemetrySend.sys.mjs:803:18
setup@resource://gre/modules/TelemetrySend.sys.mjs:241:30
setupTelemetry/this._delayedInitTask<@resource://gre/modules/TelemetryControllerParent.sys.mjs:829:36
observe@resource://gre/modules/AsyncShutdown.sys.mjs:576:16 

It closely resembles this issue refered in SeleniumHQ github: https://github.com/SeleniumHQ/selenium/issues/11795

This only occurs when we use robotcode to run via studio code. It does not happen from a terminal within the container. I was hoping maybe there is an idea of what might be different in execution that may be causing this.

Desktop (please complete the following information):

Thanks

d-biehl commented 8 months ago

Unfortunately, I can't say exactly what could be causing this.

What error message does the test abort with when you start it from VSCode? What error is in the Robot log.html?

And how do you start the test run in the terminal? Maybe something needs to be configured in VSCode to make the same call. Or have you already done that?

d-biehl commented 7 months ago

ok, because I have not received any feedback, I assume that the error has been fixed and close this issue.