appiumappium-desktop

Unable to install appium@next


I am using "npm i -g appium@next" and "npm audit fix --force", which results in the following error: Windows 10 64 bit.

npm ERR! path C:\Users\shelly\node_modules\appium\node_modules\appium-chromedriver npm ERR! command failed npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node install-npm.js npm ERR! info Chromedriver Install Opening temp file to write chromedriver_win32 to... npm ERR! TypeError: os.tmpDir is not a function npm ERR!     at tempDir (C:\Users\shelly\node_modules\appium-support\lib\tempdir.js:14:31)

I tried to edit the file and change tmpDir to tmpdir, but the error persists. Full error log:

npm WARN deprecated appium-atoms@0.0.5: Package moved into appium-remote-debugger
npm WARN deprecated appium-uiauto@1.10.10: Use appium-ios-driver
npm WARN deprecated lodash-node@2.4.1: This package is discontinued. Use lodash@^4.0.0.
npm WARN deprecated appium-instruments@2.0.6: Use appium-ios-driver
npm WARN deprecated core-js@0.9.18: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
npm WARN deprecated core-js@1.2.7: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
npm WARN deprecated core-js@2.6.12: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
npm WARN cleanup Failed to remove some directories [
npm WARN cleanup   [
npm WARN cleanup     'C:\\Users\\shelly\\node_modules\\bufferutil',
npm WARN cleanup     [Error: EBUSY: resource busy or locked, rmdir 'C:\Users\shelly\node_modules\bufferutil'] {
npm WARN cleanup       errno: -4082,
npm WARN cleanup       code: 'EBUSY',
npm WARN cleanup       syscall: 'rmdir',
npm WARN cleanup       path: 'C:\\Users\\shelly\\node_modules\\bufferutil'
npm WARN cleanup     }
npm WARN cleanup   ],
npm WARN cleanup   [
npm WARN cleanup     'C:\\Users\\shelly\\node_modules\\utf-8-validate',
npm WARN cleanup     [Error: EBUSY: resource busy or locked, rmdir 'C:\Users\shelly\node_modules\utf-8-validate'] {
npm WARN cleanup       errno: -4082,
npm WARN cleanup       code: 'EBUSY',
npm WARN cleanup       syscall: 'rmdir',
npm WARN cleanup       path: 'C:\\Users\\shelly\\node_modules\\utf-8-validate'
npm WARN cleanup     }
npm WARN cleanup   ]
npm WARN cleanup ]
npm ERR! code 1
npm ERR! path C:\Users\shelly\node_modules\appium\node_modules\appium-chromedriver
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node install-npm.js
npm ERR! info Chromedriver Install Opening temp file to write chromedriver_win32 to...
npm ERR! TypeError: os.tmpDir is not a function
npm ERR!     at tempDir (C:\Users\shelly\node_modules\appium-support\lib\tempdir.js:14:31)
npm ERR!     at generateName (C:\Users\shelly\node_modules\appium-support\lib\tempdir.js:29:20)
npm ERR!     at Object.open (C:\Users\shelly\node_modules\appium-support\lib\tempdir.js:34:18)
npm ERR!     at Object.tryCatcher (C:\Users\shelly\node_modules\appium-support\node_modules\bluebird\js\main\util.js:26:23)
npm ERR!     at Object.ret [as open] (eval at makeNodePromisifiedEval (C:\Users\shelly\node_modules\appium-support\node_modules\bluebird\js\main\promisify.js:163:12), <anonymous>:13:39)
npm ERR!     at installForPlatform$ (C:\Users\shelly\node_modules\appium\node_modules\appium-chromedriver\build\lib\lib\install.js:80:32)
npm ERR!     at tryCatch (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:67:40)
npm ERR!     at GeneratorFunctionPrototype.invoke [as _invoke] (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:294:22)
npm ERR!     at GeneratorFunctionPrototype.prototype.<computed> [as next] (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:100:21)
npm ERR!     at invoke (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:136:37)
npm ERR!     at enqueueResult (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:167:17)
npm ERR!     at new Promise (<anonymous>)
npm ERR!     at new exp (C:\Users\shelly\node_modules\core-js\library\modules\$.def.js:38:36)
npm ERR!     at AsyncIterator.enqueue (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:166:12)
npm ERR!     at AsyncIterator.prototype.<computed> [as next] (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:100:21)
npm ERR!     at Object.runtime.async (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:192:12)
npm ERR!     at installForPlatform (C:\Users\shelly\node_modules\appium\node_modules\appium-chromedriver\build\lib\install.js:151:30)
npm ERR!     at install$ (C:\Users\shelly\node_modules\appium\node_modules\appium-chromedriver\build\lib\lib\install.js:122:9)
npm ERR!     at tryCatch (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:67:40)
npm ERR!     at GeneratorFunctionPrototype.invoke [as _invoke] (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:294:22)
npm ERR!     at GeneratorFunctionPrototype.prototype.<computed> [as next] (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:100:21)
npm ERR!     at GeneratorFunctionPrototype.invoke (C:\Users\shelly\node_modules\babel-runtime\regenerator\runtime.js:136:37)
npm ERR!     at processTicksAndRejections (node:internal/process/task_queues:96:5)

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\shelly\AppData\Local\npm-cache\_logs\2023-05-12T05_38_22_721Z-debug-0.log

Tried changing tmpDir to tmpdir based https://github.com/alhazmy13/serverless-offline-python/issues/18#issuecomment-666549117, but this does not apply.


Solution

  • Providing this response as a solution for anyone who encounters this issue in the future.

    Delete the folders "node_modules/appium" and "node_modules/appium-doctor" , than install appium using "npm i -g appium@next" should hopefully work