gauge-vscode
gauge-vscode copied to clipboard
Auto Save feature re-enables itself when a Gauge project is loaded
Every time a Gauge project is opened in VS Code, Auto Save becomes enabled on its own (well, I suspect the plugin is enabling it when it becomes active).
Observations
- I open VS Code then disable Auto Save (from Menu -> File -> Auto Save)
- Auto Save is not checked anymore
- I close VS Code
- reopen VS Code in a project that does not contain any .spec file (any file that triggers the gauge plugin to kick in) -> Auto Save is still disabled <<-- this is the expected behavior
- I close VS Code
- reopen VS Code in a Gauge project -> Auto Save becomes enabled (and not by the user, me) <<-- this is the issue
VS Code info:
Version: 1.33.1 Commit: 51b0b28134d51361cf996d2f0a1c698247aeabd8 Date: 2019-04-11T08:20:22.771Z 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-48-generic
Gauge plugin info:
Name: Gauge Id: getgauge.gauge Description: Gauge support for VScode. Version: 0.0.9 Publisher: getgauge VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=getgauge.gauge
Thanks! Gustavo.
Couldn't replicate the issue with the flow you have mentioned, seems to persist the user selected value of auto save.
Steps that I did try:
- Uninstalled existing extension and installed fresh 0.0.9 version of plugin
- Ignored optimise vscode setting for gauge pop up
- Tried enabling auto save
- closed and opened the project, this persisted the enabled setting.
- Disabled auto save and closed the window.
- opening the project again had the auto save disabled
Is there something different you are doing and also please verify if there are any extensions that is enabling auto save.
hum, that's weird. Now, to rule out the possibility of another extension changing the setting, I disabled Gauge, then repeated the experiment. The Auto Save setting remains disabled. One thing I noticed that we may have done differently: Once I opened the project, I had a .spec file already opened from the past. If I have no files opened already, the setting does not change at load time.
Now, I observe that my VS Code does a kind of reload or something the very first time that it opens a .spec file (I believe when the Gauge extension kicks in and starts adding decoration to my code otherwise inert code) and there is where the setting is changed.
So, to test on your side:
can you repeat the experiment, but this time after opening the project, also double clicking in a spec file to open it?
Thanks! Gustavo.
I have had a .spec
file opened previously too, dint help reproducing the issue. Which OS you are in ? I had tried in MacOs Mojave
Hi, sorry for not specifying that important detail before. I am on Ubuntu 16.04.
(oh, I now notice this is included in the VS Code info in the first post of this thread, to some extent)
Are there any Gauge debug logs that I would be able to take a look at for this? Thanks, Gustavo.
I can confirm that I see the same issue as @gusgonnet on my pop_os (based on ubuntu 19.04)
@gusgonnet Please look for Gauge > Recommended Settings > Options
in you User settings. Is it set to Apply & Reload

@gusgonnet Please look for
Gauge > Recommended Settings > Options
in you User settings. Is it set toApply & Reload
Hi @negiDharmendra ,
yes, I see it set to Apply and Reload:
Anything else to check? Thanks!
@gusgonnet Please set Gauge > Recommended Settings > Options
to Ignore
.
So that the recommended settings won't be applied by gauge plugin also the notification to apply recommended settings won't be shown again.
Hi @Apoorva-GA , that fixes this issue - thank you!
Reopening the issue, as the below mentioned behaviour will be helpful.
Expected behavior
When Gauge > Recommended Settings > Options
is set to Apply & Reload
, Recommended settings should be applied to the gauge-project and not globally.
Actual behavior
When Gauge > Recommended Settings > Options
is set to Apply & Reload
. Recommended settings are applied globally, which might affect non-gauge projects.
Version
gauge-vscode plugin : 0.0.11.nightly-2019-05-17