dsh-duet 0.2.0 → 0.3.0
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/README.md +26 -6
- package/assets/avatar/character.glb +0 -0
- package/assets/avatar/desktop/character.glb +0 -0
- package/assets/avatar/desktop/companion.mjs +3 -3
- package/assets/avatar/desktop/index.html +10 -0
- package/assets/avatar/desktop/manifest.json +4 -4
- package/assets/avatar/desktop/portrait.png +0 -0
- package/assets/avatar/portrait.png +0 -0
- package/config/duet.patch.yml +176 -0
- package/node_modules/dsh-duet-superagent/LICENSE +21 -0
- package/node_modules/dsh-duet-superagent/README.md +39 -0
- package/node_modules/dsh-duet-superagent/cordis.patch.yml +193 -0
- package/node_modules/dsh-duet-superagent/lib/client.js +6883 -0
- package/node_modules/dsh-duet-superagent/lib/deployment-CFE4xX4v.d.ts +736 -0
- package/node_modules/dsh-duet-superagent/lib/duet.d.ts +1160 -0
- package/node_modules/dsh-duet-superagent/lib/duet.js +837 -0
- package/node_modules/dsh-duet-superagent/lib/engine-B2un4KNA.d.ts +243 -0
- package/node_modules/dsh-duet-superagent/lib/feishu-rAGM9U9b.js +1324 -0
- package/node_modules/dsh-duet-superagent/lib/feishu-watch.d.ts +125 -0
- package/node_modules/dsh-duet-superagent/lib/feishu-watch.js +2 -0
- package/node_modules/dsh-duet-superagent/lib/github-pull-gSbjzypm.js +596 -0
- package/node_modules/dsh-duet-superagent/lib/github-watch.d.ts +2 -0
- package/node_modules/dsh-duet-superagent/lib/github-watch.js +832 -0
- package/node_modules/dsh-duet-superagent/lib/index.d.ts +129 -0
- package/node_modules/dsh-duet-superagent/lib/index.js +107 -0
- package/node_modules/dsh-duet-superagent/lib/poll-Dh7J1cdM.js +872 -0
- package/node_modules/dsh-duet-superagent/lib/registry-BTgyFZ8S.d.ts +1509 -0
- package/node_modules/dsh-duet-superagent/lib/runtime-CbDPyQoo.js +10653 -0
- package/node_modules/dsh-duet-superagent/locale/en.json +6 -0
- package/node_modules/dsh-duet-superagent/locale/zh.json +6 -0
- package/node_modules/dsh-duet-superagent/package.json +113 -0
- package/node_modules/dsh-duet-superagent/prompts/admission.md +68 -0
- package/node_modules/dsh-duet-superagent/prompts/cli.md +17 -0
- package/node_modules/dsh-duet-superagent/prompts/dispatch.md +59 -0
- package/node_modules/dsh-duet-superagent/prompts/handoff-orchestrator.md +4 -0
- package/node_modules/dsh-duet-superagent/prompts/handoff-worker.md +7 -0
- package/node_modules/dsh-duet-superagent/prompts/handoff.md +6 -0
- package/node_modules/dsh-duet-superagent/prompts/orchestrator.md +16 -0
- package/node_modules/dsh-duet-superagent/prompts/replies.md +35 -0
- package/node_modules/dsh-duet-superagent/prompts/shared.md +7 -0
- package/node_modules/dsh-duet-superagent/prompts/subscriptions.md +13 -0
- package/node_modules/dsh-duet-superagent/prompts/team/communication.md +97 -0
- package/node_modules/dsh-duet-superagent/prompts/team/delivery.md +28 -0
- package/node_modules/dsh-duet-superagent/prompts/team/scope.md +22 -0
- package/node_modules/dsh-duet-superagent/prompts/work.md +49 -0
- package/node_modules/dsh-duet-superagent/prompts/worker.md +10 -0
- package/node_modules/dsh-duet-superagent/skills/dsh-superagent-feishu/SKILL.md +12 -0
- package/node_modules/dsh-duet-superagent/skills/dsh-superagent-github/SKILL.md +14 -0
- package/node_modules/graceful-fs/LICENSE.md +55 -0
- package/node_modules/graceful-fs/README.md +143 -0
- package/node_modules/graceful-fs/clone.js +23 -0
- package/node_modules/graceful-fs/graceful-fs.js +448 -0
- package/node_modules/graceful-fs/legacy-streams.js +118 -0
- package/node_modules/graceful-fs/package.json +52 -0
- package/node_modules/graceful-fs/polyfills.js +355 -0
- package/node_modules/proper-lockfile/CHANGELOG.md +108 -0
- package/node_modules/proper-lockfile/LICENSE +21 -0
- package/node_modules/proper-lockfile/README.md +183 -0
- package/node_modules/proper-lockfile/index.js +40 -0
- package/node_modules/proper-lockfile/lib/adapter.js +85 -0
- package/node_modules/proper-lockfile/lib/lockfile.js +342 -0
- package/node_modules/proper-lockfile/lib/mtime-precision.js +55 -0
- package/node_modules/proper-lockfile/package.json +71 -0
- package/node_modules/retry/.npmignore +3 -0
- package/node_modules/retry/.travis.yml +15 -0
- package/node_modules/retry/License +21 -0
- package/node_modules/retry/Makefile +18 -0
- package/node_modules/retry/README.md +227 -0
- package/node_modules/retry/equation.gif +0 -0
- package/node_modules/retry/example/dns.js +31 -0
- package/node_modules/retry/example/stop.js +40 -0
- package/node_modules/retry/index.js +1 -0
- package/node_modules/retry/lib/retry.js +100 -0
- package/node_modules/retry/lib/retry_operation.js +158 -0
- package/node_modules/retry/package.json +32 -0
- package/node_modules/retry/test/common.js +10 -0
- package/node_modules/retry/test/integration/test-forever.js +24 -0
- package/node_modules/retry/test/integration/test-retry-operation.js +258 -0
- package/node_modules/retry/test/integration/test-retry-wrap.js +101 -0
- package/node_modules/retry/test/integration/test-timeouts.js +69 -0
- package/node_modules/signal-exit/LICENSE.txt +16 -0
- package/node_modules/signal-exit/README.md +39 -0
- package/node_modules/signal-exit/index.js +202 -0
- package/node_modules/signal-exit/package.json +38 -0
- package/node_modules/signal-exit/signals.js +53 -0
- package/node_modules/zod/LICENSE +21 -0
- package/node_modules/zod/README.md +191 -0
- package/node_modules/zod/index.cjs +33 -0
- package/node_modules/zod/index.d.cts +4 -0
- package/node_modules/zod/index.d.ts +4 -0
- package/node_modules/zod/index.js +4 -0
- package/node_modules/zod/locales/index.cjs +17 -0
- package/node_modules/zod/locales/index.d.cts +1 -0
- package/node_modules/zod/locales/index.d.ts +1 -0
- package/node_modules/zod/locales/index.js +1 -0
- package/node_modules/zod/locales/package.json +7 -0
- package/node_modules/zod/mini/index.cjs +32 -0
- package/node_modules/zod/mini/index.d.cts +3 -0
- package/node_modules/zod/mini/index.d.ts +3 -0
- package/node_modules/zod/mini/index.js +3 -0
- package/node_modules/zod/mini/package.json +7 -0
- package/node_modules/zod/package.json +135 -0
- package/node_modules/zod/src/index.ts +4 -0
- package/node_modules/zod/src/locales/index.ts +1 -0
- package/node_modules/zod/src/mini/index.ts +3 -0
- package/node_modules/zod/src/v3/ZodError.ts +330 -0
- package/node_modules/zod/src/v3/benchmarks/datetime.ts +58 -0
- package/node_modules/zod/src/v3/benchmarks/discriminatedUnion.ts +80 -0
- package/node_modules/zod/src/v3/benchmarks/index.ts +59 -0
- package/node_modules/zod/src/v3/benchmarks/ipv4.ts +57 -0
- package/node_modules/zod/src/v3/benchmarks/object.ts +69 -0
- package/node_modules/zod/src/v3/benchmarks/primitives.ts +162 -0
- package/node_modules/zod/src/v3/benchmarks/realworld.ts +63 -0
- package/node_modules/zod/src/v3/benchmarks/string.ts +55 -0
- package/node_modules/zod/src/v3/benchmarks/union.ts +80 -0
- package/node_modules/zod/src/v3/errors.ts +13 -0
- package/node_modules/zod/src/v3/external.ts +6 -0
- package/node_modules/zod/src/v3/helpers/enumUtil.ts +17 -0
- package/node_modules/zod/src/v3/helpers/errorUtil.ts +8 -0
- package/node_modules/zod/src/v3/helpers/parseUtil.ts +176 -0
- package/node_modules/zod/src/v3/helpers/partialUtil.ts +34 -0
- package/node_modules/zod/src/v3/helpers/typeAliases.ts +2 -0
- package/node_modules/zod/src/v3/helpers/util.ts +224 -0
- package/node_modules/zod/src/v3/index.ts +4 -0
- package/node_modules/zod/src/v3/locales/en.ts +124 -0
- package/node_modules/zod/src/v3/standard-schema.ts +113 -0
- package/node_modules/zod/src/v3/tests/Mocker.ts +54 -0
- package/node_modules/zod/src/v3/tests/all-errors.test.ts +157 -0
- package/node_modules/zod/src/v3/tests/anyunknown.test.ts +28 -0
- package/node_modules/zod/src/v3/tests/array.test.ts +71 -0
- package/node_modules/zod/src/v3/tests/async-parsing.test.ts +388 -0
- package/node_modules/zod/src/v3/tests/async-refinements.test.ts +46 -0
- package/node_modules/zod/src/v3/tests/base.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/bigint.test.ts +55 -0
- package/node_modules/zod/src/v3/tests/branded.test.ts +53 -0
- package/node_modules/zod/src/v3/tests/catch.test.ts +220 -0
- package/node_modules/zod/src/v3/tests/coerce.test.ts +133 -0
- package/node_modules/zod/src/v3/tests/complex.test.ts +70 -0
- package/node_modules/zod/src/v3/tests/custom.test.ts +31 -0
- package/node_modules/zod/src/v3/tests/date.test.ts +32 -0
- package/node_modules/zod/src/v3/tests/deepmasking.test.ts +186 -0
- package/node_modules/zod/src/v3/tests/default.test.ts +112 -0
- package/node_modules/zod/src/v3/tests/description.test.ts +33 -0
- package/node_modules/zod/src/v3/tests/discriminated-unions.test.ts +315 -0
- package/node_modules/zod/src/v3/tests/enum.test.ts +80 -0
- package/node_modules/zod/src/v3/tests/error.test.ts +551 -0
- package/node_modules/zod/src/v3/tests/firstparty.test.ts +87 -0
- package/node_modules/zod/src/v3/tests/firstpartyschematypes.test.ts +21 -0
- package/node_modules/zod/src/v3/tests/function.test.ts +261 -0
- package/node_modules/zod/src/v3/tests/generics.test.ts +48 -0
- package/node_modules/zod/src/v3/tests/instanceof.test.ts +37 -0
- package/node_modules/zod/src/v3/tests/intersection.test.ts +110 -0
- package/node_modules/zod/src/v3/tests/language-server.source.ts +76 -0
- package/node_modules/zod/src/v3/tests/language-server.test.ts +207 -0
- package/node_modules/zod/src/v3/tests/literal.test.ts +36 -0
- package/node_modules/zod/src/v3/tests/map.test.ts +110 -0
- package/node_modules/zod/src/v3/tests/masking.test.ts +4 -0
- package/node_modules/zod/src/v3/tests/mocker.test.ts +19 -0
- package/node_modules/zod/src/v3/tests/nan.test.ts +24 -0
- package/node_modules/zod/src/v3/tests/nativeEnum.test.ts +87 -0
- package/node_modules/zod/src/v3/tests/nullable.test.ts +42 -0
- package/node_modules/zod/src/v3/tests/number.test.ts +176 -0
- package/node_modules/zod/src/v3/tests/object-augmentation.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/object-in-es5-env.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/object.test.ts +434 -0
- package/node_modules/zod/src/v3/tests/optional.test.ts +42 -0
- package/node_modules/zod/src/v3/tests/parseUtil.test.ts +23 -0
- package/node_modules/zod/src/v3/tests/parser.test.ts +41 -0
- package/node_modules/zod/src/v3/tests/partials.test.ts +243 -0
- package/node_modules/zod/src/v3/tests/pickomit.test.ts +111 -0
- package/node_modules/zod/src/v3/tests/pipeline.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/preprocess.test.ts +186 -0
- package/node_modules/zod/src/v3/tests/primitive.test.ts +440 -0
- package/node_modules/zod/src/v3/tests/promise.test.ts +90 -0
- package/node_modules/zod/src/v3/tests/readonly.test.ts +194 -0
- package/node_modules/zod/src/v3/tests/record.test.ts +171 -0
- package/node_modules/zod/src/v3/tests/recursive.test.ts +197 -0
- package/node_modules/zod/src/v3/tests/refine.test.ts +313 -0
- package/node_modules/zod/src/v3/tests/safeparse.test.ts +27 -0
- package/node_modules/zod/src/v3/tests/set.test.ts +142 -0
- package/node_modules/zod/src/v3/tests/standard-schema.test.ts +83 -0
- package/node_modules/zod/src/v3/tests/string.test.ts +916 -0
- package/node_modules/zod/src/v3/tests/transformer.test.ts +233 -0
- package/node_modules/zod/src/v3/tests/tuple.test.ts +90 -0
- package/node_modules/zod/src/v3/tests/unions.test.ts +57 -0
- package/node_modules/zod/src/v3/tests/validations.test.ts +133 -0
- package/node_modules/zod/src/v3/tests/void.test.ts +15 -0
- package/node_modules/zod/src/v3/types.ts +5138 -0
- package/node_modules/zod/src/v4/classic/checks.ts +32 -0
- package/node_modules/zod/src/v4/classic/coerce.ts +27 -0
- package/node_modules/zod/src/v4/classic/compat.ts +70 -0
- package/node_modules/zod/src/v4/classic/errors.ts +82 -0
- package/node_modules/zod/src/v4/classic/external.ts +52 -0
- package/node_modules/zod/src/v4/classic/from-json-schema.ts +659 -0
- package/node_modules/zod/src/v4/classic/index.ts +5 -0
- package/node_modules/zod/src/v4/classic/iso.ts +90 -0
- package/node_modules/zod/src/v4/classic/parse.ts +82 -0
- package/node_modules/zod/src/v4/classic/schemas.ts +2672 -0
- package/node_modules/zod/src/v4/classic/tests/anyunknown.test.ts +26 -0
- package/node_modules/zod/src/v4/classic/tests/apply.test.ts +59 -0
- package/node_modules/zod/src/v4/classic/tests/array.test.ts +264 -0
- package/node_modules/zod/src/v4/classic/tests/assignability.test.ts +216 -0
- package/node_modules/zod/src/v4/classic/tests/async-parsing.test.ts +381 -0
- package/node_modules/zod/src/v4/classic/tests/async-refinements.test.ts +68 -0
- package/node_modules/zod/src/v4/classic/tests/base.test.ts +7 -0
- package/node_modules/zod/src/v4/classic/tests/bigint.test.ts +54 -0
- package/node_modules/zod/src/v4/classic/tests/brand.test.ts +106 -0
- package/node_modules/zod/src/v4/classic/tests/catch.test.ts +326 -0
- package/node_modules/zod/src/v4/classic/tests/coalesce.test.ts +20 -0
- package/node_modules/zod/src/v4/classic/tests/codec-examples.test.ts +573 -0
- package/node_modules/zod/src/v4/classic/tests/codec.test.ts +703 -0
- package/node_modules/zod/src/v4/classic/tests/coerce.test.ts +160 -0
- package/node_modules/zod/src/v4/classic/tests/continuability.test.ts +374 -0
- package/node_modules/zod/src/v4/classic/tests/custom.test.ts +40 -0
- package/node_modules/zod/src/v4/classic/tests/date.test.ts +62 -0
- package/node_modules/zod/src/v4/classic/tests/datetime.test.ts +302 -0
- package/node_modules/zod/src/v4/classic/tests/default.test.ts +409 -0
- package/node_modules/zod/src/v4/classic/tests/describe-meta-checks.test.ts +27 -0
- package/node_modules/zod/src/v4/classic/tests/description.test.ts +32 -0
- package/node_modules/zod/src/v4/classic/tests/detached-methods.test.ts +197 -0
- package/node_modules/zod/src/v4/classic/tests/discriminated-unions.test.ts +694 -0
- package/node_modules/zod/src/v4/classic/tests/enum.test.ts +285 -0
- package/node_modules/zod/src/v4/classic/tests/error-utils.test.ts +807 -0
- package/node_modules/zod/src/v4/classic/tests/error.test.ts +711 -0
- package/node_modules/zod/src/v4/classic/tests/file.test.ts +96 -0
- package/node_modules/zod/src/v4/classic/tests/firstparty.test.ts +179 -0
- package/node_modules/zod/src/v4/classic/tests/fix-json-issue.test.ts +26 -0
- package/node_modules/zod/src/v4/classic/tests/from-json-schema.test.ts +895 -0
- package/node_modules/zod/src/v4/classic/tests/function.test.ts +360 -0
- package/node_modules/zod/src/v4/classic/tests/generics.test.ts +72 -0
- package/node_modules/zod/src/v4/classic/tests/global-config.test.ts +39 -0
- package/node_modules/zod/src/v4/classic/tests/hash.test.ts +68 -0
- package/node_modules/zod/src/v4/classic/tests/index.test.ts +939 -0
- package/node_modules/zod/src/v4/classic/tests/instanceof.test.ts +60 -0
- package/node_modules/zod/src/v4/classic/tests/intersection.test.ts +198 -0
- package/node_modules/zod/src/v4/classic/tests/jitless-allows-eval.test.ts +46 -0
- package/node_modules/zod/src/v4/classic/tests/json.test.ts +109 -0
- package/node_modules/zod/src/v4/classic/tests/lazy.test.ts +227 -0
- package/node_modules/zod/src/v4/classic/tests/literal.test.ts +117 -0
- package/node_modules/zod/src/v4/classic/tests/locales_ka.test.ts +29 -0
- package/node_modules/zod/src/v4/classic/tests/locales_ro.test.ts +24 -0
- package/node_modules/zod/src/v4/classic/tests/map.test.ts +330 -0
- package/node_modules/zod/src/v4/classic/tests/nan.test.ts +21 -0
- package/node_modules/zod/src/v4/classic/tests/nested-refine.test.ts +168 -0
- package/node_modules/zod/src/v4/classic/tests/nonoptional.test.ts +101 -0
- package/node_modules/zod/src/v4/classic/tests/nullable.test.ts +22 -0
- package/node_modules/zod/src/v4/classic/tests/number.test.ts +325 -0
- package/node_modules/zod/src/v4/classic/tests/object.test.ts +717 -0
- package/node_modules/zod/src/v4/classic/tests/optional.test.ts +333 -0
- package/node_modules/zod/src/v4/classic/tests/partial.test.ts +450 -0
- package/node_modules/zod/src/v4/classic/tests/pickomit.test.ts +211 -0
- package/node_modules/zod/src/v4/classic/tests/pipe.test.ts +101 -0
- package/node_modules/zod/src/v4/classic/tests/prefault.test.ts +74 -0
- package/node_modules/zod/src/v4/classic/tests/preprocess-types.test.ts +26 -0
- package/node_modules/zod/src/v4/classic/tests/preprocess.test.ts +351 -0
- package/node_modules/zod/src/v4/classic/tests/primitive.test.ts +175 -0
- package/node_modules/zod/src/v4/classic/tests/promise.test.ts +81 -0
- package/node_modules/zod/src/v4/classic/tests/prototypes.test.ts +23 -0
- package/node_modules/zod/src/v4/classic/tests/readonly.test.ts +252 -0
- package/node_modules/zod/src/v4/classic/tests/record.test.ts +717 -0
- package/node_modules/zod/src/v4/classic/tests/recursive-types.test.ts +631 -0
- package/node_modules/zod/src/v4/classic/tests/refine.test.ts +633 -0
- package/node_modules/zod/src/v4/classic/tests/registries.test.ts +243 -0
- package/node_modules/zod/src/v4/classic/tests/set.test.ts +181 -0
- package/node_modules/zod/src/v4/classic/tests/standard-schema.test.ts +134 -0
- package/node_modules/zod/src/v4/classic/tests/string-formats.test.ts +125 -0
- package/node_modules/zod/src/v4/classic/tests/string.test.ts +1224 -0
- package/node_modules/zod/src/v4/classic/tests/stringbool.test.ts +106 -0
- package/node_modules/zod/src/v4/classic/tests/template-literal.test.ts +771 -0
- package/node_modules/zod/src/v4/classic/tests/to-json-schema-methods.test.ts +438 -0
- package/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts +3125 -0
- package/node_modules/zod/src/v4/classic/tests/transform.test.ts +378 -0
- package/node_modules/zod/src/v4/classic/tests/tuple.test.ts +496 -0
- package/node_modules/zod/src/v4/classic/tests/union.test.ts +273 -0
- package/node_modules/zod/src/v4/classic/tests/url.test.ts +13 -0
- package/node_modules/zod/src/v4/classic/tests/validations.test.ts +283 -0
- package/node_modules/zod/src/v4/classic/tests/void.test.ts +12 -0
- package/node_modules/zod/src/v4/core/api.ts +1823 -0
- package/node_modules/zod/src/v4/core/checks.ts +1293 -0
- package/node_modules/zod/src/v4/core/config.ts +15 -0
- package/node_modules/zod/src/v4/core/core.ts +153 -0
- package/node_modules/zod/src/v4/core/doc.ts +44 -0
- package/node_modules/zod/src/v4/core/errors.ts +455 -0
- package/node_modules/zod/src/v4/core/index.ts +16 -0
- package/node_modules/zod/src/v4/core/json-schema-generator.ts +126 -0
- package/node_modules/zod/src/v4/core/json-schema-processors.ts +666 -0
- package/node_modules/zod/src/v4/core/json-schema.ts +147 -0
- package/node_modules/zod/src/v4/core/parse.ts +195 -0
- package/node_modules/zod/src/v4/core/regexes.ts +190 -0
- package/node_modules/zod/src/v4/core/registries.ts +105 -0
- package/node_modules/zod/src/v4/core/schemas.ts +4730 -0
- package/node_modules/zod/src/v4/core/standard-schema.ts +159 -0
- package/node_modules/zod/src/v4/core/tests/extend.test.ts +59 -0
- package/node_modules/zod/src/v4/core/tests/index.test.ts +46 -0
- package/node_modules/zod/src/v4/core/tests/locales/be.test.ts +124 -0
- package/node_modules/zod/src/v4/core/tests/locales/el.test.ts +215 -0
- package/node_modules/zod/src/v4/core/tests/locales/en.test.ts +22 -0
- package/node_modules/zod/src/v4/core/tests/locales/es.test.ts +181 -0
- package/node_modules/zod/src/v4/core/tests/locales/fr.test.ts +72 -0
- package/node_modules/zod/src/v4/core/tests/locales/he.test.ts +379 -0
- package/node_modules/zod/src/v4/core/tests/locales/hr.test.ts +163 -0
- package/node_modules/zod/src/v4/core/tests/locales/nl.test.ts +46 -0
- package/node_modules/zod/src/v4/core/tests/locales/ru.test.ts +128 -0
- package/node_modules/zod/src/v4/core/tests/locales/tr.test.ts +69 -0
- package/node_modules/zod/src/v4/core/tests/locales/uz.test.ts +105 -0
- package/node_modules/zod/src/v4/core/tests/record-constructor.test.ts +125 -0
- package/node_modules/zod/src/v4/core/tests/recursive-tuples.test.ts +45 -0
- package/node_modules/zod/src/v4/core/to-json-schema.ts +622 -0
- package/node_modules/zod/src/v4/core/util.ts +983 -0
- package/node_modules/zod/src/v4/core/versions.ts +5 -0
- package/node_modules/zod/src/v4/core/zsf.ts +323 -0
- package/node_modules/zod/src/v4/index.ts +4 -0
- package/node_modules/zod/src/v4/locales/ar.ts +115 -0
- package/node_modules/zod/src/v4/locales/az.ts +111 -0
- package/node_modules/zod/src/v4/locales/be.ts +176 -0
- package/node_modules/zod/src/v4/locales/bg.ts +128 -0
- package/node_modules/zod/src/v4/locales/ca.ts +116 -0
- package/node_modules/zod/src/v4/locales/cs.ts +118 -0
- package/node_modules/zod/src/v4/locales/da.ts +123 -0
- package/node_modules/zod/src/v4/locales/de.ts +116 -0
- package/node_modules/zod/src/v4/locales/el.ts +121 -0
- package/node_modules/zod/src/v4/locales/en.ts +123 -0
- package/node_modules/zod/src/v4/locales/eo.ts +118 -0
- package/node_modules/zod/src/v4/locales/es.ts +141 -0
- package/node_modules/zod/src/v4/locales/fa.ts +126 -0
- package/node_modules/zod/src/v4/locales/fi.ts +121 -0
- package/node_modules/zod/src/v4/locales/fr-CA.ts +116 -0
- package/node_modules/zod/src/v4/locales/fr.ts +132 -0
- package/node_modules/zod/src/v4/locales/he.ts +246 -0
- package/node_modules/zod/src/v4/locales/hr.ts +131 -0
- package/node_modules/zod/src/v4/locales/hu.ts +117 -0
- package/node_modules/zod/src/v4/locales/hy.ts +164 -0
- package/node_modules/zod/src/v4/locales/id.ts +115 -0
- package/node_modules/zod/src/v4/locales/index.ts +52 -0
- package/node_modules/zod/src/v4/locales/is.ts +119 -0
- package/node_modules/zod/src/v4/locales/it.ts +116 -0
- package/node_modules/zod/src/v4/locales/ja.ts +114 -0
- package/node_modules/zod/src/v4/locales/ka.ts +123 -0
- package/node_modules/zod/src/v4/locales/kh.ts +7 -0
- package/node_modules/zod/src/v4/locales/km.ts +119 -0
- package/node_modules/zod/src/v4/locales/ko.ts +121 -0
- package/node_modules/zod/src/v4/locales/lt.ts +239 -0
- package/node_modules/zod/src/v4/locales/mk.ts +118 -0
- package/node_modules/zod/src/v4/locales/ms.ts +115 -0
- package/node_modules/zod/src/v4/locales/nl.ts +121 -0
- package/node_modules/zod/src/v4/locales/no.ts +116 -0
- package/node_modules/zod/src/v4/locales/ota.ts +117 -0
- package/node_modules/zod/src/v4/locales/pl.ts +118 -0
- package/node_modules/zod/src/v4/locales/ps.ts +126 -0
- package/node_modules/zod/src/v4/locales/pt.ts +116 -0
- package/node_modules/zod/src/v4/locales/ro.ts +129 -0
- package/node_modules/zod/src/v4/locales/ru.ts +176 -0
- package/node_modules/zod/src/v4/locales/sl.ts +118 -0
- package/node_modules/zod/src/v4/locales/sv.ts +119 -0
- package/node_modules/zod/src/v4/locales/ta.ts +118 -0
- package/node_modules/zod/src/v4/locales/th.ts +119 -0
- package/node_modules/zod/src/v4/locales/tr.ts +111 -0
- package/node_modules/zod/src/v4/locales/ua.ts +7 -0
- package/node_modules/zod/src/v4/locales/uk.ts +117 -0
- package/node_modules/zod/src/v4/locales/ur.ts +119 -0
- package/node_modules/zod/src/v4/locales/uz.ts +117 -0
- package/node_modules/zod/src/v4/locales/vi.ts +117 -0
- package/node_modules/zod/src/v4/locales/yo.ts +124 -0
- package/node_modules/zod/src/v4/locales/zh-CN.ts +116 -0
- package/node_modules/zod/src/v4/locales/zh-TW.ts +115 -0
- package/node_modules/zod/src/v4/mini/checks.ts +32 -0
- package/node_modules/zod/src/v4/mini/coerce.ts +27 -0
- package/node_modules/zod/src/v4/mini/external.ts +41 -0
- package/node_modules/zod/src/v4/mini/index.ts +3 -0
- package/node_modules/zod/src/v4/mini/iso.ts +66 -0
- package/node_modules/zod/src/v4/mini/parse.ts +14 -0
- package/node_modules/zod/src/v4/mini/schemas.ts +1947 -0
- package/node_modules/zod/src/v4/mini/tests/apply.test.ts +24 -0
- package/node_modules/zod/src/v4/mini/tests/assignability.test.ts +129 -0
- package/node_modules/zod/src/v4/mini/tests/brand.test.ts +94 -0
- package/node_modules/zod/src/v4/mini/tests/checks.test.ts +144 -0
- package/node_modules/zod/src/v4/mini/tests/codec.test.ts +548 -0
- package/node_modules/zod/src/v4/mini/tests/computed.test.ts +36 -0
- package/node_modules/zod/src/v4/mini/tests/error.test.ts +22 -0
- package/node_modules/zod/src/v4/mini/tests/functions.test.ts +5 -0
- package/node_modules/zod/src/v4/mini/tests/index.test.ts +993 -0
- package/node_modules/zod/src/v4/mini/tests/number.test.ts +95 -0
- package/node_modules/zod/src/v4/mini/tests/object.test.ts +227 -0
- package/node_modules/zod/src/v4/mini/tests/prototypes.test.ts +43 -0
- package/node_modules/zod/src/v4/mini/tests/recursive-types.test.ts +325 -0
- package/node_modules/zod/src/v4/mini/tests/standard-schema.test.ts +50 -0
- package/node_modules/zod/src/v4/mini/tests/string.test.ts +352 -0
- package/node_modules/zod/src/v4-mini/index.ts +3 -0
- package/node_modules/zod/v3/ZodError.cjs +138 -0
- package/node_modules/zod/v3/ZodError.d.cts +164 -0
- package/node_modules/zod/v3/ZodError.d.ts +164 -0
- package/node_modules/zod/v3/ZodError.js +133 -0
- package/node_modules/zod/v3/errors.cjs +17 -0
- package/node_modules/zod/v3/errors.d.cts +5 -0
- package/node_modules/zod/v3/errors.d.ts +5 -0
- package/node_modules/zod/v3/errors.js +9 -0
- package/node_modules/zod/v3/external.cjs +22 -0
- package/node_modules/zod/v3/external.d.cts +6 -0
- package/node_modules/zod/v3/external.d.ts +6 -0
- package/node_modules/zod/v3/external.js +6 -0
- package/node_modules/zod/v3/helpers/enumUtil.cjs +2 -0
- package/node_modules/zod/v3/helpers/enumUtil.d.cts +8 -0
- package/node_modules/zod/v3/helpers/enumUtil.d.ts +8 -0
- package/node_modules/zod/v3/helpers/enumUtil.js +1 -0
- package/node_modules/zod/v3/helpers/errorUtil.cjs +9 -0
- package/node_modules/zod/v3/helpers/errorUtil.d.cts +9 -0
- package/node_modules/zod/v3/helpers/errorUtil.d.ts +9 -0
- package/node_modules/zod/v3/helpers/errorUtil.js +6 -0
- package/node_modules/zod/v3/helpers/parseUtil.cjs +124 -0
- package/node_modules/zod/v3/helpers/parseUtil.d.cts +78 -0
- package/node_modules/zod/v3/helpers/parseUtil.d.ts +78 -0
- package/node_modules/zod/v3/helpers/parseUtil.js +109 -0
- package/node_modules/zod/v3/helpers/partialUtil.cjs +2 -0
- package/node_modules/zod/v3/helpers/partialUtil.d.cts +8 -0
- package/node_modules/zod/v3/helpers/partialUtil.d.ts +8 -0
- package/node_modules/zod/v3/helpers/partialUtil.js +1 -0
- package/node_modules/zod/v3/helpers/typeAliases.cjs +2 -0
- package/node_modules/zod/v3/helpers/typeAliases.d.cts +2 -0
- package/node_modules/zod/v3/helpers/typeAliases.d.ts +2 -0
- package/node_modules/zod/v3/helpers/typeAliases.js +1 -0
- package/node_modules/zod/v3/helpers/util.cjs +137 -0
- package/node_modules/zod/v3/helpers/util.d.cts +85 -0
- package/node_modules/zod/v3/helpers/util.d.ts +85 -0
- package/node_modules/zod/v3/helpers/util.js +133 -0
- package/node_modules/zod/v3/index.cjs +33 -0
- package/node_modules/zod/v3/index.d.cts +4 -0
- package/node_modules/zod/v3/index.d.ts +4 -0
- package/node_modules/zod/v3/index.js +4 -0
- package/node_modules/zod/v3/locales/en.cjs +112 -0
- package/node_modules/zod/v3/locales/en.d.cts +3 -0
- package/node_modules/zod/v3/locales/en.d.ts +3 -0
- package/node_modules/zod/v3/locales/en.js +109 -0
- package/node_modules/zod/v3/package.json +7 -0
- package/node_modules/zod/v3/standard-schema.cjs +2 -0
- package/node_modules/zod/v3/standard-schema.d.cts +102 -0
- package/node_modules/zod/v3/standard-schema.d.ts +102 -0
- package/node_modules/zod/v3/standard-schema.js +1 -0
- package/node_modules/zod/v3/types.cjs +3777 -0
- package/node_modules/zod/v3/types.d.cts +1034 -0
- package/node_modules/zod/v3/types.d.ts +1034 -0
- package/node_modules/zod/v3/types.js +3695 -0
- package/node_modules/zod/v4/classic/checks.cjs +33 -0
- package/node_modules/zod/v4/classic/checks.d.cts +1 -0
- package/node_modules/zod/v4/classic/checks.d.ts +1 -0
- package/node_modules/zod/v4/classic/checks.js +1 -0
- package/node_modules/zod/v4/classic/coerce.cjs +47 -0
- package/node_modules/zod/v4/classic/coerce.d.cts +17 -0
- package/node_modules/zod/v4/classic/coerce.d.ts +17 -0
- package/node_modules/zod/v4/classic/coerce.js +17 -0
- package/node_modules/zod/v4/classic/compat.cjs +61 -0
- package/node_modules/zod/v4/classic/compat.d.cts +50 -0
- package/node_modules/zod/v4/classic/compat.d.ts +50 -0
- package/node_modules/zod/v4/classic/compat.js +31 -0
- package/node_modules/zod/v4/classic/errors.cjs +74 -0
- package/node_modules/zod/v4/classic/errors.d.cts +30 -0
- package/node_modules/zod/v4/classic/errors.d.ts +30 -0
- package/node_modules/zod/v4/classic/errors.js +48 -0
- package/node_modules/zod/v4/classic/external.cjs +73 -0
- package/node_modules/zod/v4/classic/external.d.cts +16 -0
- package/node_modules/zod/v4/classic/external.d.ts +16 -0
- package/node_modules/zod/v4/classic/external.js +20 -0
- package/node_modules/zod/v4/classic/from-json-schema.cjs +625 -0
- package/node_modules/zod/v4/classic/from-json-schema.d.cts +12 -0
- package/node_modules/zod/v4/classic/from-json-schema.d.ts +12 -0
- package/node_modules/zod/v4/classic/from-json-schema.js +599 -0
- package/node_modules/zod/v4/classic/index.cjs +33 -0
- package/node_modules/zod/v4/classic/index.d.cts +4 -0
- package/node_modules/zod/v4/classic/index.d.ts +4 -0
- package/node_modules/zod/v4/classic/index.js +4 -0
- package/node_modules/zod/v4/classic/iso.cjs +60 -0
- package/node_modules/zod/v4/classic/iso.d.cts +22 -0
- package/node_modules/zod/v4/classic/iso.d.ts +22 -0
- package/node_modules/zod/v4/classic/iso.js +30 -0
- package/node_modules/zod/v4/classic/package.json +7 -0
- package/node_modules/zod/v4/classic/parse.cjs +41 -0
- package/node_modules/zod/v4/classic/parse.d.cts +31 -0
- package/node_modules/zod/v4/classic/parse.d.ts +31 -0
- package/node_modules/zod/v4/classic/parse.js +15 -0
- package/node_modules/zod/v4/classic/schemas.cjs +1511 -0
- package/node_modules/zod/v4/classic/schemas.d.cts +767 -0
- package/node_modules/zod/v4/classic/schemas.d.ts +767 -0
- package/node_modules/zod/v4/classic/schemas.js +1395 -0
- package/node_modules/zod/v4/core/api.cjs +1227 -0
- package/node_modules/zod/v4/core/api.d.cts +325 -0
- package/node_modules/zod/v4/core/api.d.ts +325 -0
- package/node_modules/zod/v4/core/api.js +1087 -0
- package/node_modules/zod/v4/core/checks.cjs +601 -0
- package/node_modules/zod/v4/core/checks.d.cts +278 -0
- package/node_modules/zod/v4/core/checks.d.ts +278 -0
- package/node_modules/zod/v4/core/checks.js +575 -0
- package/node_modules/zod/v4/core/core.cjs +85 -0
- package/node_modules/zod/v4/core/core.d.cts +70 -0
- package/node_modules/zod/v4/core/core.d.ts +70 -0
- package/node_modules/zod/v4/core/core.js +78 -0
- package/node_modules/zod/v4/core/doc.cjs +39 -0
- package/node_modules/zod/v4/core/doc.d.cts +14 -0
- package/node_modules/zod/v4/core/doc.d.ts +14 -0
- package/node_modules/zod/v4/core/doc.js +35 -0
- package/node_modules/zod/v4/core/errors.cjs +216 -0
- package/node_modules/zod/v4/core/errors.d.cts +221 -0
- package/node_modules/zod/v4/core/errors.d.ts +221 -0
- package/node_modules/zod/v4/core/errors.js +185 -0
- package/node_modules/zod/v4/core/index.cjs +47 -0
- package/node_modules/zod/v4/core/index.d.cts +16 -0
- package/node_modules/zod/v4/core/index.d.ts +16 -0
- package/node_modules/zod/v4/core/index.js +16 -0
- package/node_modules/zod/v4/core/json-schema-generator.cjs +99 -0
- package/node_modules/zod/v4/core/json-schema-generator.d.cts +65 -0
- package/node_modules/zod/v4/core/json-schema-generator.d.ts +65 -0
- package/node_modules/zod/v4/core/json-schema-generator.js +95 -0
- package/node_modules/zod/v4/core/json-schema-processors.cjs +644 -0
- package/node_modules/zod/v4/core/json-schema-processors.d.cts +49 -0
- package/node_modules/zod/v4/core/json-schema-processors.d.ts +49 -0
- package/node_modules/zod/v4/core/json-schema-processors.js +601 -0
- package/node_modules/zod/v4/core/json-schema.cjs +2 -0
- package/node_modules/zod/v4/core/json-schema.d.cts +88 -0
- package/node_modules/zod/v4/core/json-schema.d.ts +88 -0
- package/node_modules/zod/v4/core/json-schema.js +1 -0
- package/node_modules/zod/v4/core/package.json +7 -0
- package/node_modules/zod/v4/core/parse.cjs +131 -0
- package/node_modules/zod/v4/core/parse.d.cts +49 -0
- package/node_modules/zod/v4/core/parse.d.ts +49 -0
- package/node_modules/zod/v4/core/parse.js +93 -0
- package/node_modules/zod/v4/core/regexes.cjs +172 -0
- package/node_modules/zod/v4/core/regexes.d.cts +85 -0
- package/node_modules/zod/v4/core/regexes.d.ts +85 -0
- package/node_modules/zod/v4/core/regexes.js +139 -0
- package/node_modules/zod/v4/core/registries.cjs +56 -0
- package/node_modules/zod/v4/core/registries.d.cts +35 -0
- package/node_modules/zod/v4/core/registries.d.ts +35 -0
- package/node_modules/zod/v4/core/registries.js +51 -0
- package/node_modules/zod/v4/core/schemas.cjs +2270 -0
- package/node_modules/zod/v4/core/schemas.d.cts +1184 -0
- package/node_modules/zod/v4/core/schemas.d.ts +1184 -0
- package/node_modules/zod/v4/core/schemas.js +2239 -0
- package/node_modules/zod/v4/core/standard-schema.cjs +2 -0
- package/node_modules/zod/v4/core/standard-schema.d.cts +126 -0
- package/node_modules/zod/v4/core/standard-schema.d.ts +126 -0
- package/node_modules/zod/v4/core/standard-schema.js +1 -0
- package/node_modules/zod/v4/core/to-json-schema.cjs +457 -0
- package/node_modules/zod/v4/core/to-json-schema.d.cts +114 -0
- package/node_modules/zod/v4/core/to-json-schema.d.ts +114 -0
- package/node_modules/zod/v4/core/to-json-schema.js +448 -0
- package/node_modules/zod/v4/core/util.cjs +734 -0
- package/node_modules/zod/v4/core/util.d.cts +200 -0
- package/node_modules/zod/v4/core/util.d.ts +200 -0
- package/node_modules/zod/v4/core/util.js +674 -0
- package/node_modules/zod/v4/core/versions.cjs +8 -0
- package/node_modules/zod/v4/core/versions.d.cts +5 -0
- package/node_modules/zod/v4/core/versions.d.ts +5 -0
- package/node_modules/zod/v4/core/versions.js +5 -0
- package/node_modules/zod/v4/index.cjs +22 -0
- package/node_modules/zod/v4/index.d.cts +3 -0
- package/node_modules/zod/v4/index.d.ts +3 -0
- package/node_modules/zod/v4/index.js +3 -0
- package/node_modules/zod/v4/locales/ar.cjs +133 -0
- package/node_modules/zod/v4/locales/ar.d.cts +5 -0
- package/node_modules/zod/v4/locales/ar.d.ts +4 -0
- package/node_modules/zod/v4/locales/ar.js +106 -0
- package/node_modules/zod/v4/locales/az.cjs +132 -0
- package/node_modules/zod/v4/locales/az.d.cts +5 -0
- package/node_modules/zod/v4/locales/az.d.ts +4 -0
- package/node_modules/zod/v4/locales/az.js +105 -0
- package/node_modules/zod/v4/locales/be.cjs +183 -0
- package/node_modules/zod/v4/locales/be.d.cts +5 -0
- package/node_modules/zod/v4/locales/be.d.ts +4 -0
- package/node_modules/zod/v4/locales/be.js +156 -0
- package/node_modules/zod/v4/locales/bg.cjs +147 -0
- package/node_modules/zod/v4/locales/bg.d.cts +5 -0
- package/node_modules/zod/v4/locales/bg.d.ts +4 -0
- package/node_modules/zod/v4/locales/bg.js +120 -0
- package/node_modules/zod/v4/locales/ca.cjs +134 -0
- package/node_modules/zod/v4/locales/ca.d.cts +5 -0
- package/node_modules/zod/v4/locales/ca.d.ts +4 -0
- package/node_modules/zod/v4/locales/ca.js +107 -0
- package/node_modules/zod/v4/locales/cs.cjs +138 -0
- package/node_modules/zod/v4/locales/cs.d.cts +5 -0
- package/node_modules/zod/v4/locales/cs.d.ts +4 -0
- package/node_modules/zod/v4/locales/cs.js +111 -0
- package/node_modules/zod/v4/locales/da.cjs +142 -0
- package/node_modules/zod/v4/locales/da.d.cts +5 -0
- package/node_modules/zod/v4/locales/da.d.ts +4 -0
- package/node_modules/zod/v4/locales/da.js +115 -0
- package/node_modules/zod/v4/locales/de.cjs +135 -0
- package/node_modules/zod/v4/locales/de.d.cts +5 -0
- package/node_modules/zod/v4/locales/de.d.ts +4 -0
- package/node_modules/zod/v4/locales/de.js +108 -0
- package/node_modules/zod/v4/locales/el.cjs +136 -0
- package/node_modules/zod/v4/locales/el.d.cts +5 -0
- package/node_modules/zod/v4/locales/el.d.ts +4 -0
- package/node_modules/zod/v4/locales/el.js +109 -0
- package/node_modules/zod/v4/locales/en.cjs +140 -0
- package/node_modules/zod/v4/locales/en.d.cts +5 -0
- package/node_modules/zod/v4/locales/en.d.ts +4 -0
- package/node_modules/zod/v4/locales/en.js +113 -0
- package/node_modules/zod/v4/locales/eo.cjs +136 -0
- package/node_modules/zod/v4/locales/eo.d.cts +5 -0
- package/node_modules/zod/v4/locales/eo.d.ts +4 -0
- package/node_modules/zod/v4/locales/eo.js +109 -0
- package/node_modules/zod/v4/locales/es.cjs +159 -0
- package/node_modules/zod/v4/locales/es.d.cts +5 -0
- package/node_modules/zod/v4/locales/es.d.ts +4 -0
- package/node_modules/zod/v4/locales/es.js +132 -0
- package/node_modules/zod/v4/locales/fa.cjs +141 -0
- package/node_modules/zod/v4/locales/fa.d.cts +5 -0
- package/node_modules/zod/v4/locales/fa.d.ts +4 -0
- package/node_modules/zod/v4/locales/fa.js +114 -0
- package/node_modules/zod/v4/locales/fi.cjs +139 -0
- package/node_modules/zod/v4/locales/fi.d.cts +5 -0
- package/node_modules/zod/v4/locales/fi.d.ts +4 -0
- package/node_modules/zod/v4/locales/fi.js +112 -0
- package/node_modules/zod/v4/locales/fr-CA.cjs +134 -0
- package/node_modules/zod/v4/locales/fr-CA.d.cts +5 -0
- package/node_modules/zod/v4/locales/fr-CA.d.ts +4 -0
- package/node_modules/zod/v4/locales/fr-CA.js +107 -0
- package/node_modules/zod/v4/locales/fr.cjs +152 -0
- package/node_modules/zod/v4/locales/fr.d.cts +5 -0
- package/node_modules/zod/v4/locales/fr.d.ts +4 -0
- package/node_modules/zod/v4/locales/fr.js +125 -0
- package/node_modules/zod/v4/locales/he.cjs +241 -0
- package/node_modules/zod/v4/locales/he.d.cts +5 -0
- package/node_modules/zod/v4/locales/he.d.ts +4 -0
- package/node_modules/zod/v4/locales/he.js +214 -0
- package/node_modules/zod/v4/locales/hr.cjs +149 -0
- package/node_modules/zod/v4/locales/hr.d.cts +5 -0
- package/node_modules/zod/v4/locales/hr.d.ts +4 -0
- package/node_modules/zod/v4/locales/hr.js +122 -0
- package/node_modules/zod/v4/locales/hu.cjs +135 -0
- package/node_modules/zod/v4/locales/hu.d.cts +5 -0
- package/node_modules/zod/v4/locales/hu.d.ts +4 -0
- package/node_modules/zod/v4/locales/hu.js +108 -0
- package/node_modules/zod/v4/locales/hy.cjs +174 -0
- package/node_modules/zod/v4/locales/hy.d.cts +5 -0
- package/node_modules/zod/v4/locales/hy.d.ts +4 -0
- package/node_modules/zod/v4/locales/hy.js +147 -0
- package/node_modules/zod/v4/locales/id.cjs +133 -0
- package/node_modules/zod/v4/locales/id.d.cts +5 -0
- package/node_modules/zod/v4/locales/id.d.ts +4 -0
- package/node_modules/zod/v4/locales/id.js +106 -0
- package/node_modules/zod/v4/locales/index.cjs +111 -0
- package/node_modules/zod/v4/locales/index.d.cts +52 -0
- package/node_modules/zod/v4/locales/index.d.ts +52 -0
- package/node_modules/zod/v4/locales/index.js +52 -0
- package/node_modules/zod/v4/locales/is.cjs +136 -0
- package/node_modules/zod/v4/locales/is.d.cts +5 -0
- package/node_modules/zod/v4/locales/is.d.ts +4 -0
- package/node_modules/zod/v4/locales/is.js +109 -0
- package/node_modules/zod/v4/locales/it.cjs +135 -0
- package/node_modules/zod/v4/locales/it.d.cts +5 -0
- package/node_modules/zod/v4/locales/it.d.ts +4 -0
- package/node_modules/zod/v4/locales/it.js +108 -0
- package/node_modules/zod/v4/locales/ja.cjs +134 -0
- package/node_modules/zod/v4/locales/ja.d.cts +5 -0
- package/node_modules/zod/v4/locales/ja.d.ts +4 -0
- package/node_modules/zod/v4/locales/ja.js +107 -0
- package/node_modules/zod/v4/locales/ka.cjs +139 -0
- package/node_modules/zod/v4/locales/ka.d.cts +5 -0
- package/node_modules/zod/v4/locales/ka.d.ts +4 -0
- package/node_modules/zod/v4/locales/ka.js +112 -0
- package/node_modules/zod/v4/locales/kh.cjs +12 -0
- package/node_modules/zod/v4/locales/kh.d.cts +5 -0
- package/node_modules/zod/v4/locales/kh.d.ts +5 -0
- package/node_modules/zod/v4/locales/kh.js +5 -0
- package/node_modules/zod/v4/locales/km.cjs +137 -0
- package/node_modules/zod/v4/locales/km.d.cts +5 -0
- package/node_modules/zod/v4/locales/km.d.ts +4 -0
- package/node_modules/zod/v4/locales/km.js +110 -0
- package/node_modules/zod/v4/locales/ko.cjs +138 -0
- package/node_modules/zod/v4/locales/ko.d.cts +5 -0
- package/node_modules/zod/v4/locales/ko.d.ts +4 -0
- package/node_modules/zod/v4/locales/ko.js +111 -0
- package/node_modules/zod/v4/locales/lt.cjs +230 -0
- package/node_modules/zod/v4/locales/lt.d.cts +5 -0
- package/node_modules/zod/v4/locales/lt.d.ts +4 -0
- package/node_modules/zod/v4/locales/lt.js +203 -0
- package/node_modules/zod/v4/locales/mk.cjs +136 -0
- package/node_modules/zod/v4/locales/mk.d.cts +5 -0
- package/node_modules/zod/v4/locales/mk.d.ts +4 -0
- package/node_modules/zod/v4/locales/mk.js +109 -0
- package/node_modules/zod/v4/locales/ms.cjs +134 -0
- package/node_modules/zod/v4/locales/ms.d.cts +5 -0
- package/node_modules/zod/v4/locales/ms.d.ts +4 -0
- package/node_modules/zod/v4/locales/ms.js +107 -0
- package/node_modules/zod/v4/locales/nl.cjs +137 -0
- package/node_modules/zod/v4/locales/nl.d.cts +5 -0
- package/node_modules/zod/v4/locales/nl.d.ts +4 -0
- package/node_modules/zod/v4/locales/nl.js +110 -0
- package/node_modules/zod/v4/locales/no.cjs +135 -0
- package/node_modules/zod/v4/locales/no.d.cts +5 -0
- package/node_modules/zod/v4/locales/no.d.ts +4 -0
- package/node_modules/zod/v4/locales/no.js +108 -0
- package/node_modules/zod/v4/locales/ota.cjs +136 -0
- package/node_modules/zod/v4/locales/ota.d.cts +5 -0
- package/node_modules/zod/v4/locales/ota.d.ts +4 -0
- package/node_modules/zod/v4/locales/ota.js +109 -0
- package/node_modules/zod/v4/locales/package.json +7 -0
- package/node_modules/zod/v4/locales/pl.cjs +136 -0
- package/node_modules/zod/v4/locales/pl.d.cts +5 -0
- package/node_modules/zod/v4/locales/pl.d.ts +4 -0
- package/node_modules/zod/v4/locales/pl.js +109 -0
- package/node_modules/zod/v4/locales/ps.cjs +141 -0
- package/node_modules/zod/v4/locales/ps.d.cts +5 -0
- package/node_modules/zod/v4/locales/ps.d.ts +4 -0
- package/node_modules/zod/v4/locales/ps.js +114 -0
- package/node_modules/zod/v4/locales/pt.cjs +135 -0
- package/node_modules/zod/v4/locales/pt.d.cts +5 -0
- package/node_modules/zod/v4/locales/pt.d.ts +4 -0
- package/node_modules/zod/v4/locales/pt.js +108 -0
- package/node_modules/zod/v4/locales/ro.cjs +146 -0
- package/node_modules/zod/v4/locales/ro.d.cts +5 -0
- package/node_modules/zod/v4/locales/ro.d.ts +4 -0
- package/node_modules/zod/v4/locales/ro.js +119 -0
- package/node_modules/zod/v4/locales/ru.cjs +183 -0
- package/node_modules/zod/v4/locales/ru.d.cts +5 -0
- package/node_modules/zod/v4/locales/ru.d.ts +4 -0
- package/node_modules/zod/v4/locales/ru.js +156 -0
- package/node_modules/zod/v4/locales/sl.cjs +136 -0
- package/node_modules/zod/v4/locales/sl.d.cts +5 -0
- package/node_modules/zod/v4/locales/sl.d.ts +4 -0
- package/node_modules/zod/v4/locales/sl.js +109 -0
- package/node_modules/zod/v4/locales/sv.cjs +137 -0
- package/node_modules/zod/v4/locales/sv.d.cts +5 -0
- package/node_modules/zod/v4/locales/sv.d.ts +4 -0
- package/node_modules/zod/v4/locales/sv.js +110 -0
- package/node_modules/zod/v4/locales/ta.cjs +137 -0
- package/node_modules/zod/v4/locales/ta.d.cts +5 -0
- package/node_modules/zod/v4/locales/ta.d.ts +4 -0
- package/node_modules/zod/v4/locales/ta.js +110 -0
- package/node_modules/zod/v4/locales/th.cjs +137 -0
- package/node_modules/zod/v4/locales/th.d.cts +5 -0
- package/node_modules/zod/v4/locales/th.d.ts +4 -0
- package/node_modules/zod/v4/locales/th.js +110 -0
- package/node_modules/zod/v4/locales/tr.cjs +132 -0
- package/node_modules/zod/v4/locales/tr.d.cts +5 -0
- package/node_modules/zod/v4/locales/tr.d.ts +4 -0
- package/node_modules/zod/v4/locales/tr.js +105 -0
- package/node_modules/zod/v4/locales/ua.cjs +12 -0
- package/node_modules/zod/v4/locales/ua.d.cts +5 -0
- package/node_modules/zod/v4/locales/ua.d.ts +5 -0
- package/node_modules/zod/v4/locales/ua.js +5 -0
- package/node_modules/zod/v4/locales/uk.cjs +135 -0
- package/node_modules/zod/v4/locales/uk.d.cts +5 -0
- package/node_modules/zod/v4/locales/uk.d.ts +4 -0
- package/node_modules/zod/v4/locales/uk.js +108 -0
- package/node_modules/zod/v4/locales/ur.cjs +137 -0
- package/node_modules/zod/v4/locales/ur.d.cts +5 -0
- package/node_modules/zod/v4/locales/ur.d.ts +4 -0
- package/node_modules/zod/v4/locales/ur.js +110 -0
- package/node_modules/zod/v4/locales/uz.cjs +137 -0
- package/node_modules/zod/v4/locales/uz.d.cts +5 -0
- package/node_modules/zod/v4/locales/uz.d.ts +4 -0
- package/node_modules/zod/v4/locales/uz.js +110 -0
- package/node_modules/zod/v4/locales/vi.cjs +135 -0
- package/node_modules/zod/v4/locales/vi.d.cts +5 -0
- package/node_modules/zod/v4/locales/vi.d.ts +4 -0
- package/node_modules/zod/v4/locales/vi.js +108 -0
- package/node_modules/zod/v4/locales/yo.cjs +134 -0
- package/node_modules/zod/v4/locales/yo.d.cts +5 -0
- package/node_modules/zod/v4/locales/yo.d.ts +4 -0
- package/node_modules/zod/v4/locales/yo.js +107 -0
- package/node_modules/zod/v4/locales/zh-CN.cjs +136 -0
- package/node_modules/zod/v4/locales/zh-CN.d.cts +5 -0
- package/node_modules/zod/v4/locales/zh-CN.d.ts +4 -0
- package/node_modules/zod/v4/locales/zh-CN.js +109 -0
- package/node_modules/zod/v4/locales/zh-TW.cjs +134 -0
- package/node_modules/zod/v4/locales/zh-TW.d.cts +5 -0
- package/node_modules/zod/v4/locales/zh-TW.d.ts +4 -0
- package/node_modules/zod/v4/locales/zh-TW.js +107 -0
- package/node_modules/zod/v4/mini/checks.cjs +34 -0
- package/node_modules/zod/v4/mini/checks.d.cts +1 -0
- package/node_modules/zod/v4/mini/checks.d.ts +1 -0
- package/node_modules/zod/v4/mini/checks.js +1 -0
- package/node_modules/zod/v4/mini/coerce.cjs +52 -0
- package/node_modules/zod/v4/mini/coerce.d.cts +7 -0
- package/node_modules/zod/v4/mini/coerce.d.ts +7 -0
- package/node_modules/zod/v4/mini/coerce.js +22 -0
- package/node_modules/zod/v4/mini/external.cjs +63 -0
- package/node_modules/zod/v4/mini/external.d.cts +13 -0
- package/node_modules/zod/v4/mini/external.d.ts +13 -0
- package/node_modules/zod/v4/mini/external.js +14 -0
- package/node_modules/zod/v4/mini/index.cjs +32 -0
- package/node_modules/zod/v4/mini/index.d.cts +3 -0
- package/node_modules/zod/v4/mini/index.d.ts +3 -0
- package/node_modules/zod/v4/mini/index.js +3 -0
- package/node_modules/zod/v4/mini/iso.cjs +64 -0
- package/node_modules/zod/v4/mini/iso.d.cts +22 -0
- package/node_modules/zod/v4/mini/iso.d.ts +22 -0
- package/node_modules/zod/v4/mini/iso.js +34 -0
- package/node_modules/zod/v4/mini/package.json +7 -0
- package/node_modules/zod/v4/mini/parse.cjs +16 -0
- package/node_modules/zod/v4/mini/parse.d.cts +1 -0
- package/node_modules/zod/v4/mini/parse.d.ts +1 -0
- package/node_modules/zod/v4/mini/parse.js +1 -0
- package/node_modules/zod/v4/mini/schemas.cjs +1083 -0
- package/node_modules/zod/v4/mini/schemas.d.cts +445 -0
- package/node_modules/zod/v4/mini/schemas.d.ts +445 -0
- package/node_modules/zod/v4/mini/schemas.js +961 -0
- package/node_modules/zod/v4/package.json +7 -0
- package/node_modules/zod/v4-mini/index.cjs +32 -0
- package/node_modules/zod/v4-mini/index.d.cts +3 -0
- package/node_modules/zod/v4-mini/index.d.ts +3 -0
- package/node_modules/zod/v4-mini/index.js +3 -0
- package/node_modules/zod/v4-mini/package.json +7 -0
- package/package.json +6 -3
- package/src/avatar/companion.html +10 -0
- package/src/avatar/companion.mjs +1 -1
- package/src/avatar/surface.mjs +2 -0
- package/src/client/agent-tasks.mjs +165 -0
- package/src/client/audio.mjs +30 -4
- package/src/client/avatar-surfaces.mjs +7 -4
- package/src/client/avatar-tasks.mjs +5 -2
- package/src/client/avatar.mjs +21 -2
- package/src/client/browser.mjs +73 -38
- package/src/client/composer-bridge.mjs +1 -1
- package/src/client/connection-hint.mjs +1 -1
- package/src/client/entry.js +1 -1
- package/src/client/feedback.mjs +1 -1
- package/src/client/identity.mjs +2 -2
- package/src/client/notice.mjs +19 -4
- package/src/client/settings.html +65 -4
- package/src/client/tutorial-adapter.mjs +11 -4
- package/src/client/tutorial.mjs +11 -4
- package/src/client/voices.mjs +137 -0
- package/src/client/work-mode.mjs +250 -0
- package/src/client/workspaces.mjs +1 -1
- package/src/host/agent-connection.mjs +199 -0
- package/src/host/agent-trace.mjs +56 -0
- package/src/host/assets.mjs +3 -0
- package/src/host/diagnostics.mjs +37 -2
- package/src/host/plugin.mjs +112 -12
- package/src/host/proxy.mjs +93 -19
- package/src/host/service-info.mjs +30 -0
- package/src/host/settings.mjs +23 -2
- package/src/host/trace.mjs +4 -1
- package/src/host/voices.mjs +205 -0
- package/src/shared/avatar-menu-ui.mjs +5 -3
- package/src/shared/avatar-menu.mjs +3 -0
- package/src/shared/avatar-surface.mjs +2 -1
- package/src/shared/state.mjs +31 -7
- package/src/shared/work-mode.mjs +59 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "proper-lockfile",
|
|
3
|
+
"version": "4.1.2",
|
|
4
|
+
"description": "A inter-process and inter-machine lockfile utility that works on a local or network file system",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"lock",
|
|
7
|
+
"locking",
|
|
8
|
+
"file",
|
|
9
|
+
"lockfile",
|
|
10
|
+
"fs",
|
|
11
|
+
"cross-process"
|
|
12
|
+
],
|
|
13
|
+
"author": "André Cruz <andre@moxy.studio>",
|
|
14
|
+
"homepage": "https://github.com/moxystudio/node-proper-lockfile",
|
|
15
|
+
"repository": {
|
|
16
|
+
"type": "git",
|
|
17
|
+
"url": "git@github.com:moxystudio/node-proper-lockfile.git"
|
|
18
|
+
},
|
|
19
|
+
"license": "MIT",
|
|
20
|
+
"main": "index.js",
|
|
21
|
+
"files": [
|
|
22
|
+
"lib"
|
|
23
|
+
],
|
|
24
|
+
"scripts": {
|
|
25
|
+
"lint": "eslint .",
|
|
26
|
+
"test": "jest --env node --coverage --runInBand",
|
|
27
|
+
"prerelease": "npm t && npm run lint",
|
|
28
|
+
"release": "standard-version",
|
|
29
|
+
"postrelease": "git push --follow-tags origin HEAD && npm publish"
|
|
30
|
+
},
|
|
31
|
+
"husky": {
|
|
32
|
+
"hooks": {
|
|
33
|
+
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS",
|
|
34
|
+
"pre-commit": "lint-staged"
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"lint-staged": {
|
|
38
|
+
"*.js": [
|
|
39
|
+
"eslint --fix",
|
|
40
|
+
"git add"
|
|
41
|
+
]
|
|
42
|
+
},
|
|
43
|
+
"commitlint": {
|
|
44
|
+
"extends": [
|
|
45
|
+
"@commitlint/config-conventional"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
"dependencies": {
|
|
49
|
+
"graceful-fs": "^4.2.4",
|
|
50
|
+
"retry": "^0.12.0",
|
|
51
|
+
"signal-exit": "^3.0.2"
|
|
52
|
+
},
|
|
53
|
+
"devDependencies": {
|
|
54
|
+
"@commitlint/cli": "^7.0.0",
|
|
55
|
+
"@commitlint/config-conventional": "^7.0.1",
|
|
56
|
+
"@segment/clear-timeouts": "^2.0.0",
|
|
57
|
+
"delay": "^4.1.0",
|
|
58
|
+
"eslint": "^5.3.0",
|
|
59
|
+
"eslint-config-moxy": "^7.1.0",
|
|
60
|
+
"execa": "^1.0.0",
|
|
61
|
+
"husky": "^1.1.4",
|
|
62
|
+
"jest": "^24.5.0",
|
|
63
|
+
"lint-staged": "^8.0.4",
|
|
64
|
+
"mkdirp": "^0.5.1",
|
|
65
|
+
"p-defer": "^2.1.0",
|
|
66
|
+
"rimraf": "^2.6.2",
|
|
67
|
+
"stable": "^0.1.8",
|
|
68
|
+
"standard-version": "^5.0.0",
|
|
69
|
+
"thread-sleep": "^2.1.0"
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
language: node_js
|
|
2
|
+
node_js:
|
|
3
|
+
- "4"
|
|
4
|
+
before_install:
|
|
5
|
+
- pip install --user codecov
|
|
6
|
+
after_success:
|
|
7
|
+
- codecov --file coverage/lcov.info --disable search
|
|
8
|
+
# travis encrypt [subdomain]:[api token]@[room id]
|
|
9
|
+
# notifications:
|
|
10
|
+
# email: false
|
|
11
|
+
# campfire:
|
|
12
|
+
# rooms:
|
|
13
|
+
# secure: xyz
|
|
14
|
+
# on_failure: always
|
|
15
|
+
# on_success: always
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
Copyright (c) 2011:
|
|
2
|
+
Tim Koschützki (tim@debuggable.com)
|
|
3
|
+
Felix Geisendörfer (felix@debuggable.com)
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
|
13
|
+
all copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
21
|
+
THE SOFTWARE.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
SHELL := /bin/bash
|
|
2
|
+
|
|
3
|
+
release-major: test
|
|
4
|
+
npm version major -m "Release %s"
|
|
5
|
+
git push
|
|
6
|
+
npm publish
|
|
7
|
+
|
|
8
|
+
release-minor: test
|
|
9
|
+
npm version minor -m "Release %s"
|
|
10
|
+
git push
|
|
11
|
+
npm publish
|
|
12
|
+
|
|
13
|
+
release-patch: test
|
|
14
|
+
npm version patch -m "Release %s"
|
|
15
|
+
git push
|
|
16
|
+
npm publish
|
|
17
|
+
|
|
18
|
+
.PHONY: test release-major release-minor release-patch
|
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
<!-- badges/ -->
|
|
2
|
+
[](http://travis-ci.org/tim-kos/node-retry "Check this project's build status on TravisCI")
|
|
3
|
+
[](https://codecov.io/gh/tim-kos/node-retry)
|
|
4
|
+
<!-- /badges -->
|
|
5
|
+
|
|
6
|
+
# retry
|
|
7
|
+
|
|
8
|
+
Abstraction for exponential and custom retry strategies for failed operations.
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
npm install retry
|
|
13
|
+
|
|
14
|
+
## Current Status
|
|
15
|
+
|
|
16
|
+
This module has been tested and is ready to be used.
|
|
17
|
+
|
|
18
|
+
## Tutorial
|
|
19
|
+
|
|
20
|
+
The example below will retry a potentially failing `dns.resolve` operation
|
|
21
|
+
`10` times using an exponential backoff strategy. With the default settings, this
|
|
22
|
+
means the last attempt is made after `17 minutes and 3 seconds`.
|
|
23
|
+
|
|
24
|
+
``` javascript
|
|
25
|
+
var dns = require('dns');
|
|
26
|
+
var retry = require('retry');
|
|
27
|
+
|
|
28
|
+
function faultTolerantResolve(address, cb) {
|
|
29
|
+
var operation = retry.operation();
|
|
30
|
+
|
|
31
|
+
operation.attempt(function(currentAttempt) {
|
|
32
|
+
dns.resolve(address, function(err, addresses) {
|
|
33
|
+
if (operation.retry(err)) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
cb(err ? operation.mainError() : null, addresses);
|
|
38
|
+
});
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
faultTolerantResolve('nodejs.org', function(err, addresses) {
|
|
43
|
+
console.log(err, addresses);
|
|
44
|
+
});
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Of course you can also configure the factors that go into the exponential
|
|
48
|
+
backoff. See the API documentation below for all available settings.
|
|
49
|
+
currentAttempt is an int representing the number of attempts so far.
|
|
50
|
+
|
|
51
|
+
``` javascript
|
|
52
|
+
var operation = retry.operation({
|
|
53
|
+
retries: 5,
|
|
54
|
+
factor: 3,
|
|
55
|
+
minTimeout: 1 * 1000,
|
|
56
|
+
maxTimeout: 60 * 1000,
|
|
57
|
+
randomize: true,
|
|
58
|
+
});
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## API
|
|
62
|
+
|
|
63
|
+
### retry.operation([options])
|
|
64
|
+
|
|
65
|
+
Creates a new `RetryOperation` object. `options` is the same as `retry.timeouts()`'s `options`, with two additions:
|
|
66
|
+
|
|
67
|
+
* `forever`: Whether to retry forever, defaults to `false`.
|
|
68
|
+
* `unref`: Whether to [unref](https://nodejs.org/api/timers.html#timers_unref) the setTimeout's, defaults to `false`.
|
|
69
|
+
* `maxRetryTime`: The maximum time (in milliseconds) that the retried operation is allowed to run. Default is `Infinity`.
|
|
70
|
+
|
|
71
|
+
### retry.timeouts([options])
|
|
72
|
+
|
|
73
|
+
Returns an array of timeouts. All time `options` and return values are in
|
|
74
|
+
milliseconds. If `options` is an array, a copy of that array is returned.
|
|
75
|
+
|
|
76
|
+
`options` is a JS object that can contain any of the following keys:
|
|
77
|
+
|
|
78
|
+
* `retries`: The maximum amount of times to retry the operation. Default is `10`. Seting this to `1` means `do it once, then retry it once`.
|
|
79
|
+
* `factor`: The exponential factor to use. Default is `2`.
|
|
80
|
+
* `minTimeout`: The number of milliseconds before starting the first retry. Default is `1000`.
|
|
81
|
+
* `maxTimeout`: The maximum number of milliseconds between two retries. Default is `Infinity`.
|
|
82
|
+
* `randomize`: Randomizes the timeouts by multiplying with a factor between `1` to `2`. Default is `false`.
|
|
83
|
+
|
|
84
|
+
The formula used to calculate the individual timeouts is:
|
|
85
|
+
|
|
86
|
+
```
|
|
87
|
+
Math.min(random * minTimeout * Math.pow(factor, attempt), maxTimeout)
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Have a look at [this article][article] for a better explanation of approach.
|
|
91
|
+
|
|
92
|
+
If you want to tune your `factor` / `times` settings to attempt the last retry
|
|
93
|
+
after a certain amount of time, you can use wolfram alpha. For example in order
|
|
94
|
+
to tune for `10` attempts in `5 minutes`, you can use this equation:
|
|
95
|
+
|
|
96
|
+

|
|
97
|
+
|
|
98
|
+
Explaining the various values from left to right:
|
|
99
|
+
|
|
100
|
+
* `k = 0 ... 9`: The `retries` value (10)
|
|
101
|
+
* `1000`: The `minTimeout` value in ms (1000)
|
|
102
|
+
* `x^k`: No need to change this, `x` will be your resulting factor
|
|
103
|
+
* `5 * 60 * 1000`: The desired total amount of time for retrying in ms (5 minutes)
|
|
104
|
+
|
|
105
|
+
To make this a little easier for you, use wolfram alpha to do the calculations:
|
|
106
|
+
|
|
107
|
+
<http://www.wolframalpha.com/input/?i=Sum%5B1000*x^k%2C+{k%2C+0%2C+9}%5D+%3D+5+*+60+*+1000>
|
|
108
|
+
|
|
109
|
+
[article]: http://dthain.blogspot.com/2009/02/exponential-backoff-in-distributed.html
|
|
110
|
+
|
|
111
|
+
### retry.createTimeout(attempt, opts)
|
|
112
|
+
|
|
113
|
+
Returns a new `timeout` (integer in milliseconds) based on the given parameters.
|
|
114
|
+
|
|
115
|
+
`attempt` is an integer representing for which retry the timeout should be calculated. If your retry operation was executed 4 times you had one attempt and 3 retries. If you then want to calculate a new timeout, you should set `attempt` to 4 (attempts are zero-indexed).
|
|
116
|
+
|
|
117
|
+
`opts` can include `factor`, `minTimeout`, `randomize` (boolean) and `maxTimeout`. They are documented above.
|
|
118
|
+
|
|
119
|
+
`retry.createTimeout()` is used internally by `retry.timeouts()` and is public for you to be able to create your own timeouts for reinserting an item, see [issue #13](https://github.com/tim-kos/node-retry/issues/13).
|
|
120
|
+
|
|
121
|
+
### retry.wrap(obj, [options], [methodNames])
|
|
122
|
+
|
|
123
|
+
Wrap all functions of the `obj` with retry. Optionally you can pass operation options and
|
|
124
|
+
an array of method names which need to be wrapped.
|
|
125
|
+
|
|
126
|
+
```
|
|
127
|
+
retry.wrap(obj)
|
|
128
|
+
|
|
129
|
+
retry.wrap(obj, ['method1', 'method2'])
|
|
130
|
+
|
|
131
|
+
retry.wrap(obj, {retries: 3})
|
|
132
|
+
|
|
133
|
+
retry.wrap(obj, {retries: 3}, ['method1', 'method2'])
|
|
134
|
+
```
|
|
135
|
+
The `options` object can take any options that the usual call to `retry.operation` can take.
|
|
136
|
+
|
|
137
|
+
### new RetryOperation(timeouts, [options])
|
|
138
|
+
|
|
139
|
+
Creates a new `RetryOperation` where `timeouts` is an array where each value is
|
|
140
|
+
a timeout given in milliseconds.
|
|
141
|
+
|
|
142
|
+
Available options:
|
|
143
|
+
* `forever`: Whether to retry forever, defaults to `false`.
|
|
144
|
+
* `unref`: Wether to [unref](https://nodejs.org/api/timers.html#timers_unref) the setTimeout's, defaults to `false`.
|
|
145
|
+
|
|
146
|
+
If `forever` is true, the following changes happen:
|
|
147
|
+
* `RetryOperation.errors()` will only output an array of one item: the last error.
|
|
148
|
+
* `RetryOperation` will repeatedly use the `timeouts` array. Once all of its timeouts have been used up, it restarts with the first timeout, then uses the second and so on.
|
|
149
|
+
|
|
150
|
+
#### retryOperation.errors()
|
|
151
|
+
|
|
152
|
+
Returns an array of all errors that have been passed to `retryOperation.retry()` so far. The
|
|
153
|
+
returning array has the errors ordered chronologically based on when they were passed to
|
|
154
|
+
`retryOperation.retry()`, which means the first passed error is at index zero and the last is
|
|
155
|
+
at the last index.
|
|
156
|
+
|
|
157
|
+
#### retryOperation.mainError()
|
|
158
|
+
|
|
159
|
+
A reference to the error object that occured most frequently. Errors are
|
|
160
|
+
compared using the `error.message` property.
|
|
161
|
+
|
|
162
|
+
If multiple error messages occured the same amount of time, the last error
|
|
163
|
+
object with that message is returned.
|
|
164
|
+
|
|
165
|
+
If no errors occured so far, the value is `null`.
|
|
166
|
+
|
|
167
|
+
#### retryOperation.attempt(fn, timeoutOps)
|
|
168
|
+
|
|
169
|
+
Defines the function `fn` that is to be retried and executes it for the first
|
|
170
|
+
time right away. The `fn` function can receive an optional `currentAttempt` callback that represents the number of attempts to execute `fn` so far.
|
|
171
|
+
|
|
172
|
+
Optionally defines `timeoutOps` which is an object having a property `timeout` in miliseconds and a property `cb` callback function.
|
|
173
|
+
Whenever your retry operation takes longer than `timeout` to execute, the timeout callback function `cb` is called.
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
#### retryOperation.try(fn)
|
|
177
|
+
|
|
178
|
+
This is an alias for `retryOperation.attempt(fn)`. This is deprecated. Please use `retryOperation.attempt(fn)` instead.
|
|
179
|
+
|
|
180
|
+
#### retryOperation.start(fn)
|
|
181
|
+
|
|
182
|
+
This is an alias for `retryOperation.attempt(fn)`. This is deprecated. Please use `retryOperation.attempt(fn)` instead.
|
|
183
|
+
|
|
184
|
+
#### retryOperation.retry(error)
|
|
185
|
+
|
|
186
|
+
Returns `false` when no `error` value is given, or the maximum amount of retries
|
|
187
|
+
has been reached.
|
|
188
|
+
|
|
189
|
+
Otherwise it returns `true`, and retries the operation after the timeout for
|
|
190
|
+
the current attempt number.
|
|
191
|
+
|
|
192
|
+
#### retryOperation.stop()
|
|
193
|
+
|
|
194
|
+
Allows you to stop the operation being retried. Useful for aborting the operation on a fatal error etc.
|
|
195
|
+
|
|
196
|
+
#### retryOperation.reset()
|
|
197
|
+
|
|
198
|
+
Resets the internal state of the operation object, so that you can call `attempt()` again as if this was a new operation object.
|
|
199
|
+
|
|
200
|
+
#### retryOperation.attempts()
|
|
201
|
+
|
|
202
|
+
Returns an int representing the number of attempts it took to call `fn` before it was successful.
|
|
203
|
+
|
|
204
|
+
## License
|
|
205
|
+
|
|
206
|
+
retry is licensed under the MIT license.
|
|
207
|
+
|
|
208
|
+
|
|
209
|
+
# Changelog
|
|
210
|
+
|
|
211
|
+
0.10.0 Adding `stop` functionality, thanks to @maxnachlinger.
|
|
212
|
+
|
|
213
|
+
0.9.0 Adding `unref` functionality, thanks to @satazor.
|
|
214
|
+
|
|
215
|
+
0.8.0 Implementing retry.wrap.
|
|
216
|
+
|
|
217
|
+
0.7.0 Some bug fixes and made retry.createTimeout() public. Fixed issues [#10](https://github.com/tim-kos/node-retry/issues/10), [#12](https://github.com/tim-kos/node-retry/issues/12), and [#13](https://github.com/tim-kos/node-retry/issues/13).
|
|
218
|
+
|
|
219
|
+
0.6.0 Introduced optional timeOps parameter for the attempt() function which is an object having a property timeout in milliseconds and a property cb callback function. Whenever your retry operation takes longer than timeout to execute, the timeout callback function cb is called.
|
|
220
|
+
|
|
221
|
+
0.5.0 Some minor refactoring.
|
|
222
|
+
|
|
223
|
+
0.4.0 Changed retryOperation.try() to retryOperation.attempt(). Deprecated the aliases start() and try() for it.
|
|
224
|
+
|
|
225
|
+
0.3.0 Added retryOperation.start() which is an alias for retryOperation.try().
|
|
226
|
+
|
|
227
|
+
0.2.0 Added attempts() function and parameter to retryOperation.try() representing the number of attempts it took to call fn().
|
|
Binary file
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
var dns = require('dns');
|
|
2
|
+
var retry = require('../lib/retry');
|
|
3
|
+
|
|
4
|
+
function faultTolerantResolve(address, cb) {
|
|
5
|
+
var opts = {
|
|
6
|
+
retries: 2,
|
|
7
|
+
factor: 2,
|
|
8
|
+
minTimeout: 1 * 1000,
|
|
9
|
+
maxTimeout: 2 * 1000,
|
|
10
|
+
randomize: true
|
|
11
|
+
};
|
|
12
|
+
var operation = retry.operation(opts);
|
|
13
|
+
|
|
14
|
+
operation.attempt(function(currentAttempt) {
|
|
15
|
+
dns.resolve(address, function(err, addresses) {
|
|
16
|
+
if (operation.retry(err)) {
|
|
17
|
+
return;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
cb(operation.mainError(), operation.errors(), addresses);
|
|
21
|
+
});
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
faultTolerantResolve('nodejs.org', function(err, errors, addresses) {
|
|
26
|
+
console.warn('err:');
|
|
27
|
+
console.log(err);
|
|
28
|
+
|
|
29
|
+
console.warn('addresses:');
|
|
30
|
+
console.log(addresses);
|
|
31
|
+
});
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
var retry = require('../lib/retry');
|
|
2
|
+
|
|
3
|
+
function attemptAsyncOperation(someInput, cb) {
|
|
4
|
+
var opts = {
|
|
5
|
+
retries: 2,
|
|
6
|
+
factor: 2,
|
|
7
|
+
minTimeout: 1 * 1000,
|
|
8
|
+
maxTimeout: 2 * 1000,
|
|
9
|
+
randomize: true
|
|
10
|
+
};
|
|
11
|
+
var operation = retry.operation(opts);
|
|
12
|
+
|
|
13
|
+
operation.attempt(function(currentAttempt) {
|
|
14
|
+
failingAsyncOperation(someInput, function(err, result) {
|
|
15
|
+
|
|
16
|
+
if (err && err.message === 'A fatal error') {
|
|
17
|
+
operation.stop();
|
|
18
|
+
return cb(err);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
if (operation.retry(err)) {
|
|
22
|
+
return;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
cb(operation.mainError(), operation.errors(), result);
|
|
26
|
+
});
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
attemptAsyncOperation('test input', function(err, errors, result) {
|
|
31
|
+
console.warn('err:');
|
|
32
|
+
console.log(err);
|
|
33
|
+
|
|
34
|
+
console.warn('result:');
|
|
35
|
+
console.log(result);
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
function failingAsyncOperation(input, cb) {
|
|
39
|
+
return setImmediate(cb.bind(null, new Error('A fatal error')));
|
|
40
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
module.exports = require('./lib/retry');
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
var RetryOperation = require('./retry_operation');
|
|
2
|
+
|
|
3
|
+
exports.operation = function(options) {
|
|
4
|
+
var timeouts = exports.timeouts(options);
|
|
5
|
+
return new RetryOperation(timeouts, {
|
|
6
|
+
forever: options && options.forever,
|
|
7
|
+
unref: options && options.unref,
|
|
8
|
+
maxRetryTime: options && options.maxRetryTime
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
exports.timeouts = function(options) {
|
|
13
|
+
if (options instanceof Array) {
|
|
14
|
+
return [].concat(options);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
var opts = {
|
|
18
|
+
retries: 10,
|
|
19
|
+
factor: 2,
|
|
20
|
+
minTimeout: 1 * 1000,
|
|
21
|
+
maxTimeout: Infinity,
|
|
22
|
+
randomize: false
|
|
23
|
+
};
|
|
24
|
+
for (var key in options) {
|
|
25
|
+
opts[key] = options[key];
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
if (opts.minTimeout > opts.maxTimeout) {
|
|
29
|
+
throw new Error('minTimeout is greater than maxTimeout');
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
var timeouts = [];
|
|
33
|
+
for (var i = 0; i < opts.retries; i++) {
|
|
34
|
+
timeouts.push(this.createTimeout(i, opts));
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
if (options && options.forever && !timeouts.length) {
|
|
38
|
+
timeouts.push(this.createTimeout(i, opts));
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// sort the array numerically ascending
|
|
42
|
+
timeouts.sort(function(a,b) {
|
|
43
|
+
return a - b;
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
return timeouts;
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
exports.createTimeout = function(attempt, opts) {
|
|
50
|
+
var random = (opts.randomize)
|
|
51
|
+
? (Math.random() + 1)
|
|
52
|
+
: 1;
|
|
53
|
+
|
|
54
|
+
var timeout = Math.round(random * opts.minTimeout * Math.pow(opts.factor, attempt));
|
|
55
|
+
timeout = Math.min(timeout, opts.maxTimeout);
|
|
56
|
+
|
|
57
|
+
return timeout;
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
exports.wrap = function(obj, options, methods) {
|
|
61
|
+
if (options instanceof Array) {
|
|
62
|
+
methods = options;
|
|
63
|
+
options = null;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
if (!methods) {
|
|
67
|
+
methods = [];
|
|
68
|
+
for (var key in obj) {
|
|
69
|
+
if (typeof obj[key] === 'function') {
|
|
70
|
+
methods.push(key);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
for (var i = 0; i < methods.length; i++) {
|
|
76
|
+
var method = methods[i];
|
|
77
|
+
var original = obj[method];
|
|
78
|
+
|
|
79
|
+
obj[method] = function retryWrapper(original) {
|
|
80
|
+
var op = exports.operation(options);
|
|
81
|
+
var args = Array.prototype.slice.call(arguments, 1);
|
|
82
|
+
var callback = args.pop();
|
|
83
|
+
|
|
84
|
+
args.push(function(err) {
|
|
85
|
+
if (op.retry(err)) {
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
if (err) {
|
|
89
|
+
arguments[0] = op.mainError();
|
|
90
|
+
}
|
|
91
|
+
callback.apply(this, arguments);
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
op.attempt(function() {
|
|
95
|
+
original.apply(obj, args);
|
|
96
|
+
});
|
|
97
|
+
}.bind(obj, original);
|
|
98
|
+
obj[method].options = options;
|
|
99
|
+
}
|
|
100
|
+
};
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
function RetryOperation(timeouts, options) {
|
|
2
|
+
// Compatibility for the old (timeouts, retryForever) signature
|
|
3
|
+
if (typeof options === 'boolean') {
|
|
4
|
+
options = { forever: options };
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
this._originalTimeouts = JSON.parse(JSON.stringify(timeouts));
|
|
8
|
+
this._timeouts = timeouts;
|
|
9
|
+
this._options = options || {};
|
|
10
|
+
this._maxRetryTime = options && options.maxRetryTime || Infinity;
|
|
11
|
+
this._fn = null;
|
|
12
|
+
this._errors = [];
|
|
13
|
+
this._attempts = 1;
|
|
14
|
+
this._operationTimeout = null;
|
|
15
|
+
this._operationTimeoutCb = null;
|
|
16
|
+
this._timeout = null;
|
|
17
|
+
this._operationStart = null;
|
|
18
|
+
|
|
19
|
+
if (this._options.forever) {
|
|
20
|
+
this._cachedTimeouts = this._timeouts.slice(0);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
module.exports = RetryOperation;
|
|
24
|
+
|
|
25
|
+
RetryOperation.prototype.reset = function() {
|
|
26
|
+
this._attempts = 1;
|
|
27
|
+
this._timeouts = this._originalTimeouts;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
RetryOperation.prototype.stop = function() {
|
|
31
|
+
if (this._timeout) {
|
|
32
|
+
clearTimeout(this._timeout);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
this._timeouts = [];
|
|
36
|
+
this._cachedTimeouts = null;
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
RetryOperation.prototype.retry = function(err) {
|
|
40
|
+
if (this._timeout) {
|
|
41
|
+
clearTimeout(this._timeout);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
if (!err) {
|
|
45
|
+
return false;
|
|
46
|
+
}
|
|
47
|
+
var currentTime = new Date().getTime();
|
|
48
|
+
if (err && currentTime - this._operationStart >= this._maxRetryTime) {
|
|
49
|
+
this._errors.unshift(new Error('RetryOperation timeout occurred'));
|
|
50
|
+
return false;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
this._errors.push(err);
|
|
54
|
+
|
|
55
|
+
var timeout = this._timeouts.shift();
|
|
56
|
+
if (timeout === undefined) {
|
|
57
|
+
if (this._cachedTimeouts) {
|
|
58
|
+
// retry forever, only keep last error
|
|
59
|
+
this._errors.splice(this._errors.length - 1, this._errors.length);
|
|
60
|
+
this._timeouts = this._cachedTimeouts.slice(0);
|
|
61
|
+
timeout = this._timeouts.shift();
|
|
62
|
+
} else {
|
|
63
|
+
return false;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
var self = this;
|
|
68
|
+
var timer = setTimeout(function() {
|
|
69
|
+
self._attempts++;
|
|
70
|
+
|
|
71
|
+
if (self._operationTimeoutCb) {
|
|
72
|
+
self._timeout = setTimeout(function() {
|
|
73
|
+
self._operationTimeoutCb(self._attempts);
|
|
74
|
+
}, self._operationTimeout);
|
|
75
|
+
|
|
76
|
+
if (self._options.unref) {
|
|
77
|
+
self._timeout.unref();
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
self._fn(self._attempts);
|
|
82
|
+
}, timeout);
|
|
83
|
+
|
|
84
|
+
if (this._options.unref) {
|
|
85
|
+
timer.unref();
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
return true;
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
RetryOperation.prototype.attempt = function(fn, timeoutOps) {
|
|
92
|
+
this._fn = fn;
|
|
93
|
+
|
|
94
|
+
if (timeoutOps) {
|
|
95
|
+
if (timeoutOps.timeout) {
|
|
96
|
+
this._operationTimeout = timeoutOps.timeout;
|
|
97
|
+
}
|
|
98
|
+
if (timeoutOps.cb) {
|
|
99
|
+
this._operationTimeoutCb = timeoutOps.cb;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
var self = this;
|
|
104
|
+
if (this._operationTimeoutCb) {
|
|
105
|
+
this._timeout = setTimeout(function() {
|
|
106
|
+
self._operationTimeoutCb();
|
|
107
|
+
}, self._operationTimeout);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
this._operationStart = new Date().getTime();
|
|
111
|
+
|
|
112
|
+
this._fn(this._attempts);
|
|
113
|
+
};
|
|
114
|
+
|
|
115
|
+
RetryOperation.prototype.try = function(fn) {
|
|
116
|
+
console.log('Using RetryOperation.try() is deprecated');
|
|
117
|
+
this.attempt(fn);
|
|
118
|
+
};
|
|
119
|
+
|
|
120
|
+
RetryOperation.prototype.start = function(fn) {
|
|
121
|
+
console.log('Using RetryOperation.start() is deprecated');
|
|
122
|
+
this.attempt(fn);
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
RetryOperation.prototype.start = RetryOperation.prototype.try;
|
|
126
|
+
|
|
127
|
+
RetryOperation.prototype.errors = function() {
|
|
128
|
+
return this._errors;
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
RetryOperation.prototype.attempts = function() {
|
|
132
|
+
return this._attempts;
|
|
133
|
+
};
|
|
134
|
+
|
|
135
|
+
RetryOperation.prototype.mainError = function() {
|
|
136
|
+
if (this._errors.length === 0) {
|
|
137
|
+
return null;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
var counts = {};
|
|
141
|
+
var mainError = null;
|
|
142
|
+
var mainErrorCount = 0;
|
|
143
|
+
|
|
144
|
+
for (var i = 0; i < this._errors.length; i++) {
|
|
145
|
+
var error = this._errors[i];
|
|
146
|
+
var message = error.message;
|
|
147
|
+
var count = (counts[message] || 0) + 1;
|
|
148
|
+
|
|
149
|
+
counts[message] = count;
|
|
150
|
+
|
|
151
|
+
if (count >= mainErrorCount) {
|
|
152
|
+
mainError = error;
|
|
153
|
+
mainErrorCount = count;
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
return mainError;
|
|
158
|
+
};
|