Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gauge: show last run report fails on error "command 'vscode.previewHtml' not found" #1384

Closed
gusgonnet opened this issue Apr 9, 2019 · 6 comments

Comments

@gusgonnet
Copy link

gusgonnet commented Apr 9, 2019

Expected behavior

Show last run report command succeeds

Actual behavior

Show last run report command fails, a popup with an error appears in VS Code:
command 'vscode.previewHtml' not found

Steps to reproduce

  1. Open a Gauge python project with VS Code
  2. CTRL SHIFT P to open command palette
  3. Hit on Gauge: Show Last Run Report
  4. an error is shown, no report is shown <- here is the problem I think

VS Code and Gauge plugin versions

VS Code

Version: 1.33.0
Commit: 0dd516dd412d42323fc3464531b1c715d51c4c1a
Date: 2019-04-04T15:08:57.775Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Linux x64 4.15.0-46-generic

VS Code plugin

V0.0.9

Gauge version


Gauge version: 1.0.4
Commit Hash: 3a9a647

Plugins
-------
csharp (0.10.5)
html-report (4.0.8)
java (0.7.2)
js (2.3.4)
python (0.3.5)
ruby (0.5.2)
screenshot (0.0.1)
spectacle (0.1.3)
xml-report (0.2.1)

Some analysis

Perhaps related to this:
Deprecating previewHtml #62630

I'm running this on Ubuntu 16.04.

Thank you!
Gustavo.

@gaugebot gaugebot bot added the community label Apr 9, 2019
@Apoorva-GA
Copy link
Contributor

Should be fixed as part of getgauge/gauge-vscode#354 and getgauge/gauge-vscode#362.
Please install Gauge-VSCode nightly to avail the changes.

@gusgonnet
Copy link
Author

Please install Gauge-VSCode nightly to avail the changes.

Thank you.

I just installed the nightly version gauge-0.0.10.nightly-2019-04-09.vsix and the error about previewHtml goes away, however the command Show last run report command does not give me anything.
Perhaps I'm not doing things right, but when I hit Gauge: Show last run report, it opens a new VS Code window but it remains empty.

Any other ideas?

I did run a spec:

13:31:33.349 Plugin python is already installed.
13:31:33.350 Plugin html-report is already installed.
13:31:33.803 Checking updates...
13:31:37.258 # Specification Heading
13:31:37.258 ## my first test
13:31:37.259 * create configuration 1
13:32:25.807 * Create configuration 2

13:34:12.698 Plugin [Html Report] with pid [32427] has exited
13:34:12.798 Specifications:	1 executed	1 passed	0 failed	0 skipped
13:34:12.798 Scenarios:	1 executed	1 passed	0 failed	0 skipped
13:34:12.798 
Total time taken: 2m35.363s

Thanks!

@Apoorva-GA
Copy link
Contributor

The behaviour of opening the report in VSCode editor has changed with this fix to open the report in browser.

13:34:12.698 Plugin [Html Report] with pid [32427] has exited

I see that html-report has exited and the reports are not generated as expected.
Is this happening consistently?

Steps to fallow:

  • Run spec from VSCode
  • Execute Gauge: Show last run report from command pallet

Note : Should open the report in the default browser.

@gusgonnet
Copy link
Author

Hi,
the html-report exits consistently like that ever since I installed Gauge for the first time (last week). Just went to the logs and double checked that it is the case. I'm on Ubuntu 16.04, in case it would matter.
From the fact that you are paying attention to it, I infer this is not normal.
Any way to figure out what is wrong?
However, it may be worth mentioning that if I open reports/html-report/index.html in a browser I'm able to see the report is generated properly and nicely.

If I run the steps you mention (run spec, then Gauge: Show last run report) it also consistently opens a new VS Code window that remains empty.

Thank you!
Gustavo.

@BugDiver
Copy link
Member

@gusgonnet As @Apoorva-GA mentioned we have removed support for inline html report inside vs code. Instead, we have added the feature to open the generated report in the default browser.

Could you try a few workarounds

  • Uninstall gauge-vscode extension
  • Just to make sure it is uninstalled properly delete ~/.vscode/extensions/getgauge.gauge*
  • Installed the latest nightly version of the extension again
  • Open the project, run and check if reports are generated properly

@gusgonnet
Copy link
Author

Hi @BugDiver
I did that already. However, I just did it again, with a reboot of my computer included, with same results:

run spec, then Gauge: Show last run report) opens a new VS Code window that remains empty

Anyhow, the issue I raised was about previewHtml and I know that you guys are aware of it and fixed it in an upcoming release so I'm happy.

Thank you for all the details!
Gustavo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants