Rayrun
← Back to Discord Forum

Unable to install Playwright in VS Code

Following the instructions on: https://playwright.dev/docs/getting-started-vscode

After installing the Playwright extension on Visual Studio Code, I've opened the command palette and typed "Install Playwright", which brings "Test: Install Playwright". I've clicked on it and the command palette just closes and nothing happens. Based on the page linked above, you should get options to select browsers and then you can proceed with the install.

I'm using the latest Visual Studio Code. Tried on both macOS and Windows. It was the same behavior on both.

Can anyone help me?

This thread is trying to answer question "Why does the command palette close and nothing happens when trying to install Playwright in Visual Studio Code?"

5 replies

Verify you have NodeJs is installed! If it still fails open terminal inside visual studio code . Run this command npm init playwright@latest

Also the extension be sure when you updated PW do everything. Doing the installed from inside Code, that will do "@latest", think that will get the latest PW, but may not match the VS extension. Can't remember i know when running with older verions say 1.2x one didn't need to update the VS extension all the time or i got lucky... Forgot the version, think it was 1.32, there was a breaking change more because some of the internal components in PW moved around and should be completely transparent except for ensureing the extension and PW match. Makes senses as we see the UI Mode getting more tightly integrated... So not updating the PW Extension could easily see issues and strange behaviors... After PW 1.32 i make it a point to update and double check all is updatd PW, the browsers and the VS code plug in whenever i update PW... Might be th first thing to ensure all is the latest...

@jaratlanta: Yeah, I ended up doing it this way which I've done outside of VS Code in the past. Unfortunately that VS Code command palette still closes on me no matter which computer or different OS I use. Thank you for the help!

Yeah, I ended up doing it this way which I've done outside of VS Code in the past. Unfortunately that VS Code command palette still closes on me no matter which computer or different OS I use. Thank you for the help!

@dand33: I've installed visual studio code and the playwright extension the same day, so everything was latest. Considering I tried different computers and different OSs, either I was doing something wrong or this is currently broken. Thank you for the help!

I've installed visual studio code and the playwright extension the same day, so everything was latest. Considering I tried different computers and different OSs, either I was doing something wrong or this is currently broken. Thank you for the help!

@mztik: No clue what the OS is. While i bet if you search the forum few people are running into this problem suggesting there may be something with you environment. Helping a couple others with this kind of issue there is something odd with your setup.

No clue what the OS is. While i bet if you search the forum few people are running into this problem suggesting there may be something with you environment. Helping a couple others with this kind of issue there is something odd with your setup.

Related Discord Threads

TwitterGitHubLinkedIn
AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email luc@ray.run.