appium-mac2-driver 4.6.0 → 4.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/WebDriverAgentMac/WebDriverAgentRunner/WebDriverAgentRunner.m +3 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/LICENSE +203 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/README.md +258 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncfilter.d.ts +9 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncfilter.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncfilter.js +35 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncfilter.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncmap.d.ts +9 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncmap.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncmap.js +23 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/asyncmap.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/errors.d.ts +9 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/errors.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/errors.js +20 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/errors.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/index.d.ts +12 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/index.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/index.js +24 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/index.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/limit-function.d.ts +3 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/limit-function.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/limit-function.js +15 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/limit-function.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/lock.d.ts +74 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/lock.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/lock.js +295 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/lock.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/long-sleep.d.ts +15 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/long-sleep.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/long-sleep.js +36 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/long-sleep.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/retry.d.ts +17 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/retry.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/retry.js +57 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/retry.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/sleep.d.ts +20 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/sleep.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/sleep.js +61 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/sleep.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/types.d.ts +84 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/types.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/types.js +3 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/types.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts +18 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js +51 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.d.ts +16 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.js +45 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/package.json +3 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncfilter.d.ts +9 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncfilter.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncfilter.js +32 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncfilter.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncmap.d.ts +9 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncmap.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncmap.js +20 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncmap.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/errors.d.ts +9 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/errors.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/errors.js +15 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/errors.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/index.d.ts +12 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/index.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/index.js +10 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/index.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.d.ts +3 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.js +12 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/lock.d.ts +74 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/lock.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/lock.js +291 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/lock.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/long-sleep.d.ts +15 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/long-sleep.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/long-sleep.js +33 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/long-sleep.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/retry.d.ts +17 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/retry.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/retry.js +53 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/retry.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/sleep.d.ts +20 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/sleep.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/sleep.js +58 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/sleep.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/types.d.ts +84 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/types.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/types.js +2 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/types.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/wait-for-condition.d.ts +18 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/wait-for-condition.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/wait-for-condition.js +48 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/wait-for-condition.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/with-timeout.d.ts +16 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/with-timeout.d.ts.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/with-timeout.js +42 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/with-timeout.js.map +1 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/package.json +3 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/asyncfilter.ts +38 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/asyncmap.ts +29 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/errors.ts +15 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/index.ts +21 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/limit-function.ts +18 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/lock.ts +360 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/long-sleep.ts +38 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/retry.ts +61 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/sleep.ts +79 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/types.ts +88 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/wait-for-condition.ts +52 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/lib/with-timeout.ts +43 -0
- package/node_modules/@appium/base-driver/node_modules/asyncbox/package.json +74 -0
- package/node_modules/@appium/support/node_modules/asyncbox/LICENSE +203 -0
- package/node_modules/@appium/support/node_modules/asyncbox/README.md +258 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncfilter.d.ts +9 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncfilter.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncfilter.js +35 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncfilter.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncmap.d.ts +9 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncmap.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncmap.js +23 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/asyncmap.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/errors.d.ts +9 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/errors.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/errors.js +20 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/errors.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/index.d.ts +12 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/index.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/index.js +24 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/index.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/limit-function.d.ts +3 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/limit-function.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/limit-function.js +15 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/limit-function.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/lock.d.ts +74 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/lock.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/lock.js +295 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/lock.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/long-sleep.d.ts +15 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/long-sleep.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/long-sleep.js +36 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/long-sleep.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/retry.d.ts +17 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/retry.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/retry.js +57 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/retry.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/sleep.d.ts +20 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/sleep.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/sleep.js +61 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/sleep.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/types.d.ts +84 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/types.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/types.js +3 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/types.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts +18 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js +51 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/with-timeout.d.ts +16 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/with-timeout.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/with-timeout.js +45 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/lib/with-timeout.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/cjs/package.json +3 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncfilter.d.ts +9 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncfilter.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncfilter.js +32 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncfilter.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncmap.d.ts +9 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncmap.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncmap.js +20 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/asyncmap.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/errors.d.ts +9 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/errors.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/errors.js +15 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/errors.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/index.d.ts +12 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/index.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/index.js +10 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/index.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/limit-function.d.ts +3 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/limit-function.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/limit-function.js +12 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/limit-function.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/lock.d.ts +74 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/lock.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/lock.js +291 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/lock.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/long-sleep.d.ts +15 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/long-sleep.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/long-sleep.js +33 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/long-sleep.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/retry.d.ts +17 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/retry.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/retry.js +53 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/retry.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/sleep.d.ts +20 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/sleep.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/sleep.js +58 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/sleep.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/types.d.ts +84 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/types.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/types.js +2 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/types.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/wait-for-condition.d.ts +18 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/wait-for-condition.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/wait-for-condition.js +48 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/wait-for-condition.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/with-timeout.d.ts +16 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/with-timeout.d.ts.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/with-timeout.js +42 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/lib/with-timeout.js.map +1 -0
- package/node_modules/@appium/support/node_modules/asyncbox/build/esm/package.json +3 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/asyncfilter.ts +38 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/asyncmap.ts +29 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/errors.ts +15 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/index.ts +21 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/limit-function.ts +18 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/lock.ts +360 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/long-sleep.ts +38 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/retry.ts +61 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/sleep.ts +79 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/types.ts +88 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/wait-for-condition.ts +52 -0
- package/node_modules/@appium/support/node_modules/asyncbox/lib/with-timeout.ts +43 -0
- package/node_modules/@appium/support/node_modules/asyncbox/package.json +74 -0
- package/node_modules/asyncbox/README.md +18 -4
- package/node_modules/asyncbox/build/cjs/lib/errors.d.ts +20 -2
- package/node_modules/asyncbox/build/cjs/lib/errors.d.ts.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/errors.js +41 -6
- package/node_modules/asyncbox/build/cjs/lib/errors.js.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/index.d.ts +1 -1
- package/node_modules/asyncbox/build/cjs/lib/index.d.ts.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/index.js +5 -1
- package/node_modules/asyncbox/build/cjs/lib/index.js.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/lock.d.ts.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/lock.js +6 -5
- package/node_modules/asyncbox/build/cjs/lib/lock.js.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts +1 -1
- package/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts.map +1 -1
- package/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js +4 -3
- package/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/errors.d.ts +20 -2
- package/node_modules/asyncbox/build/esm/lib/errors.d.ts.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/errors.js +36 -5
- package/node_modules/asyncbox/build/esm/lib/errors.js.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/index.d.ts +1 -1
- package/node_modules/asyncbox/build/esm/lib/index.d.ts.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/index.js +1 -1
- package/node_modules/asyncbox/build/esm/lib/index.js.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/lock.d.ts.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/lock.js +6 -5
- package/node_modules/asyncbox/build/esm/lib/lock.js.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/wait-for-condition.d.ts +1 -1
- package/node_modules/asyncbox/build/esm/lib/wait-for-condition.d.ts.map +1 -1
- package/node_modules/asyncbox/build/esm/lib/wait-for-condition.js +4 -3
- package/node_modules/asyncbox/build/esm/lib/wait-for-condition.js.map +1 -1
- package/node_modules/asyncbox/lib/errors.ts +41 -5
- package/node_modules/asyncbox/lib/index.ts +8 -1
- package/node_modules/asyncbox/lib/lock.ts +7 -5
- package/node_modules/asyncbox/lib/wait-for-condition.ts +4 -3
- package/node_modules/asyncbox/package.json +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.sleep = sleep;
|
|
4
|
+
const errors_js_1 = require("./errors.js");
|
|
5
|
+
function sleep(arg) {
|
|
6
|
+
const { ms, cancelError } = parseSleepArg(arg);
|
|
7
|
+
let timeoutId;
|
|
8
|
+
let resolveFn;
|
|
9
|
+
let rejectFn;
|
|
10
|
+
const promise = new Promise((resolve, reject) => {
|
|
11
|
+
resolveFn = resolve;
|
|
12
|
+
rejectFn = reject;
|
|
13
|
+
timeoutId = setTimeout(resolve, ms);
|
|
14
|
+
});
|
|
15
|
+
promise.cancel = () => {
|
|
16
|
+
if (timeoutId) {
|
|
17
|
+
clearTimeout(timeoutId);
|
|
18
|
+
timeoutId = undefined;
|
|
19
|
+
}
|
|
20
|
+
if (cancelError === null) {
|
|
21
|
+
resolveFn?.(undefined);
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
let err;
|
|
25
|
+
if (typeof cancelError === 'string' && cancelError) {
|
|
26
|
+
err = new errors_js_1.PromiseCancellationError(cancelError);
|
|
27
|
+
}
|
|
28
|
+
else if (cancelError instanceof Error) {
|
|
29
|
+
err = cancelError;
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
err = new errors_js_1.PromiseCancellationError();
|
|
33
|
+
}
|
|
34
|
+
rejectFn?.(err);
|
|
35
|
+
}
|
|
36
|
+
resolveFn = undefined;
|
|
37
|
+
rejectFn = undefined;
|
|
38
|
+
};
|
|
39
|
+
return promise;
|
|
40
|
+
}
|
|
41
|
+
/** Non-array object values (including class instances); excludes `null` and arrays. */
|
|
42
|
+
function isSleepArgObject(value) {
|
|
43
|
+
return value !== null && typeof value === 'object' && !Array.isArray(value);
|
|
44
|
+
}
|
|
45
|
+
function parseSleepArg(arg) {
|
|
46
|
+
if (typeof arg === 'number') {
|
|
47
|
+
if (!Number.isFinite(arg)) {
|
|
48
|
+
throw new TypeError('sleep: expected a finite number or an object with ms');
|
|
49
|
+
}
|
|
50
|
+
return { ms: arg };
|
|
51
|
+
}
|
|
52
|
+
if (isSleepArgObject(arg)) {
|
|
53
|
+
const ms = arg.ms;
|
|
54
|
+
if (typeof ms !== 'number' || !Number.isFinite(ms)) {
|
|
55
|
+
throw new TypeError('sleep: options.ms must be a finite number');
|
|
56
|
+
}
|
|
57
|
+
return { ms, cancelError: arg.cancelError };
|
|
58
|
+
}
|
|
59
|
+
throw new TypeError('sleep: expected a finite number or an object with ms');
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=sleep.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sleep.js","sourceRoot":"","sources":["../../../lib/sleep.ts"],"names":[],"mappings":";;AAqBA,sBAmCC;AAxDD,2CAAqD;AAqBrD,SAAgB,KAAK,CAAC,GAAa;IACjC,MAAM,EAAC,EAAE,EAAE,WAAW,EAAC,GAAG,aAAa,CAAC,GAAG,CAAC,CAAC;IAC7C,IAAI,SAAqC,CAAC;IAC1C,IAAI,SAA8C,CAAC;IACnD,IAAI,QAA8C,CAAC;IAEnD,MAAM,OAAO,GAAG,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QACpD,SAAS,GAAG,OAAO,CAAC;QACpB,QAAQ,GAAG,MAAM,CAAC;QAClB,SAAS,GAAG,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC;IACtC,CAAC,CAA6B,CAAC;IAE/B,OAAO,CAAC,MAAM,GAAG,GAAG,EAAE;QACpB,IAAI,SAAS,EAAE,CAAC;YACd,YAAY,CAAC,SAAS,CAAC,CAAC;YACxB,SAAS,GAAG,SAAS,CAAC;QACxB,CAAC;QACD,IAAI,WAAW,KAAK,IAAI,EAAE,CAAC;YACzB,SAAS,EAAE,CAAC,SAAS,CAAC,CAAC;QACzB,CAAC;aAAM,CAAC;YACN,IAAI,GAAU,CAAC;YACf,IAAI,OAAO,WAAW,KAAK,QAAQ,IAAI,WAAW,EAAE,CAAC;gBACnD,GAAG,GAAG,IAAI,oCAAwB,CAAC,WAAW,CAAC,CAAC;YAClD,CAAC;iBAAM,IAAI,WAAW,YAAY,KAAK,EAAE,CAAC;gBACxC,GAAG,GAAG,WAAW,CAAC;YACpB,CAAC;iBAAM,CAAC;gBACN,GAAG,GAAG,IAAI,oCAAwB,EAAE,CAAC;YACvC,CAAC;YACD,QAAQ,EAAE,CAAC,GAAG,CAAC,CAAC;QAClB,CAAC;QACD,SAAS,GAAG,SAAS,CAAC;QACtB,QAAQ,GAAG,SAAS,CAAC;IACvB,CAAC,CAAC;IAEF,OAAO,OAAO,CAAC;AACjB,CAAC;AAED,uFAAuF;AACvF,SAAS,gBAAgB,CAAC,KAAc;IACtC,OAAO,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAC9E,CAAC;AAED,SAAS,aAAa,CAAC,GAAa;IAClC,IAAI,OAAO,GAAG,KAAK,QAAQ,EAAE,CAAC;QAC5B,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;YAC1B,MAAM,IAAI,SAAS,CAAC,sDAAsD,CAAC,CAAC;QAC9E,CAAC;QACD,OAAO,EAAC,EAAE,EAAE,GAAG,EAAC,CAAC;IACnB,CAAC;IACD,IAAI,gBAAgB,CAAC,GAAG,CAAC,EAAE,CAAC;QAC1B,MAAM,EAAE,GAAG,GAAG,CAAC,EAAE,CAAC;QAClB,IAAI,OAAO,EAAE,KAAK,QAAQ,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,CAAC;YACnD,MAAM,IAAI,SAAS,CAAC,2CAA2C,CAAC,CAAC;QACnE,CAAC;QACD,OAAO,EAAC,EAAE,EAAE,WAAW,EAAE,GAAG,CAAC,WAAgD,EAAC,CAAC;IACjF,CAAC;IACD,MAAM,IAAI,SAAS,CAAC,sDAAsD,CAAC,CAAC;AAC9E,CAAC"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parameter provided to a progress callback
|
|
3
|
+
*/
|
|
4
|
+
export interface Progress {
|
|
5
|
+
/** Elapsed time in milliseconds since the operation started */
|
|
6
|
+
elapsedMs: number;
|
|
7
|
+
/** Remaining time in milliseconds until the operation completes */
|
|
8
|
+
timeLeft: number;
|
|
9
|
+
/** Progress as a number between 0 and 1 (0 = not started, 1 = complete) */
|
|
10
|
+
progress: number;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Progress callback for {@link longSleep}
|
|
14
|
+
*/
|
|
15
|
+
export type ProgressCallback = (progress: Progress) => void;
|
|
16
|
+
/**
|
|
17
|
+
* Options for {@link longSleep}
|
|
18
|
+
*/
|
|
19
|
+
export interface LongSleepOptions {
|
|
20
|
+
/** Minimum duration in milliseconds before using long sleep behavior.
|
|
21
|
+
* @default 5000
|
|
22
|
+
*/
|
|
23
|
+
thresholdMs?: number;
|
|
24
|
+
/** Interval in milliseconds between progress callbacks.
|
|
25
|
+
* @default 1000
|
|
26
|
+
*/
|
|
27
|
+
intervalMs?: number;
|
|
28
|
+
/** Optional callback function to receive progress updates during the sleep */
|
|
29
|
+
progressCb?: ProgressCallback | null;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Options for {@link asyncmap} and {@link asyncfilter}
|
|
33
|
+
*/
|
|
34
|
+
export type MapFilterOptions = boolean | {
|
|
35
|
+
concurrency: number;
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* Object form of {@link sleep}'s argument: duration plus optional cancellation rejection override.
|
|
39
|
+
* Structural typing allows class instances; {@link sleep} accepts any non-array object with a finite `ms`.
|
|
40
|
+
*/
|
|
41
|
+
export interface SleepOptions {
|
|
42
|
+
/** Duration in milliseconds */
|
|
43
|
+
ms: number;
|
|
44
|
+
/**
|
|
45
|
+
* When {@link sleep}'s `cancel` runs: a non-empty string becomes {@link PromiseCancellationError}
|
|
46
|
+
* with that message; an `Error` rejects with that same instance; `null` resolves the promise
|
|
47
|
+
* instead of rejecting; omitted, `undefined`, or `''` use the default {@link PromiseCancellationError}.
|
|
48
|
+
*/
|
|
49
|
+
cancelError?: string | Error | null;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Argument to {@link sleep}: either milliseconds or an options object (see {@link SleepOptions}).
|
|
53
|
+
*/
|
|
54
|
+
export type SleepArg = number | SleepOptions;
|
|
55
|
+
/**
|
|
56
|
+
* A promise with a {@linkcode cancel} method (e.g. from {@link sleep}).
|
|
57
|
+
*
|
|
58
|
+
* @typeParam T - Resolved value type; {@link sleep} uses `void`.
|
|
59
|
+
*/
|
|
60
|
+
export type CancellablePromise<T = void> = Promise<T> & {
|
|
61
|
+
cancel: () => void;
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* Options for {@link waitForCondition}
|
|
65
|
+
*/
|
|
66
|
+
export interface WaitForConditionOptions {
|
|
67
|
+
/** Maximum time to wait in milliseconds.
|
|
68
|
+
* @default 5000
|
|
69
|
+
*/
|
|
70
|
+
waitMs?: number;
|
|
71
|
+
/** Interval in milliseconds between condition checks.
|
|
72
|
+
* @default 500
|
|
73
|
+
*/
|
|
74
|
+
intervalMs?: number;
|
|
75
|
+
/** Optional logger object with a debug method for logging wait progress */
|
|
76
|
+
logger?: {
|
|
77
|
+
debug: (...args: any[]) => void;
|
|
78
|
+
};
|
|
79
|
+
/** Custom error message (string) or Error object to throw if condition is not met.
|
|
80
|
+
* If not provided, a default error is thrown
|
|
81
|
+
*/
|
|
82
|
+
error?: string | Error;
|
|
83
|
+
}
|
|
84
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../lib/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,QAAQ;IACvB,+DAA+D;IAC/D,SAAS,EAAE,MAAM,CAAC;IAClB,mEAAmE;IACnE,QAAQ,EAAE,MAAM,CAAC;IACjB,2EAA2E;IAC3E,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,QAAQ,EAAE,QAAQ,KAAK,IAAI,CAAC;AAE5D;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,8EAA8E;IAC9E,UAAU,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAC;CACtC;AAED;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,OAAO,GAAG;IAAC,WAAW,EAAE,MAAM,CAAA;CAAC,CAAC;AAE/D;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,+BAA+B;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX;;;;OAIG;IACH,WAAW,CAAC,EAAE,MAAM,GAAG,KAAK,GAAG,IAAI,CAAC;CACrC;AAED;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,YAAY,CAAC;AAE7C;;;;GAIG;AACH,MAAM,MAAM,kBAAkB,CAAC,CAAC,GAAG,IAAI,IAAI,OAAO,CAAC,CAAC,CAAC,GAAG;IACtD,MAAM,EAAE,MAAM,IAAI,CAAC;CACpB,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2EAA2E;IAC3E,MAAM,CAAC,EAAE;QACP,KAAK,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC;KACjC,CAAC;IACF;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;CACxB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../lib/types.ts"],"names":[],"mappings":""}
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/wait-for-condition.d.ts
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { WaitForConditionOptions } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Takes a condition (a function returning a boolean or boolean promise), and
|
|
4
|
+
* waits until the condition is true.
|
|
5
|
+
*
|
|
6
|
+
* Throws a `/Condition unmet/` error if the condition has not been satisfied
|
|
7
|
+
* within the allocated time, unless an error is provided in the options, as the
|
|
8
|
+
* `error` property, which is either thrown itself, or used as the message.
|
|
9
|
+
*
|
|
10
|
+
* The condition result is returned if it is not falsy. If the condition throws an
|
|
11
|
+
* error then this exception will be immediately passed through.
|
|
12
|
+
*
|
|
13
|
+
* The default options are: `{ waitMs: 5000, intervalMs: 500 }`
|
|
14
|
+
* @param condFn - The condition function to evaluate
|
|
15
|
+
* @param options - Options for controlling the wait behavior
|
|
16
|
+
*/
|
|
17
|
+
export declare function waitForCondition<T>(condFn: () => Promise<T> | T, options?: WaitForConditionOptions): Promise<T>;
|
|
18
|
+
//# sourceMappingURL=wait-for-condition.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wait-for-condition.d.ts","sourceRoot":"","sources":["../../../lib/wait-for-condition.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,uBAAuB,EAAC,MAAM,YAAY,CAAC;AAExD;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,gBAAgB,CAAC,CAAC,EACtC,MAAM,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,GAAG,CAAC,EAC5B,OAAO,GAAE,uBAA4B,GACpC,OAAO,CAAC,CAAC,CAAC,CA8BZ"}
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/wait-for-condition.js
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.waitForCondition = waitForCondition;
|
|
4
|
+
const sleep_js_1 = require("./sleep.js");
|
|
5
|
+
/**
|
|
6
|
+
* Takes a condition (a function returning a boolean or boolean promise), and
|
|
7
|
+
* waits until the condition is true.
|
|
8
|
+
*
|
|
9
|
+
* Throws a `/Condition unmet/` error if the condition has not been satisfied
|
|
10
|
+
* within the allocated time, unless an error is provided in the options, as the
|
|
11
|
+
* `error` property, which is either thrown itself, or used as the message.
|
|
12
|
+
*
|
|
13
|
+
* The condition result is returned if it is not falsy. If the condition throws an
|
|
14
|
+
* error then this exception will be immediately passed through.
|
|
15
|
+
*
|
|
16
|
+
* The default options are: `{ waitMs: 5000, intervalMs: 500 }`
|
|
17
|
+
* @param condFn - The condition function to evaluate
|
|
18
|
+
* @param options - Options for controlling the wait behavior
|
|
19
|
+
*/
|
|
20
|
+
async function waitForCondition(condFn, options = {}) {
|
|
21
|
+
const opts = {
|
|
22
|
+
...options,
|
|
23
|
+
waitMs: typeof options.waitMs === 'number' ? options.waitMs : 5000,
|
|
24
|
+
intervalMs: typeof options.intervalMs === 'number' ? options.intervalMs : 500,
|
|
25
|
+
};
|
|
26
|
+
const debug = opts.logger ? opts.logger.debug.bind(opts.logger) : () => undefined;
|
|
27
|
+
const error = opts.error;
|
|
28
|
+
const begunAt = performance.now();
|
|
29
|
+
const endAt = begunAt + opts.waitMs;
|
|
30
|
+
const spin = async function spin() {
|
|
31
|
+
const result = await condFn();
|
|
32
|
+
if (result) {
|
|
33
|
+
return result;
|
|
34
|
+
}
|
|
35
|
+
const now = performance.now();
|
|
36
|
+
const waited = Math.round(now - begunAt);
|
|
37
|
+
const remainingTime = endAt - now;
|
|
38
|
+
if (now < endAt) {
|
|
39
|
+
debug(`Waited for ${waited} ms so far`);
|
|
40
|
+
await (0, sleep_js_1.sleep)(Math.min(opts.intervalMs, remainingTime));
|
|
41
|
+
return await spin();
|
|
42
|
+
}
|
|
43
|
+
// if there is an error option, it is either a string message or an error itself
|
|
44
|
+
if (error) {
|
|
45
|
+
throw typeof error === 'string' ? new Error(error) : error;
|
|
46
|
+
}
|
|
47
|
+
throw new Error(`Condition unmet after ${waited} ms. Timing out.`);
|
|
48
|
+
};
|
|
49
|
+
return await spin();
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=wait-for-condition.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wait-for-condition.js","sourceRoot":"","sources":["../../../lib/wait-for-condition.ts"],"names":[],"mappings":";;AAkBA,4CAiCC;AAnDD,yCAAiC;AAGjC;;;;;;;;;;;;;;GAcG;AACI,KAAK,UAAU,gBAAgB,CACpC,MAA4B,EAC5B,UAAmC,EAAE;IAErC,MAAM,IAAI,GAAmE;QAC3E,GAAG,OAAO;QACV,MAAM,EAAE,OAAO,OAAO,CAAC,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI;QAClE,UAAU,EAAE,OAAO,OAAO,CAAC,UAAU,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,GAAG;KAC9E,CAAC;IACF,MAAM,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC;IAClF,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;IACzB,MAAM,OAAO,GAAG,WAAW,CAAC,GAAG,EAAE,CAAC;IAClC,MAAM,KAAK,GAAG,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC;IACpC,MAAM,IAAI,GAAG,KAAK,UAAU,IAAI;QAC9B,MAAM,MAAM,GAAG,MAAM,MAAM,EAAE,CAAC;QAC9B,IAAI,MAAM,EAAE,CAAC;YACX,OAAO,MAAM,CAAC;QAChB,CAAC;QACD,MAAM,GAAG,GAAG,WAAW,CAAC,GAAG,EAAE,CAAC;QAC9B,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,GAAG,OAAO,CAAC,CAAC;QACzC,MAAM,aAAa,GAAG,KAAK,GAAG,GAAG,CAAC;QAClC,IAAI,GAAG,GAAG,KAAK,EAAE,CAAC;YAChB,KAAK,CAAC,cAAc,MAAM,YAAY,CAAC,CAAC;YACxC,MAAM,IAAA,gBAAK,EAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,UAAU,EAAE,aAAa,CAAC,CAAC,CAAC;YACtD,OAAO,MAAM,IAAI,EAAE,CAAC;QACtB,CAAC;QACD,gFAAgF;QAChF,IAAI,KAAK,EAAE,CAAC;YACV,MAAM,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;QAC7D,CAAC;QACD,MAAM,IAAI,KAAK,CAAC,yBAAyB,MAAM,kBAAkB,CAAC,CAAC;IACrE,CAAC,CAAC;IACF,OAAO,MAAM,IAAI,EAAE,CAAC;AACtB,CAAC"}
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Resolves with `promise` or rejects if it does not settle before `timeoutMs`.
|
|
3
|
+
*
|
|
4
|
+
* If the deadline passes first: with no third argument (or a falsy non-error value), rejects
|
|
5
|
+
* with {@link TimeoutError} whose message includes `timeoutMs`; with a non-empty string,
|
|
6
|
+
* rejects with {@link TimeoutError} using that message; with an `Error` instance, rejects
|
|
7
|
+
* with that same instance.
|
|
8
|
+
*
|
|
9
|
+
* @param promise - Promise to race against the timeout.
|
|
10
|
+
* @param timeoutMs - Maximum time in milliseconds before rejecting if `promise` has not settled.
|
|
11
|
+
* @param messageOrError - Optional override for the timeout rejection: custom {@link TimeoutError}
|
|
12
|
+
* message when the string is non-empty, or an existing `Error` to reject with verbatim.
|
|
13
|
+
* Omitted, `undefined`, or other falsy non-error values use the default timeout message (includes `timeoutMs`).
|
|
14
|
+
*/
|
|
15
|
+
export declare function withTimeout<T>(promise: Promise<T>, timeoutMs: number, messageOrError?: string | Error): Promise<T>;
|
|
16
|
+
//# sourceMappingURL=with-timeout.d.ts.map
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"with-timeout.d.ts","sourceRoot":"","sources":["../../../lib/with-timeout.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;GAaG;AACH,wBAAsB,WAAW,CAAC,CAAC,EACjC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,EACnB,SAAS,EAAE,MAAM,EACjB,cAAc,CAAC,EAAE,MAAM,GAAG,KAAK,GAC9B,OAAO,CAAC,CAAC,CAAC,CAsBZ"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.withTimeout = withTimeout;
|
|
4
|
+
const errors_js_1 = require("./errors.js");
|
|
5
|
+
/**
|
|
6
|
+
* Resolves with `promise` or rejects if it does not settle before `timeoutMs`.
|
|
7
|
+
*
|
|
8
|
+
* If the deadline passes first: with no third argument (or a falsy non-error value), rejects
|
|
9
|
+
* with {@link TimeoutError} whose message includes `timeoutMs`; with a non-empty string,
|
|
10
|
+
* rejects with {@link TimeoutError} using that message; with an `Error` instance, rejects
|
|
11
|
+
* with that same instance.
|
|
12
|
+
*
|
|
13
|
+
* @param promise - Promise to race against the timeout.
|
|
14
|
+
* @param timeoutMs - Maximum time in milliseconds before rejecting if `promise` has not settled.
|
|
15
|
+
* @param messageOrError - Optional override for the timeout rejection: custom {@link TimeoutError}
|
|
16
|
+
* message when the string is non-empty, or an existing `Error` to reject with verbatim.
|
|
17
|
+
* Omitted, `undefined`, or other falsy non-error values use the default timeout message (includes `timeoutMs`).
|
|
18
|
+
*/
|
|
19
|
+
async function withTimeout(promise, timeoutMs, messageOrError) {
|
|
20
|
+
let timer = null;
|
|
21
|
+
try {
|
|
22
|
+
return await Promise.race([
|
|
23
|
+
promise,
|
|
24
|
+
new Promise((_resolve, reject) => {
|
|
25
|
+
timer = setTimeout(() => {
|
|
26
|
+
if (typeof messageOrError === 'string' && messageOrError) {
|
|
27
|
+
reject(new errors_js_1.TimeoutError(messageOrError));
|
|
28
|
+
}
|
|
29
|
+
else if (!messageOrError) {
|
|
30
|
+
reject(new errors_js_1.TimeoutError(`Operation timed out after ${timeoutMs}ms`));
|
|
31
|
+
}
|
|
32
|
+
else {
|
|
33
|
+
reject(messageOrError);
|
|
34
|
+
}
|
|
35
|
+
}, timeoutMs);
|
|
36
|
+
}),
|
|
37
|
+
]);
|
|
38
|
+
}
|
|
39
|
+
finally {
|
|
40
|
+
if (timer) {
|
|
41
|
+
clearTimeout(timer);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=with-timeout.js.map
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/cjs/lib/with-timeout.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"with-timeout.js","sourceRoot":"","sources":["../../../lib/with-timeout.ts"],"names":[],"mappings":";;AAgBA,kCA0BC;AA1CD,2CAAyC;AAEzC;;;;;;;;;;;;;GAaG;AACI,KAAK,UAAU,WAAW,CAC/B,OAAmB,EACnB,SAAiB,EACjB,cAA+B;IAE/B,IAAI,KAAK,GAA0B,IAAI,CAAC;IACxC,IAAI,CAAC;QACH,OAAO,MAAM,OAAO,CAAC,IAAI,CAAC;YACxB,OAAO;YACP,IAAI,OAAO,CAAI,CAAC,QAAQ,EAAE,MAAM,EAAE,EAAE;gBAClC,KAAK,GAAG,UAAU,CAAC,GAAG,EAAE;oBACtB,IAAI,OAAO,cAAc,KAAK,QAAQ,IAAI,cAAc,EAAE,CAAC;wBACzD,MAAM,CAAC,IAAI,wBAAY,CAAC,cAAc,CAAC,CAAC,CAAC;oBAC3C,CAAC;yBAAM,IAAI,CAAC,cAAc,EAAE,CAAC;wBAC3B,MAAM,CAAC,IAAI,wBAAY,CAAC,6BAA6B,SAAS,IAAI,CAAC,CAAC,CAAC;oBACvE,CAAC;yBAAM,CAAC;wBACN,MAAM,CAAC,cAAc,CAAC,CAAC;oBACzB,CAAC;gBACH,CAAC,EAAE,SAAS,CAAC,CAAC;YAChB,CAAC,CAAC;SACH,CAAC,CAAC;IACL,CAAC;YAAS,CAAC;QACT,IAAI,KAAK,EAAE,CAAC;YACV,YAAY,CAAC,KAAK,CAAC,CAAC;QACtB,CAAC;IACH,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { MapFilterOptions } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Similar to `Array.prototype.filter`; runs in parallel, serial, or with custom concurrency pool
|
|
4
|
+
* @param coll - The collection to filter
|
|
5
|
+
* @param filter - The function to test each element
|
|
6
|
+
* @param options - Options for controlling parallelism (default: true - fully parallel)
|
|
7
|
+
*/
|
|
8
|
+
export declare function asyncfilter<T>(coll: T[], filter: (value: T) => boolean | Promise<boolean>, options?: MapFilterOptions): Promise<T[]>;
|
|
9
|
+
//# sourceMappingURL=asyncfilter.d.ts.map
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncfilter.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asyncfilter.d.ts","sourceRoot":"","sources":["../../../lib/asyncfilter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,YAAY,CAAC;AAEjD;;;;;GAKG;AACH,wBAAsB,WAAW,CAAC,CAAC,EACjC,IAAI,EAAE,CAAC,EAAE,EACT,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,EAChD,OAAO,GAAE,gBAAuB,GAC/B,OAAO,CAAC,CAAC,EAAE,CAAC,CAwBd"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { getLimitFunction } from './limit-function.js';
|
|
2
|
+
/**
|
|
3
|
+
* Similar to `Array.prototype.filter`; runs in parallel, serial, or with custom concurrency pool
|
|
4
|
+
* @param coll - The collection to filter
|
|
5
|
+
* @param filter - The function to test each element
|
|
6
|
+
* @param options - Options for controlling parallelism (default: true - fully parallel)
|
|
7
|
+
*/
|
|
8
|
+
export async function asyncfilter(coll, filter, options = true) {
|
|
9
|
+
if (options === null) {
|
|
10
|
+
throw new Error('Options cannot be null');
|
|
11
|
+
}
|
|
12
|
+
// limitFunction requires the filter to always return a promise
|
|
13
|
+
const filterAsync = async (value) => filter(value);
|
|
14
|
+
if (options === false) {
|
|
15
|
+
return coll.reduce(async (accP, item) => {
|
|
16
|
+
const acc = await accP;
|
|
17
|
+
if (await filterAsync(item)) {
|
|
18
|
+
acc.push(item);
|
|
19
|
+
}
|
|
20
|
+
return acc;
|
|
21
|
+
}, Promise.resolve([]));
|
|
22
|
+
}
|
|
23
|
+
const adjustedFilter = options === true ? filterAsync : (await getLimitFunction())(filterAsync, { concurrency: options.concurrency });
|
|
24
|
+
const bools = await Promise.all(coll.map(adjustedFilter));
|
|
25
|
+
return coll.reduce((acc, item, i) => {
|
|
26
|
+
if (bools[i]) {
|
|
27
|
+
acc.push(item);
|
|
28
|
+
}
|
|
29
|
+
return acc;
|
|
30
|
+
}, []);
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=asyncfilter.js.map
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncfilter.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asyncfilter.js","sourceRoot":"","sources":["../../../lib/asyncfilter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,gBAAgB,EAAC,MAAM,qBAAqB,CAAC;AAGrD;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,WAAW,CAC/B,IAAS,EACT,MAAgD,EAChD,UAA4B,IAAI;IAEhC,IAAI,OAAO,KAAK,IAAI,EAAE,CAAC;QACrB,MAAM,IAAI,KAAK,CAAC,wBAAwB,CAAC,CAAC;IAC5C,CAAC;IACD,+DAA+D;IAC/D,MAAM,WAAW,GAAG,KAAK,EAAE,KAAQ,EAAoB,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACxE,IAAI,OAAO,KAAK,KAAK,EAAE,CAAC;QACtB,OAAO,IAAI,CAAC,MAAM,CAAe,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE;YACpD,MAAM,GAAG,GAAG,MAAM,IAAI,CAAC;YACvB,IAAI,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,CAAC;gBAC5B,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YACjB,CAAC;YACD,OAAO,GAAG,CAAC;QACb,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC;IAC1B,CAAC;IACD,MAAM,cAAc,GAClB,OAAO,KAAK,IAAI,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,MAAM,gBAAgB,EAAE,CAAC,CAAC,WAAW,EAAE,EAAC,WAAW,EAAE,OAAO,CAAC,WAAW,EAAC,CAAC,CAAC;IAC/G,MAAM,KAAK,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC,CAAC;IAC1D,OAAO,IAAI,CAAC,MAAM,CAAM,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE;QACvC,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;YACb,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACjB,CAAC;QACD,OAAO,GAAG,CAAC;IACb,CAAC,EAAE,EAAE,CAAC,CAAC;AACT,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { MapFilterOptions } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Similar to `Array.prototype.map`; runs in parallel, serial, or with custom concurrency pool
|
|
4
|
+
* @param coll - The collection to map over
|
|
5
|
+
* @param mapper - The function to apply to each element
|
|
6
|
+
* @param options - Options for controlling parallelism (default: true - fully parallel)
|
|
7
|
+
*/
|
|
8
|
+
export declare function asyncmap<T, R>(coll: T[], mapper: (value: T) => R | Promise<R>, options?: MapFilterOptions): Promise<R[]>;
|
|
9
|
+
//# sourceMappingURL=asyncmap.d.ts.map
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/asyncmap.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asyncmap.d.ts","sourceRoot":"","sources":["../../../lib/asyncmap.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,YAAY,CAAC;AAEjD;;;;;GAKG;AACH,wBAAsB,QAAQ,CAAC,CAAC,EAAE,CAAC,EACjC,IAAI,EAAE,CAAC,EAAE,EACT,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,EACpC,OAAO,GAAE,gBAAuB,GAC/B,OAAO,CAAC,CAAC,EAAE,CAAC,CAed"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { getLimitFunction } from './limit-function.js';
|
|
2
|
+
/**
|
|
3
|
+
* Similar to `Array.prototype.map`; runs in parallel, serial, or with custom concurrency pool
|
|
4
|
+
* @param coll - The collection to map over
|
|
5
|
+
* @param mapper - The function to apply to each element
|
|
6
|
+
* @param options - Options for controlling parallelism (default: true - fully parallel)
|
|
7
|
+
*/
|
|
8
|
+
export async function asyncmap(coll, mapper, options = true) {
|
|
9
|
+
if (options === null) {
|
|
10
|
+
throw new Error('Options cannot be null');
|
|
11
|
+
}
|
|
12
|
+
// limitFunction requires the mapper to always return a promise
|
|
13
|
+
const mapperAsync = async (value) => mapper(value);
|
|
14
|
+
if (options === false) {
|
|
15
|
+
return coll.reduce(async (acc, item) => [...(await acc), await mapperAsync(item)], Promise.resolve([]));
|
|
16
|
+
}
|
|
17
|
+
const adjustedMapper = options === true ? mapperAsync : (await getLimitFunction())(mapperAsync, { concurrency: options.concurrency });
|
|
18
|
+
return Promise.all(coll.map(adjustedMapper));
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=asyncmap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asyncmap.js","sourceRoot":"","sources":["../../../lib/asyncmap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,gBAAgB,EAAC,MAAM,qBAAqB,CAAC;AAGrD;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,QAAQ,CAC5B,IAAS,EACT,MAAoC,EACpC,UAA4B,IAAI;IAEhC,IAAI,OAAO,KAAK,IAAI,EAAE,CAAC;QACrB,MAAM,IAAI,KAAK,CAAC,wBAAwB,CAAC,CAAC;IAC5C,CAAC;IACD,+DAA+D;IAC/D,MAAM,WAAW,GAAG,KAAK,EAAE,KAAQ,EAAc,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IAClE,IAAI,OAAO,KAAK,KAAK,EAAE,CAAC;QACtB,OAAO,IAAI,CAAC,MAAM,CAChB,KAAK,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,MAAM,GAAG,CAAC,EAAE,MAAM,WAAW,CAAC,IAAI,CAAC,CAAC,EAC9D,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,CACpB,CAAC;IACJ,CAAC;IACD,MAAM,cAAc,GAClB,OAAO,KAAK,IAAI,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,MAAM,gBAAgB,EAAE,CAAC,CAAC,WAAW,EAAE,EAAC,WAAW,EAAE,OAAO,CAAC,WAAW,EAAC,CAAC,CAAC;IAC/G,OAAO,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC,CAAC;AAC/C,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/** Error thrown by {@link withTimeout} when the deadline is exceeded. */
|
|
2
|
+
export declare class TimeoutError extends Error {
|
|
3
|
+
constructor(message?: string);
|
|
4
|
+
}
|
|
5
|
+
/** Thrown when a promise is cancelled via `cancel`. */
|
|
6
|
+
export declare class PromiseCancellationError extends Error {
|
|
7
|
+
constructor(message?: string);
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../lib/errors.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,qBAAa,YAAa,SAAQ,KAAK;gBACzB,OAAO,CAAC,EAAE,MAAM;CAI7B;AAED,uDAAuD;AACvD,qBAAa,wBAAyB,SAAQ,KAAK;gBACrC,OAAO,GAAE,MAA4B;CAIlD"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** Error thrown by {@link withTimeout} when the deadline is exceeded. */
|
|
2
|
+
export class TimeoutError extends Error {
|
|
3
|
+
constructor(message) {
|
|
4
|
+
super(message ?? 'Operation timed out');
|
|
5
|
+
this.name = 'TimeoutError';
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
/** Thrown when a promise is cancelled via `cancel`. */
|
|
9
|
+
export class PromiseCancellationError extends Error {
|
|
10
|
+
constructor(message = 'Promise cancelled') {
|
|
11
|
+
super(message);
|
|
12
|
+
this.name = 'PromiseCancellationError';
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=errors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../../lib/errors.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,MAAM,OAAO,YAAa,SAAQ,KAAK;IACrC,YAAY,OAAgB;QAC1B,KAAK,CAAC,OAAO,IAAI,qBAAqB,CAAC,CAAC;QACxC,IAAI,CAAC,IAAI,GAAG,cAAc,CAAC;IAC7B,CAAC;CACF;AAED,uDAAuD;AACvD,MAAM,OAAO,wBAAyB,SAAQ,KAAK;IACjD,YAAY,UAAkB,mBAAmB;QAC/C,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,0BAA0B,CAAC;IACzC,CAAC;CACF"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export { TimeoutError, PromiseCancellationError } from './errors.js';
|
|
2
|
+
export { sleep } from './sleep.js';
|
|
3
|
+
export { withTimeout } from './with-timeout.js';
|
|
4
|
+
export { longSleep } from './long-sleep.js';
|
|
5
|
+
export { retry, retryInterval } from './retry.js';
|
|
6
|
+
export { asyncmap } from './asyncmap.js';
|
|
7
|
+
export { asyncfilter } from './asyncfilter.js';
|
|
8
|
+
export { waitForCondition } from './wait-for-condition.js';
|
|
9
|
+
export { AsyncLock } from './lock.js';
|
|
10
|
+
export type { AsyncLockOptions, AcquireOptions } from './lock.js';
|
|
11
|
+
export type { CancellablePromise, Progress, ProgressCallback, LongSleepOptions, MapFilterOptions, SleepArg, SleepOptions, WaitForConditionOptions, } from './types.js';
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAE,wBAAwB,EAAC,MAAM,aAAa,CAAC;AACnE,OAAO,EAAC,KAAK,EAAC,MAAM,YAAY,CAAC;AACjC,OAAO,EAAC,WAAW,EAAC,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAC,SAAS,EAAC,MAAM,iBAAiB,CAAC;AAC1C,OAAO,EAAC,KAAK,EAAE,aAAa,EAAC,MAAM,YAAY,CAAC;AAChD,OAAO,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AACvC,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAC,gBAAgB,EAAC,MAAM,yBAAyB,CAAC;AACzD,OAAO,EAAC,SAAS,EAAC,MAAM,WAAW,CAAC;AAEpC,YAAY,EAAC,gBAAgB,EAAE,cAAc,EAAC,MAAM,WAAW,CAAC;AAChE,YAAY,EACV,kBAAkB,EAClB,QAAQ,EACR,gBAAgB,EAChB,gBAAgB,EAChB,gBAAgB,EAChB,QAAQ,EACR,YAAY,EACZ,uBAAuB,GACxB,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export { TimeoutError, PromiseCancellationError } from './errors.js';
|
|
2
|
+
export { sleep } from './sleep.js';
|
|
3
|
+
export { withTimeout } from './with-timeout.js';
|
|
4
|
+
export { longSleep } from './long-sleep.js';
|
|
5
|
+
export { retry, retryInterval } from './retry.js';
|
|
6
|
+
export { asyncmap } from './asyncmap.js';
|
|
7
|
+
export { asyncfilter } from './asyncfilter.js';
|
|
8
|
+
export { waitForCondition } from './wait-for-condition.js';
|
|
9
|
+
export { AsyncLock } from './lock.js';
|
|
10
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAE,wBAAwB,EAAC,MAAM,aAAa,CAAC;AACnE,OAAO,EAAC,KAAK,EAAC,MAAM,YAAY,CAAC;AACjC,OAAO,EAAC,WAAW,EAAC,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAC,SAAS,EAAC,MAAM,iBAAiB,CAAC;AAC1C,OAAO,EAAC,KAAK,EAAE,aAAa,EAAC,MAAM,YAAY,CAAC;AAChD,OAAO,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AACvC,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAC,gBAAgB,EAAC,MAAM,yBAAyB,CAAC;AACzD,OAAO,EAAC,SAAS,EAAC,MAAM,WAAW,CAAC"}
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"limit-function.d.ts","sourceRoot":"","sources":["../../../lib/limit-function.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,SAAS,CAAC;AAc3C,wBAAsB,gBAAgB,kCAGrC"}
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// p-limit is ESM-only. tsc downlevels a plain `import()` in CommonJS output into a
|
|
2
|
+
// require()-in-a-microtask, which still hits Node's require(esm) interop and can race with a
|
|
3
|
+
// concurrent dynamic import() of the same module elsewhere in the process
|
|
4
|
+
// (ERR_REQUIRE_ESM_RACE_CONDITION). Route through `new Function` so tsc can't see or rewrite the
|
|
5
|
+
// import() call, keeping it a genuine native dynamic import in both the ESM and CJS builds.
|
|
6
|
+
const dynamicImport = new Function('specifier', 'return import(specifier)');
|
|
7
|
+
let limitFunctionPromise;
|
|
8
|
+
export async function getLimitFunction() {
|
|
9
|
+
limitFunctionPromise ??= dynamicImport('p-limit');
|
|
10
|
+
return (await limitFunctionPromise).limitFunction;
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=limit-function.js.map
|
package/node_modules/@appium/base-driver/node_modules/asyncbox/build/esm/lib/limit-function.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"limit-function.js","sourceRoot":"","sources":["../../../lib/limit-function.ts"],"names":[],"mappings":"AAIA,mFAAmF;AACnF,6FAA6F;AAC7F,0EAA0E;AAC1E,iGAAiG;AACjG,4FAA4F;AAC5F,MAAM,aAAa,GAAG,IAAI,QAAQ,CAAC,WAAW,EAAE,0BAA0B,CAEhD,CAAC;AAE3B,IAAI,oBAAuD,CAAC;AAC5D,MAAM,CAAC,KAAK,UAAU,gBAAgB;IACpC,oBAAoB,KAAK,aAAa,CAAC,SAAS,CAAC,CAAC;IAClD,OAAO,CAAC,MAAM,oBAAoB,CAAC,CAAC,aAAa,CAAC;AACpD,CAAC"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/** Options shared by the {@link AsyncLock} constructor and {@link AsyncLock.acquire}. */
|
|
2
|
+
export interface AsyncLockOptions {
|
|
3
|
+
/**
|
|
4
|
+
* Max ms a task may wait in the queue before failing. `0` means never.
|
|
5
|
+
* @default 0
|
|
6
|
+
*/
|
|
7
|
+
timeout?: number;
|
|
8
|
+
/**
|
|
9
|
+
* Max ms between calling `acquire` and the task finishing (queue wait included). `0` means never.
|
|
10
|
+
* @default 0
|
|
11
|
+
*/
|
|
12
|
+
maxOccupationTime?: number;
|
|
13
|
+
/**
|
|
14
|
+
* Max ms the task may run once it holds the lock; the lock is then released. `0` means never.
|
|
15
|
+
* @default 0
|
|
16
|
+
*/
|
|
17
|
+
maxExecutionTime?: number;
|
|
18
|
+
/**
|
|
19
|
+
* Max number of tasks waiting per key; further ones are rejected right away. `0` rejects every
|
|
20
|
+
* task that would have to wait.
|
|
21
|
+
* @default 1000
|
|
22
|
+
*/
|
|
23
|
+
maxPending?: number;
|
|
24
|
+
}
|
|
25
|
+
/** Per-call options of {@link AsyncLock.acquire}; override the constructor ones. */
|
|
26
|
+
export interface AcquireOptions extends AsyncLockOptions {
|
|
27
|
+
/**
|
|
28
|
+
* Put the task at the front of the queue instead of the back.
|
|
29
|
+
* @default false
|
|
30
|
+
*/
|
|
31
|
+
skipQueue?: boolean;
|
|
32
|
+
}
|
|
33
|
+
type Task<T> = () => T | PromiseLike<T>;
|
|
34
|
+
/**
|
|
35
|
+
* Promise-based mutex keyed by string. Tasks with the same key run one at a time, in FIFO order.
|
|
36
|
+
*
|
|
37
|
+
* Each task runs in the async context (`AsyncLocalStorage`) of the code that called
|
|
38
|
+
* {@link AsyncLock.acquire}, not in the context of the task that held the lock before it.
|
|
39
|
+
*/
|
|
40
|
+
export declare class AsyncLock {
|
|
41
|
+
private readonly queues;
|
|
42
|
+
private readonly defaults;
|
|
43
|
+
constructor(opts?: AsyncLockOptions);
|
|
44
|
+
/**
|
|
45
|
+
* Run `fn` once the lock for `key` is free and release the lock when it settles.
|
|
46
|
+
*
|
|
47
|
+
* Multiple keys are held together. They are acquired one by one in sorted order, whatever order
|
|
48
|
+
* they are given in, so that overlapping calls cannot deadlock; duplicates are ignored. Keys that
|
|
49
|
+
* are already held stay held while a later one is awaited. `timeout` and `maxOccupationTime` are
|
|
50
|
+
* budgets for the whole call, while `maxExecutionTime` counts from the moment all the keys are
|
|
51
|
+
* held and releases all of them.
|
|
52
|
+
*
|
|
53
|
+
* @param key - Resource key, or a non-empty array of keys
|
|
54
|
+
* @param fn - Task to run while holding the lock; may be sync or async
|
|
55
|
+
* @param opts - Per-call options
|
|
56
|
+
* @returns The result of `fn`
|
|
57
|
+
* @throws {TypeError} Synchronously, if an argument is invalid
|
|
58
|
+
*/
|
|
59
|
+
acquire<T>(key: string | readonly string[], fn: Task<T>, opts?: AcquireOptions): Promise<T>;
|
|
60
|
+
/**
|
|
61
|
+
* Number of tasks waiting for `key`, not counting the running one.
|
|
62
|
+
*
|
|
63
|
+
* @param key - Resource key
|
|
64
|
+
*/
|
|
65
|
+
getQueueLength(key: string): number;
|
|
66
|
+
/**
|
|
67
|
+
* Whether `key` has a running or pending task. Without a key, whether any key does.
|
|
68
|
+
*
|
|
69
|
+
* @param key - Resource key
|
|
70
|
+
*/
|
|
71
|
+
isBusy(key?: string): boolean;
|
|
72
|
+
}
|
|
73
|
+
export {};
|
|
74
|
+
//# sourceMappingURL=lock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lock.d.ts","sourceRoot":"","sources":["../../../lib/lock.ts"],"names":[],"mappings":"AAMA,yFAAyF;AACzF,MAAM,WAAW,gBAAgB;IAC/B;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;;OAIG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,oFAAoF;AACpF,MAAM,WAAW,cAAe,SAAQ,gBAAgB;IACtD;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,KAAK,IAAI,CAAC,CAAC,IAAI,MAAM,CAAC,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC;AAMxC;;;;;GAKG;AACH,qBAAa,SAAS;IACpB,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAqB;IAC5C,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAA6B;gBAE1C,IAAI,GAAE,gBAAqB;IAWvC;;;;;;;;;;;;;;OAcG;IACH,OAAO,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,GAAG,SAAS,MAAM,EAAE,EAAE,EAAE,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,IAAI,GAAE,cAAmB,GAAG,OAAO,CAAC,CAAC,CAAC;IAkB/F;;;;OAIG;IACH,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM;IAInC;;;;OAIG;IACH,MAAM,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,OAAO;CAG9B"}
|