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

Reset nwConfig before refreshing for a new one #42

Open
garg3133 opened this issue Feb 16, 2024 · 0 comments
Open

Reset nwConfig before refreshing for a new one #42

garg3133 opened this issue Feb 16, 2024 · 0 comments

Comments

@garg3133
Copy link
Member

Before re-requireing the Nightwatch config file, we should always reset the nwConfig from workspaceState, otherwise if there is some error in the config file or the config file has altogether been deleted, Nightwatch VSCode extension will just keep on showing the old environments in the Environments Panel and no information of the error will be transmitted to the user in any way, which is quite misleading and bad UX, as the extension will stop working and the user wouldn't know why.

Ex. in the development mode, if I delete the nightwatch.conf.js file, it shows error in the Debug Console of my development environment:

image

but the environments in the Environments Panel remains the same with no error/warning being transmitted to the user:

image

Reseting the nwConfig before requireing a new one would at least reset the envs in Environments Panel and in case there is an error, we should show it to the user (maybe in form of a pop-up?).

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

No branches or pull requests

1 participant