Load extensions on Windows
See original GitHub issueSteps to reproduce
Tell us about your environment:
- Puppeteer version: 1.5.0
- Platform / OS version: Windows 10
- URLs (if applicable):
- Node.js version: 9
What steps will reproduce the problem?
Please include code that reproduces the issue.
I needed to load a extension that a page requires, so I added --disable-extensions-except
and --load-extension
args but it doesn’t load on windows. The full args I passed were:
[ '--enable-logging',
'--v=1',
'about:blank',
'--disable-extensions-except="C:\\Users\\...\\chrome-extensions"',
'--load-extension="C:\\Users\\...\\chrome-extensions"' ]
And the result was:
---------------------------
Error Loading Extension
---------------------------
Failed to load extension from:
C:\Users\...\...\...\node_modules\puppeteer\.local-chromium\win64-564778\chrome-win32\"C:\Users\...\chrome-extensions". Manifest file is missing or unreadable.
---------------------------
OK
---------------------------
What is the expected result?
Load extensions properly.
What happens instead?
---------------------------
Error Loading Extension
---------------------------
Failed to load extension from:
C:\Users\...\...\...\node_modules\puppeteer\.local-chromium\win64-564778\chrome-win32\"C:\Users\...\chrome-extensions". Manifest file is missing or unreadable.
---------------------------
OK
---------------------------
I think if I pass the extension path as a relative path it might be work but I also think that is so awful.
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (1 by maintainers)
Top Results From Across the Web
Install and Manage Extensions | Microsoft Learn
Installing an extension · Click the Settings button in the top-right > In the left pane, click Extensions. · The Available Extensions tab...
Read more >How to Add Extensions or Add-ons to Your Browser
Microsoft Edge · In the new window, under Find new extensions, click the Get extensions button in Edge. button. · In the upper-left...
Read more >Installing a PHP extension on Windows - Manual
On Windows, you have two ways to load a PHP extension: either compile it into PHP, or load the DLL. Loading a pre-compiled...
Read more >Managing Extensions in Visual Studio Code
To install an extension, select the Install button. Once the installation is complete, the Install button will change to the Manage gear button....
Read more >How to Install PHP Extensions on Windows? - GeeksforGeeks
Installing PHP Extensions on Windows ... To install PHP extension we need to follow the following steps: Step 1: Click on the Config...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
but then it does not load any extentions
I finally fixed this exact error/issue with ublock. I had originally made several errors. It now works.
Here’s the working code:
In /puppeteer-extensions/, I changed /chromium.ublock0.152341/ or whatever to plain /ublock/, and deleted a nested sub-directory with an equally funky name. Within /ublock/ there is a manifest.json. Many extensions have multiple layers of weird-named directories. Change the dir names to something simple like /ublock/, and then make sure your line declaring the extension has that directory path typed perfectly in your code.
@Ajju2211 I think you should unzip the extension and absolute/relative path to the directory that contains manifest.json.