Commit 6c4011c
Creates the intermediate tmp folder before attempting to copy CHROMEDRIVER_FILEPATH to it.
Copying the binary no longer worked, unless the destination tmp folder already existed.
Steps to reproduce:
- rm -Rf /tmp/117.0.5938.92/chromedriver/
- CHROMEDRIVER_FILEPATH="/yourpathto/chromedriver" node node_modules/chromedriver/install.js
Failed with:
```
ChromeDriver installation failed Error: ENOENT: no such file or directory, copyfile '/tmp/chromedriver' -> '/tmp/117.0.5938.92/chromedriver/chromedriver-linux64/chromedriver'
at Object.copyFileSync (node:fs:2894:3)
at extractDownload (/home/anastasios/Sources/cloud/web/node_modules/chromedriver/install.js:364:8)
at install (/home/anastasios/Sources/cloud/web/node_modules/chromedriver/install.js:70:13)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
errno: -2,
syscall: 'copyfile',
code: 'ENOENT',
path: '/tmp/chromedriver',
dest: '/tmp/117.0.5938.92/chromedriver/chromedriver-linux64/chromedriver'
}
```
After this change it succeeds.1 parent afe9bf9 commit 6c4011c
1 file changed
+1
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
359 | 359 | | |
360 | 360 | | |
361 | 361 | | |
| 362 | + | |
362 | 363 | | |
363 | 364 | | |
364 | 365 | | |
| |||
0 commit comments