@justjoshn/pi-pstack-v2 0.1.5 → 0.1.6

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.
Files changed (983) hide show
  1. package/README.md +4 -4
  2. package/docs/guide/05-build-and-clean.md +1 -1
  3. package/docs/pi-mechanisms.md +1 -1
  4. package/package.json +12 -5
  5. package/skills/poteto-mode/scripts/bootstrap.ts +1 -2
  6. package/skills/poteto-mode/scripts/bun.lock +3 -0
  7. package/skills/poteto-mode/scripts/node_modules/zod/LICENSE +21 -0
  8. package/skills/poteto-mode/scripts/node_modules/zod/README.md +218 -0
  9. package/skills/poteto-mode/scripts/node_modules/zod/compile.cjs +96 -0
  10. package/skills/poteto-mode/scripts/node_modules/zod/compile.d.cts +1 -0
  11. package/skills/poteto-mode/scripts/node_modules/zod/compile.d.ts +1 -0
  12. package/skills/poteto-mode/scripts/node_modules/zod/compile.js +52 -0
  13. package/skills/poteto-mode/scripts/node_modules/zod/index.cjs +52 -0
  14. package/skills/poteto-mode/scripts/node_modules/zod/index.d.cts +3 -0
  15. package/skills/poteto-mode/scripts/node_modules/zod/index.d.ts +3 -0
  16. package/skills/poteto-mode/scripts/node_modules/zod/index.js +7 -0
  17. package/skills/poteto-mode/scripts/node_modules/zod/locales/index.cjs +36 -0
  18. package/skills/poteto-mode/scripts/node_modules/zod/locales/index.d.cts +1 -0
  19. package/skills/poteto-mode/scripts/node_modules/zod/locales/index.d.ts +1 -0
  20. package/skills/poteto-mode/scripts/node_modules/zod/locales/index.js +1 -0
  21. package/skills/poteto-mode/scripts/node_modules/zod/locales/package.json +7 -0
  22. package/skills/poteto-mode/scripts/node_modules/zod/mini/index.cjs +51 -0
  23. package/skills/poteto-mode/scripts/node_modules/zod/mini/index.d.cts +3 -0
  24. package/skills/poteto-mode/scripts/node_modules/zod/mini/index.d.ts +3 -0
  25. package/skills/poteto-mode/scripts/node_modules/zod/mini/index.js +3 -0
  26. package/skills/poteto-mode/scripts/node_modules/zod/mini/package.json +7 -0
  27. package/skills/poteto-mode/scripts/node_modules/zod/package.json +147 -0
  28. package/skills/poteto-mode/scripts/node_modules/zod/src/compile.ts +56 -0
  29. package/skills/poteto-mode/scripts/node_modules/zod/src/index.ts +7 -0
  30. package/skills/poteto-mode/scripts/node_modules/zod/src/locales/index.ts +1 -0
  31. package/skills/poteto-mode/scripts/node_modules/zod/src/mini/index.ts +3 -0
  32. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/ZodError.ts +340 -0
  33. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/datetime.ts +58 -0
  34. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/discriminatedUnion.ts +80 -0
  35. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/index.ts +59 -0
  36. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/ipv4.ts +57 -0
  37. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/object.ts +69 -0
  38. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/primitives.ts +162 -0
  39. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/realworld.ts +63 -0
  40. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/string.ts +55 -0
  41. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/benchmarks/union.ts +80 -0
  42. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/errors.ts +13 -0
  43. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/external.ts +6 -0
  44. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/helpers/enumUtil.ts +17 -0
  45. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/helpers/errorUtil.ts +8 -0
  46. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/helpers/parseUtil.ts +176 -0
  47. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/helpers/partialUtil.ts +34 -0
  48. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/helpers/typeAliases.ts +2 -0
  49. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/helpers/util.ts +224 -0
  50. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/index.ts +4 -0
  51. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/locales/en.ts +124 -0
  52. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/standard-schema.ts +113 -0
  53. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/Mocker.ts +54 -0
  54. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/all-errors.test.ts +157 -0
  55. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/anyunknown.test.ts +28 -0
  56. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/array.test.ts +71 -0
  57. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/async-parsing.test.ts +388 -0
  58. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/async-refinements.test.ts +46 -0
  59. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/base.test.ts +29 -0
  60. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/bigint.test.ts +55 -0
  61. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/branded.test.ts +53 -0
  62. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/catch.test.ts +220 -0
  63. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/coerce.test.ts +133 -0
  64. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/complex.test.ts +70 -0
  65. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/custom.test.ts +31 -0
  66. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/date.test.ts +32 -0
  67. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/deepmasking.test.ts +186 -0
  68. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/default.test.ts +112 -0
  69. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/description.test.ts +33 -0
  70. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/discriminated-unions.test.ts +315 -0
  71. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/enum.test.ts +80 -0
  72. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/error.test.ts +586 -0
  73. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/firstparty.test.ts +87 -0
  74. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/firstpartyschematypes.test.ts +21 -0
  75. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/function.test.ts +261 -0
  76. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/generics.test.ts +48 -0
  77. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/instanceof.test.ts +37 -0
  78. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/intersection.test.ts +128 -0
  79. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/language-server.source.ts +76 -0
  80. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/language-server.test.ts +206 -0
  81. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/literal.test.ts +36 -0
  82. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/map.test.ts +110 -0
  83. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/masking.test.ts +4 -0
  84. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/mocker.test.ts +19 -0
  85. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/nan.test.ts +24 -0
  86. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/nativeEnum.test.ts +87 -0
  87. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/nullable.test.ts +42 -0
  88. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/number.test.ts +176 -0
  89. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/object-augmentation.test.ts +29 -0
  90. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/object-in-es5-env.test.ts +29 -0
  91. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/object.test.ts +431 -0
  92. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/optional.test.ts +42 -0
  93. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/parseUtil.test.ts +23 -0
  94. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/parser.test.ts +41 -0
  95. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/partials.test.ts +243 -0
  96. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/pickomit.test.ts +111 -0
  97. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/pipeline.test.ts +29 -0
  98. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/preprocess.test.ts +186 -0
  99. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/primitive.test.ts +440 -0
  100. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/promise.test.ts +90 -0
  101. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/readonly.test.ts +114 -0
  102. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/record.test.ts +171 -0
  103. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/recursive.test.ts +197 -0
  104. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/refine.test.ts +313 -0
  105. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/safeparse.test.ts +27 -0
  106. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/set.test.ts +142 -0
  107. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/standard-schema.test.ts +83 -0
  108. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/string.test.ts +922 -0
  109. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/transformer.test.ts +233 -0
  110. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/tuple.test.ts +90 -0
  111. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/unions.test.ts +57 -0
  112. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/validations.test.ts +133 -0
  113. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/tests/void.test.ts +15 -0
  114. package/skills/poteto-mode/scripts/node_modules/zod/src/v3/types.ts +5138 -0
  115. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/checks.ts +33 -0
  116. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/coerce.ts +27 -0
  117. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/compat.ts +78 -0
  118. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/deep-partial.ts +76 -0
  119. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/errors.ts +97 -0
  120. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/external.ts +57 -0
  121. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/from-json-schema.ts +944 -0
  122. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/in-out.ts +45 -0
  123. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/index.ts +5 -0
  124. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/iso.ts +20 -0
  125. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/parse.ts +88 -0
  126. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/schemas.ts +2937 -0
  127. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/anyunknown.test.ts +26 -0
  128. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/apply.test.ts +86 -0
  129. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/array.test.ts +291 -0
  130. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/assignability.test.ts +402 -0
  131. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/async-parsing.test.ts +381 -0
  132. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/async-refinements.test.ts +68 -0
  133. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/base.test.ts +7 -0
  134. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/bigint.test.ts +89 -0
  135. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/brand.test.ts +106 -0
  136. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/catch.test.ts +604 -0
  137. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/coalesce.test.ts +20 -0
  138. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/codec-examples.test.ts +572 -0
  139. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/codec.test.ts +704 -0
  140. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/coerce.test.ts +160 -0
  141. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/continuability.test.ts +374 -0
  142. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/credit-card.test.ts +76 -0
  143. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/custom.test.ts +40 -0
  144. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/cyclic-data.test.ts +985 -0
  145. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/date.test.ts +92 -0
  146. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/datetime.test.ts +316 -0
  147. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/deep-partial.test.ts +380 -0
  148. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/default-locale.test.ts +32 -0
  149. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/default.test.ts +455 -0
  150. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/describe-meta-checks.test.ts +27 -0
  151. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/description.test.ts +32 -0
  152. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/detached-methods.test.ts +221 -0
  153. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/discriminated-unions.test.ts +942 -0
  154. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/enum.test.ts +305 -0
  155. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/error-utils.test.ts +917 -0
  156. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/error.test.ts +1108 -0
  157. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/file.test.ts +96 -0
  158. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/firstparty.test.ts +179 -0
  159. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/fix-json-issue.test.ts +26 -0
  160. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/from-json-schema.test.ts +1467 -0
  161. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/function.test.ts +391 -0
  162. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/generics.test.ts +72 -0
  163. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/global-config.test.ts +32 -0
  164. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/hash.test.ts +67 -0
  165. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/iban.test.ts +81 -0
  166. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/in-out.test.ts +159 -0
  167. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/index.test.ts +958 -0
  168. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/instance-footprint.test.ts +319 -0
  169. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/instanceof.test.ts +127 -0
  170. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/intersection.test.ts +334 -0
  171. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/issue-schema.test.ts +215 -0
  172. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/jitless-allows-eval.test.ts +39 -0
  173. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/json.test.ts +109 -0
  174. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/lazy.test.ts +262 -0
  175. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/literal.test.ts +128 -0
  176. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/locales_ka.test.ts +29 -0
  177. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/locales_ro.test.ts +24 -0
  178. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/map.test.ts +349 -0
  179. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/nan.test.ts +21 -0
  180. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/nested-refine.test.ts +168 -0
  181. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/nonoptional.test.ts +101 -0
  182. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/nullable.test.ts +22 -0
  183. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/number.test.ts +401 -0
  184. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/object.test.ts +1006 -0
  185. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/optin-ladder.test.ts +235 -0
  186. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/optional.test.ts +366 -0
  187. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/partial.test.ts +497 -0
  188. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/pickomit.test.ts +211 -0
  189. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/pipe.test.ts +101 -0
  190. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/prefault.test.ts +144 -0
  191. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/preprocess-types.test.ts +44 -0
  192. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/preprocess.test.ts +351 -0
  193. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/primitive.test.ts +175 -0
  194. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/promise.test.ts +81 -0
  195. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/properties.test.ts +141 -0
  196. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/prototypes.test.ts +23 -0
  197. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/readonly.test.ts +184 -0
  198. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/record.test.ts +885 -0
  199. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/recursive-types.test.ts +707 -0
  200. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/redos.test.ts +68 -0
  201. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/refine.test.ts +693 -0
  202. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/registries.test.ts +243 -0
  203. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/set.test.ts +196 -0
  204. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/standard-schema.test.ts +153 -0
  205. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/string-formats.test.ts +125 -0
  206. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/string.test.ts +1440 -0
  207. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/stringbool.test.ts +124 -0
  208. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/template-literal.test.ts +812 -0
  209. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/to-json-schema-methods.test.ts +438 -0
  210. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts +4733 -0
  211. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/transform.test.ts +378 -0
  212. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/tuple.test.ts +511 -0
  213. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/union.test.ts +310 -0
  214. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/url.test.ts +13 -0
  215. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/validate.test.ts +645 -0
  216. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/validations.test.ts +283 -0
  217. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/classic/tests/void.test.ts +12 -0
  218. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/api.ts +1875 -0
  219. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/checks.ts +1266 -0
  220. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/compile.ts +2322 -0
  221. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/core.ts +230 -0
  222. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/doc.ts +52 -0
  223. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/errors.ts +543 -0
  224. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/index.ts +19 -0
  225. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/json-schema-generator.ts +131 -0
  226. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/json-schema-processors.ts +934 -0
  227. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/json-schema.ts +148 -0
  228. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/memoizer.ts +331 -0
  229. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/parse.ts +309 -0
  230. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/regexes.ts +217 -0
  231. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/registries.ts +105 -0
  232. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/schemas.ts +5226 -0
  233. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/standard-schema.ts +159 -0
  234. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/cached.test.ts +54 -0
  235. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/compile-differential.test.ts +1004 -0
  236. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/compile-generative.test.ts +445 -0
  237. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/compile-global.test.ts +89 -0
  238. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/compile-off-by-default.test.ts +26 -0
  239. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/compile-stats.test.ts +34 -0
  240. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/compile.test.ts +2036 -0
  241. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/email-regex.test.ts +140 -0
  242. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/extend.test.ts +59 -0
  243. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/index.test.ts +46 -0
  244. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/be.test.ts +124 -0
  245. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/el.test.ts +214 -0
  246. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/en.test.ts +22 -0
  247. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/es.test.ts +180 -0
  248. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/fr.test.ts +72 -0
  249. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/he.test.ts +379 -0
  250. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/hr.test.ts +163 -0
  251. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/nl.test.ts +46 -0
  252. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/parity.test.ts +42 -0
  253. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/ru.test.ts +128 -0
  254. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/tg.test.ts +85 -0
  255. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/tk.test.ts +69 -0
  256. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/tr.test.ts +69 -0
  257. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/locales/uz.test.ts +105 -0
  258. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/polyfill-collision.test.ts +46 -0
  259. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/record-constructor.test.ts +125 -0
  260. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/recursive-tuples.test.ts +45 -0
  261. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/treeshake.test.ts +51 -0
  262. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/tests/url-no-canparse.test.ts +133 -0
  263. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/to-json-schema.ts +857 -0
  264. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/util.ts +1293 -0
  265. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/versions.ts +5 -0
  266. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/visit.ts +193 -0
  267. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/core/zsf.ts +323 -0
  268. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/index.ts +4 -0
  269. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ar.ts +120 -0
  270. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/az.ts +116 -0
  271. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/be.ts +188 -0
  272. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/bg.ts +133 -0
  273. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/bn.ts +123 -0
  274. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ca.ts +121 -0
  275. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ckb.ts +140 -0
  276. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/cs.ts +123 -0
  277. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/da.ts +128 -0
  278. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/de.ts +121 -0
  279. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/el.ts +124 -0
  280. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/en.ts +136 -0
  281. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/eo.ts +123 -0
  282. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/es.ts +145 -0
  283. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/fa.ts +131 -0
  284. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/fi.ts +126 -0
  285. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/fr-CA.ts +121 -0
  286. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/fr.ts +139 -0
  287. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/gu.ts +123 -0
  288. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/he.ts +253 -0
  289. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/hi.ts +126 -0
  290. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/hr.ts +135 -0
  291. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/hu.ts +122 -0
  292. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/hy.ts +175 -0
  293. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/id.ts +120 -0
  294. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/index.ts +63 -0
  295. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/is.ts +124 -0
  296. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/it.ts +121 -0
  297. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ja.ts +119 -0
  298. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ka.ts +128 -0
  299. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/kh.ts +7 -0
  300. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/km.ts +124 -0
  301. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/kn.ts +126 -0
  302. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ko.ts +126 -0
  303. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/lt.ts +243 -0
  304. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/mk.ts +123 -0
  305. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ms.ts +120 -0
  306. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ne.ts +128 -0
  307. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/nl.ts +126 -0
  308. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/nn.ts +121 -0
  309. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/no.ts +121 -0
  310. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ota.ts +122 -0
  311. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/pl.ts +123 -0
  312. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ps.ts +131 -0
  313. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/pt-BR.ts +161 -0
  314. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/pt.ts +159 -0
  315. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ro.ts +132 -0
  316. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ru.ts +188 -0
  317. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/sk.ts +123 -0
  318. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/sl.ts +123 -0
  319. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/sv.ts +124 -0
  320. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ta.ts +123 -0
  321. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/tg.ts +135 -0
  322. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/th.ts +124 -0
  323. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/tk.ts +113 -0
  324. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/tr.ts +116 -0
  325. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ua.ts +7 -0
  326. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/uk.ts +122 -0
  327. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/ur.ts +124 -0
  328. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/uz.ts +120 -0
  329. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/vi.ts +122 -0
  330. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/yo.ts +129 -0
  331. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/zh-CN.ts +121 -0
  332. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/locales/zh-TW.ts +120 -0
  333. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/checks.ts +33 -0
  334. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/coerce.ts +27 -0
  335. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/deep-partial.ts +73 -0
  336. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/external.ts +52 -0
  337. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/in-out.ts +45 -0
  338. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/index.ts +3 -0
  339. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/iso.ts +66 -0
  340. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/parse.ts +16 -0
  341. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/schemas.ts +2051 -0
  342. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/apply.test.ts +57 -0
  343. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/assignability.test.ts +190 -0
  344. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/brand.test.ts +94 -0
  345. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/checks.test.ts +158 -0
  346. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/codec.test.ts +582 -0
  347. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/computed.test.ts +30 -0
  348. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/cyclic-data.test.ts +84 -0
  349. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/deep-partial.test.ts +54 -0
  350. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/error.test.ts +41 -0
  351. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/functions.test.ts +14 -0
  352. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/index.test.ts +1146 -0
  353. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/number.test.ts +109 -0
  354. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/object.test.ts +292 -0
  355. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/prototypes.test.ts +43 -0
  356. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/recursive-types.test.ts +341 -0
  357. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/standard-schema.test.ts +50 -0
  358. package/skills/poteto-mode/scripts/node_modules/zod/src/v4/mini/tests/string.test.ts +396 -0
  359. package/skills/poteto-mode/scripts/node_modules/zod/src/v4-mini/index.ts +3 -0
  360. package/skills/poteto-mode/scripts/node_modules/zod/v3/ZodError.cjs +167 -0
  361. package/skills/poteto-mode/scripts/node_modules/zod/v3/ZodError.d.cts +164 -0
  362. package/skills/poteto-mode/scripts/node_modules/zod/v3/ZodError.d.ts +164 -0
  363. package/skills/poteto-mode/scripts/node_modules/zod/v3/ZodError.js +143 -0
  364. package/skills/poteto-mode/scripts/node_modules/zod/v3/errors.cjs +36 -0
  365. package/skills/poteto-mode/scripts/node_modules/zod/v3/errors.d.cts +5 -0
  366. package/skills/poteto-mode/scripts/node_modules/zod/v3/errors.d.ts +5 -0
  367. package/skills/poteto-mode/scripts/node_modules/zod/v3/errors.js +9 -0
  368. package/skills/poteto-mode/scripts/node_modules/zod/v3/external.cjs +41 -0
  369. package/skills/poteto-mode/scripts/node_modules/zod/v3/external.d.cts +6 -0
  370. package/skills/poteto-mode/scripts/node_modules/zod/v3/external.d.ts +6 -0
  371. package/skills/poteto-mode/scripts/node_modules/zod/v3/external.js +6 -0
  372. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/enumUtil.cjs +21 -0
  373. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/enumUtil.d.cts +8 -0
  374. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/enumUtil.d.ts +8 -0
  375. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/enumUtil.js +1 -0
  376. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/errorUtil.cjs +28 -0
  377. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/errorUtil.d.cts +9 -0
  378. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/errorUtil.d.ts +9 -0
  379. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/errorUtil.js +6 -0
  380. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/parseUtil.cjs +143 -0
  381. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/parseUtil.d.cts +78 -0
  382. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/parseUtil.d.ts +78 -0
  383. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/parseUtil.js +109 -0
  384. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/partialUtil.cjs +21 -0
  385. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/partialUtil.d.cts +8 -0
  386. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/partialUtil.d.ts +8 -0
  387. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/partialUtil.js +1 -0
  388. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/typeAliases.cjs +21 -0
  389. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/typeAliases.d.cts +2 -0
  390. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/typeAliases.d.ts +2 -0
  391. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/typeAliases.js +1 -0
  392. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/util.cjs +156 -0
  393. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/util.d.cts +85 -0
  394. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/util.d.ts +85 -0
  395. package/skills/poteto-mode/scripts/node_modules/zod/v3/helpers/util.js +133 -0
  396. package/skills/poteto-mode/scripts/node_modules/zod/v3/index.cjs +52 -0
  397. package/skills/poteto-mode/scripts/node_modules/zod/v3/index.d.cts +4 -0
  398. package/skills/poteto-mode/scripts/node_modules/zod/v3/index.d.ts +4 -0
  399. package/skills/poteto-mode/scripts/node_modules/zod/v3/index.js +4 -0
  400. package/skills/poteto-mode/scripts/node_modules/zod/v3/locales/en.cjs +112 -0
  401. package/skills/poteto-mode/scripts/node_modules/zod/v3/locales/en.d.cts +3 -0
  402. package/skills/poteto-mode/scripts/node_modules/zod/v3/locales/en.d.ts +3 -0
  403. package/skills/poteto-mode/scripts/node_modules/zod/v3/locales/en.js +109 -0
  404. package/skills/poteto-mode/scripts/node_modules/zod/v3/package.json +7 -0
  405. package/skills/poteto-mode/scripts/node_modules/zod/v3/standard-schema.cjs +21 -0
  406. package/skills/poteto-mode/scripts/node_modules/zod/v3/standard-schema.d.cts +102 -0
  407. package/skills/poteto-mode/scripts/node_modules/zod/v3/standard-schema.d.ts +102 -0
  408. package/skills/poteto-mode/scripts/node_modules/zod/v3/standard-schema.js +1 -0
  409. package/skills/poteto-mode/scripts/node_modules/zod/v3/types.cjs +3798 -0
  410. package/skills/poteto-mode/scripts/node_modules/zod/v3/types.d.cts +1034 -0
  411. package/skills/poteto-mode/scripts/node_modules/zod/v3/types.d.ts +1034 -0
  412. package/skills/poteto-mode/scripts/node_modules/zod/v3/types.js +3697 -0
  413. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/checks.cjs +53 -0
  414. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/checks.d.cts +1 -0
  415. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/checks.d.ts +1 -0
  416. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/checks.js +1 -0
  417. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/coerce.cjs +66 -0
  418. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/coerce.d.cts +17 -0
  419. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/coerce.d.ts +17 -0
  420. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/coerce.js +17 -0
  421. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/compat.cjs +80 -0
  422. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/compat.d.cts +48 -0
  423. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/compat.d.ts +48 -0
  424. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/compat.js +31 -0
  425. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/deep-partial.cjs +58 -0
  426. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/deep-partial.d.cts +14 -0
  427. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/deep-partial.d.ts +14 -0
  428. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/deep-partial.js +13 -0
  429. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/errors.cjs +102 -0
  430. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/errors.d.cts +29 -0
  431. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/errors.d.ts +29 -0
  432. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/errors.js +57 -0
  433. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/external.cjs +97 -0
  434. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/external.d.cts +19 -0
  435. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/external.d.ts +19 -0
  436. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/external.js +17 -0
  437. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/from-json-schema.cjs +926 -0
  438. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/from-json-schema.d.cts +12 -0
  439. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/from-json-schema.d.ts +12 -0
  440. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/from-json-schema.js +881 -0
  441. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/in-out.cjs +82 -0
  442. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/in-out.d.cts +8 -0
  443. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/in-out.d.ts +8 -0
  444. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/in-out.js +36 -0
  445. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/index.cjs +52 -0
  446. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/index.d.cts +3 -0
  447. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/index.d.ts +3 -0
  448. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/index.js +4 -0
  449. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/iso.cjs +68 -0
  450. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/iso.d.cts +7 -0
  451. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/iso.d.ts +7 -0
  452. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/iso.js +15 -0
  453. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/package.json +7 -0
  454. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/parse.cjs +63 -0
  455. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/parse.d.cts +44 -0
  456. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/parse.d.ts +44 -0
  457. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/parse.js +16 -0
  458. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/schemas.cjs +1676 -0
  459. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/schemas.d.cts +816 -0
  460. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/schemas.d.ts +816 -0
  461. package/skills/poteto-mode/scripts/node_modules/zod/v4/classic/schemas.js +1535 -0
  462. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/api.cjs +1269 -0
  463. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/api.d.cts +335 -0
  464. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/api.d.ts +335 -0
  465. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/api.js +1107 -0
  466. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/checks.cjs +561 -0
  467. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/checks.d.cts +294 -0
  468. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/checks.d.ts +294 -0
  469. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/checks.js +516 -0
  470. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/compile.cjs +1916 -0
  471. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/compile.d.cts +65 -0
  472. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/compile.d.ts +65 -0
  473. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/compile.js +1866 -0
  474. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/core.cjs +167 -0
  475. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/core.d.cts +82 -0
  476. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/core.d.ts +82 -0
  477. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/core.js +141 -0
  478. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/doc.cjs +61 -0
  479. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/doc.d.cts +16 -0
  480. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/doc.d.ts +16 -0
  481. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/doc.js +38 -0
  482. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/errors.cjs +317 -0
  483. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/errors.d.cts +225 -0
  484. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/errors.d.ts +225 -0
  485. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/errors.js +267 -0
  486. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/index.cjs +70 -0
  487. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/index.d.cts +19 -0
  488. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/index.d.ts +19 -0
  489. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/index.js +19 -0
  490. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-generator.cjs +122 -0
  491. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-generator.d.cts +65 -0
  492. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-generator.d.ts +65 -0
  493. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-generator.js +99 -0
  494. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-processors.cjs +929 -0
  495. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-processors.d.cts +65 -0
  496. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-processors.d.ts +65 -0
  497. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema-processors.js +843 -0
  498. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema.cjs +21 -0
  499. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema.d.cts +89 -0
  500. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema.d.ts +89 -0
  501. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/json-schema.js +1 -0
  502. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/memoizer.cjs +360 -0
  503. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/memoizer.d.cts +15 -0
  504. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/memoizer.d.ts +15 -0
  505. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/memoizer.js +311 -0
  506. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/package.json +7 -0
  507. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/parse.cjs +233 -0
  508. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/parse.d.cts +52 -0
  509. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/parse.d.ts +52 -0
  510. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/parse.js +175 -0
  511. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/regexes.cjs +209 -0
  512. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/regexes.d.cts +90 -0
  513. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/regexes.d.ts +90 -0
  514. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/regexes.js +156 -0
  515. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/registries.cjs +75 -0
  516. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/registries.d.cts +35 -0
  517. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/registries.d.ts +35 -0
  518. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/registries.js +51 -0
  519. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/schemas.cjs +2699 -0
  520. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/schemas.d.cts +1275 -0
  521. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/schemas.d.ts +1275 -0
  522. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/schemas.js +2636 -0
  523. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/standard-schema.cjs +21 -0
  524. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/standard-schema.d.cts +126 -0
  525. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/standard-schema.d.ts +126 -0
  526. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/standard-schema.js +1 -0
  527. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/to-json-schema.cjs +681 -0
  528. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/to-json-schema.d.cts +154 -0
  529. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/to-json-schema.d.ts +154 -0
  530. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/to-json-schema.js +651 -0
  531. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/util.cjs +964 -0
  532. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/util.d.cts +280 -0
  533. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/util.d.ts +280 -0
  534. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/util.js +873 -0
  535. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/versions.cjs +27 -0
  536. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/versions.d.cts +5 -0
  537. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/versions.d.ts +5 -0
  538. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/versions.js +5 -0
  539. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/visit.cjs +214 -0
  540. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/visit.d.cts +30 -0
  541. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/visit.d.ts +30 -0
  542. package/skills/poteto-mode/scripts/node_modules/zod/v4/core/visit.js +169 -0
  543. package/skills/poteto-mode/scripts/node_modules/zod/v4/index.cjs +51 -0
  544. package/skills/poteto-mode/scripts/node_modules/zod/v4/index.d.cts +3 -0
  545. package/skills/poteto-mode/scripts/node_modules/zod/v4/index.d.ts +3 -0
  546. package/skills/poteto-mode/scripts/node_modules/zod/v4/index.js +4 -0
  547. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ar.cjs +138 -0
  548. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ar.d.cts +5 -0
  549. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ar.d.ts +4 -0
  550. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ar.js +111 -0
  551. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/az.cjs +137 -0
  552. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/az.d.cts +5 -0
  553. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/az.d.ts +4 -0
  554. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/az.js +110 -0
  555. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/be.cjs +195 -0
  556. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/be.d.cts +5 -0
  557. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/be.d.ts +4 -0
  558. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/be.js +168 -0
  559. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bg.cjs +152 -0
  560. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bg.d.cts +5 -0
  561. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bg.d.ts +4 -0
  562. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bg.js +125 -0
  563. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bn.cjs +140 -0
  564. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bn.d.cts +5 -0
  565. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bn.d.ts +4 -0
  566. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/bn.js +113 -0
  567. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ca.cjs +139 -0
  568. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ca.d.cts +5 -0
  569. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ca.d.ts +4 -0
  570. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ca.js +112 -0
  571. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ckb.cjs +160 -0
  572. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ckb.d.cts +5 -0
  573. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ckb.d.ts +4 -0
  574. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ckb.js +133 -0
  575. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/cs.cjs +143 -0
  576. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/cs.d.cts +5 -0
  577. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/cs.d.ts +4 -0
  578. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/cs.js +116 -0
  579. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/da.cjs +147 -0
  580. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/da.d.cts +5 -0
  581. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/da.d.ts +4 -0
  582. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/da.js +120 -0
  583. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/de.cjs +140 -0
  584. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/de.d.cts +5 -0
  585. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/de.d.ts +4 -0
  586. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/de.js +113 -0
  587. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/el.cjs +139 -0
  588. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/el.d.cts +5 -0
  589. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/el.d.ts +4 -0
  590. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/el.js +112 -0
  591. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/en.cjs +152 -0
  592. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/en.d.cts +5 -0
  593. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/en.d.ts +4 -0
  594. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/en.js +125 -0
  595. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/eo.cjs +141 -0
  596. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/eo.d.cts +5 -0
  597. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/eo.d.ts +4 -0
  598. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/eo.js +114 -0
  599. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/es.cjs +163 -0
  600. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/es.d.cts +5 -0
  601. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/es.d.ts +4 -0
  602. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/es.js +136 -0
  603. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fa.cjs +146 -0
  604. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fa.d.cts +5 -0
  605. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fa.d.ts +4 -0
  606. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fa.js +119 -0
  607. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fi.cjs +144 -0
  608. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fi.d.cts +5 -0
  609. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fi.d.ts +4 -0
  610. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fi.js +117 -0
  611. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr-CA.cjs +139 -0
  612. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr-CA.d.cts +5 -0
  613. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr-CA.d.ts +4 -0
  614. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr-CA.js +112 -0
  615. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr.cjs +156 -0
  616. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr.d.cts +5 -0
  617. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr.d.ts +4 -0
  618. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/fr.js +129 -0
  619. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/gu.cjs +140 -0
  620. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/gu.d.cts +5 -0
  621. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/gu.d.ts +4 -0
  622. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/gu.js +113 -0
  623. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/he.cjs +248 -0
  624. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/he.d.cts +5 -0
  625. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/he.d.ts +4 -0
  626. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/he.js +221 -0
  627. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hi.cjs +138 -0
  628. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hi.d.cts +5 -0
  629. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hi.d.ts +4 -0
  630. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hi.js +111 -0
  631. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hr.cjs +153 -0
  632. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hr.d.cts +5 -0
  633. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hr.d.ts +4 -0
  634. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hr.js +126 -0
  635. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hu.cjs +140 -0
  636. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hu.d.cts +5 -0
  637. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hu.d.ts +4 -0
  638. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hu.js +113 -0
  639. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hy.cjs +185 -0
  640. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hy.d.cts +5 -0
  641. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hy.d.ts +4 -0
  642. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/hy.js +158 -0
  643. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/id.cjs +138 -0
  644. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/id.d.cts +5 -0
  645. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/id.d.ts +4 -0
  646. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/id.js +111 -0
  647. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/index.cjs +152 -0
  648. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/index.d.cts +63 -0
  649. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/index.d.ts +63 -0
  650. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/index.js +63 -0
  651. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/is.cjs +141 -0
  652. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/is.d.cts +5 -0
  653. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/is.d.ts +4 -0
  654. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/is.js +114 -0
  655. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/it.cjs +140 -0
  656. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/it.d.cts +5 -0
  657. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/it.d.ts +4 -0
  658. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/it.js +113 -0
  659. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ja.cjs +139 -0
  660. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ja.d.cts +5 -0
  661. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ja.d.ts +4 -0
  662. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ja.js +112 -0
  663. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ka.cjs +144 -0
  664. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ka.d.cts +5 -0
  665. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ka.d.ts +4 -0
  666. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ka.js +117 -0
  667. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kh.cjs +12 -0
  668. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kh.d.cts +5 -0
  669. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kh.d.ts +5 -0
  670. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kh.js +5 -0
  671. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/km.cjs +142 -0
  672. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/km.d.cts +5 -0
  673. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/km.d.ts +4 -0
  674. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/km.js +115 -0
  675. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kn.cjs +143 -0
  676. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kn.d.cts +5 -0
  677. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kn.d.ts +4 -0
  678. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/kn.js +116 -0
  679. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ko.cjs +143 -0
  680. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ko.d.cts +5 -0
  681. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ko.d.ts +4 -0
  682. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ko.js +116 -0
  683. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/lt.cjs +234 -0
  684. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/lt.d.cts +5 -0
  685. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/lt.d.ts +4 -0
  686. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/lt.js +207 -0
  687. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/mk.cjs +141 -0
  688. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/mk.d.cts +5 -0
  689. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/mk.d.ts +4 -0
  690. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/mk.js +114 -0
  691. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ms.cjs +139 -0
  692. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ms.d.cts +5 -0
  693. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ms.d.ts +4 -0
  694. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ms.js +112 -0
  695. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ne.cjs +138 -0
  696. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ne.d.cts +5 -0
  697. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ne.d.ts +4 -0
  698. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ne.js +111 -0
  699. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nl.cjs +142 -0
  700. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nl.d.cts +5 -0
  701. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nl.d.ts +4 -0
  702. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nl.js +115 -0
  703. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nn.cjs +140 -0
  704. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nn.d.cts +5 -0
  705. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nn.d.ts +4 -0
  706. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/nn.js +113 -0
  707. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/no.cjs +140 -0
  708. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/no.d.cts +5 -0
  709. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/no.d.ts +4 -0
  710. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/no.js +113 -0
  711. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ota.cjs +141 -0
  712. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ota.d.cts +5 -0
  713. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ota.d.ts +4 -0
  714. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ota.js +114 -0
  715. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/package.json +7 -0
  716. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pl.cjs +141 -0
  717. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pl.d.cts +5 -0
  718. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pl.d.ts +4 -0
  719. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pl.js +114 -0
  720. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ps.cjs +146 -0
  721. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ps.d.cts +5 -0
  722. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ps.d.ts +4 -0
  723. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ps.js +119 -0
  724. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt-BR.cjs +170 -0
  725. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt-BR.d.cts +5 -0
  726. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt-BR.d.ts +4 -0
  727. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt-BR.js +143 -0
  728. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt.cjs +169 -0
  729. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt.d.cts +5 -0
  730. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt.d.ts +4 -0
  731. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/pt.js +142 -0
  732. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ro.cjs +149 -0
  733. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ro.d.cts +5 -0
  734. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ro.d.ts +4 -0
  735. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ro.js +122 -0
  736. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ru.cjs +195 -0
  737. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ru.d.cts +5 -0
  738. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ru.d.ts +4 -0
  739. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ru.js +168 -0
  740. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sk.cjs +143 -0
  741. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sk.d.cts +5 -0
  742. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sk.d.ts +4 -0
  743. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sk.js +116 -0
  744. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sl.cjs +141 -0
  745. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sl.d.cts +5 -0
  746. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sl.d.ts +4 -0
  747. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sl.js +114 -0
  748. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sv.cjs +142 -0
  749. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sv.d.cts +5 -0
  750. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sv.d.ts +4 -0
  751. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/sv.js +115 -0
  752. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ta.cjs +142 -0
  753. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ta.d.cts +5 -0
  754. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ta.d.ts +4 -0
  755. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ta.js +115 -0
  756. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tg.cjs +144 -0
  757. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tg.d.cts +5 -0
  758. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tg.d.ts +4 -0
  759. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tg.js +117 -0
  760. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/th.cjs +142 -0
  761. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/th.d.cts +5 -0
  762. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/th.d.ts +4 -0
  763. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/th.js +115 -0
  764. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tk.cjs +134 -0
  765. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tk.d.cts +5 -0
  766. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tk.d.ts +4 -0
  767. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tk.js +107 -0
  768. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tr.cjs +137 -0
  769. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tr.d.cts +5 -0
  770. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tr.d.ts +4 -0
  771. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/tr.js +110 -0
  772. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ua.cjs +12 -0
  773. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ua.d.cts +5 -0
  774. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ua.d.ts +5 -0
  775. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ua.js +5 -0
  776. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uk.cjs +140 -0
  777. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uk.d.cts +5 -0
  778. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uk.d.ts +4 -0
  779. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uk.js +113 -0
  780. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ur.cjs +142 -0
  781. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ur.d.cts +5 -0
  782. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ur.d.ts +4 -0
  783. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/ur.js +115 -0
  784. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uz.cjs +140 -0
  785. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uz.d.cts +5 -0
  786. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uz.d.ts +4 -0
  787. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/uz.js +113 -0
  788. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/vi.cjs +140 -0
  789. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/vi.d.cts +5 -0
  790. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/vi.d.ts +4 -0
  791. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/vi.js +113 -0
  792. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/yo.cjs +139 -0
  793. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/yo.d.cts +5 -0
  794. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/yo.d.ts +4 -0
  795. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/yo.js +112 -0
  796. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-CN.cjs +141 -0
  797. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-CN.d.cts +5 -0
  798. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-CN.d.ts +4 -0
  799. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-CN.js +114 -0
  800. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-TW.cjs +139 -0
  801. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-TW.d.cts +5 -0
  802. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-TW.d.ts +4 -0
  803. package/skills/poteto-mode/scripts/node_modules/zod/v4/locales/zh-TW.js +112 -0
  804. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/checks.cjs +54 -0
  805. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/checks.d.cts +1 -0
  806. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/checks.d.ts +1 -0
  807. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/checks.js +1 -0
  808. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/coerce.cjs +71 -0
  809. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/coerce.d.cts +7 -0
  810. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/coerce.d.ts +7 -0
  811. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/coerce.js +22 -0
  812. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/deep-partial.cjs +58 -0
  813. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/deep-partial.d.cts +14 -0
  814. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/deep-partial.d.ts +14 -0
  815. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/deep-partial.js +13 -0
  816. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/external.cjs +95 -0
  817. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/external.d.cts +16 -0
  818. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/external.d.ts +16 -0
  819. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/external.js +16 -0
  820. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/in-out.cjs +82 -0
  821. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/in-out.d.cts +8 -0
  822. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/in-out.d.ts +8 -0
  823. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/in-out.js +36 -0
  824. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/index.cjs +51 -0
  825. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/index.d.cts +3 -0
  826. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/index.d.ts +3 -0
  827. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/index.js +3 -0
  828. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/iso.cjs +83 -0
  829. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/iso.d.cts +22 -0
  830. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/iso.d.ts +22 -0
  831. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/iso.js +34 -0
  832. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/package.json +7 -0
  833. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/parse.cjs +37 -0
  834. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/parse.d.cts +1 -0
  835. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/parse.d.ts +1 -0
  836. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/parse.js +1 -0
  837. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/schemas.cjs +1147 -0
  838. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/schemas.d.cts +480 -0
  839. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/schemas.d.ts +480 -0
  840. package/skills/poteto-mode/scripts/node_modules/zod/v4/mini/schemas.js +1002 -0
  841. package/skills/poteto-mode/scripts/node_modules/zod/v4/package.json +7 -0
  842. package/skills/poteto-mode/scripts/node_modules/zod/v4-mini/index.cjs +51 -0
  843. package/skills/poteto-mode/scripts/node_modules/zod/v4-mini/index.d.cts +3 -0
  844. package/skills/poteto-mode/scripts/node_modules/zod/v4-mini/index.d.ts +3 -0
  845. package/skills/poteto-mode/scripts/node_modules/zod/v4-mini/index.js +3 -0
  846. package/skills/poteto-mode/scripts/node_modules/zod/v4-mini/package.json +7 -0
  847. package/skills/poteto-mode/scripts/package.json +2 -1
  848. package/skills/poteto-mode/scripts/watch-pr/classify.ts +144 -0
  849. package/skills/poteto-mode/scripts/watch-pr/cli.test.ts +68 -41
  850. package/skills/poteto-mode/scripts/watch-pr/cli.ts +95 -48
  851. package/skills/poteto-mode/scripts/watch-pr/fakes.test-helper.ts +26 -19
  852. package/skills/poteto-mode/scripts/watch-pr/github-checks.ts +91 -0
  853. package/skills/poteto-mode/scripts/watch-pr/github-json.ts +92 -0
  854. package/skills/poteto-mode/scripts/watch-pr/github-pr.ts +125 -0
  855. package/skills/poteto-mode/scripts/watch-pr/github-queries.ts +26 -0
  856. package/skills/poteto-mode/scripts/watch-pr/github-review.ts +112 -0
  857. package/skills/poteto-mode/scripts/watch-pr/github-stack.ts +67 -0
  858. package/skills/poteto-mode/scripts/watch-pr/github.test.ts +125 -104
  859. package/skills/poteto-mode/scripts/watch-pr/github.ts +158 -564
  860. package/skills/poteto-mode/scripts/watch-pr/policy.test.ts +210 -161
  861. package/skills/poteto-mode/scripts/watch-pr/policy.ts +23 -842
  862. package/skills/poteto-mode/scripts/watch-pr/poll.ts +121 -0
  863. package/skills/poteto-mode/scripts/watch-pr/queue.ts +190 -0
  864. package/skills/poteto-mode/scripts/watch-pr/recorder.test-helper.ts +16 -0
  865. package/skills/poteto-mode/scripts/watch-pr/render.ts +91 -63
  866. package/skills/poteto-mode/scripts/watch-pr/run-queued.ts +187 -0
  867. package/skills/poteto-mode/scripts/watch-pr/run-simple.ts +135 -0
  868. package/skills/poteto-mode/scripts/watch-pr/snapshot.ts +139 -0
  869. package/skills/poteto-mode/scripts/watch-pr/types.compile.ts +2 -1
  870. package/skills/poteto-mode/scripts/watch-pr/types.ts +27 -21
  871. package/skills/poteto-mode/scripts/watch-pr/verdict.ts +88 -0
  872. package/skills/pr-review-canvas/SKILL.md +1 -1
  873. package/skills/pr-review-canvas/renderer.js +169 -119
  874. package/skills/pr-review-canvas/template.html +1 -1
  875. package/skills/statechart/scripts/backends/cfg.ts +2 -6
  876. package/skills/statechart/scripts/backends/mermaid-escape.ts +91 -0
  877. package/skills/statechart/scripts/backends/mermaid.ts +190 -223
  878. package/skills/statechart/scripts/backends/report-notes.ts +137 -0
  879. package/skills/statechart/scripts/backends/report.ts +93 -146
  880. package/skills/statechart/scripts/frontends/config.ts +82 -260
  881. package/skills/statechart/scripts/frontends/configLex.ts +142 -0
  882. package/skills/statechart/scripts/frontends/configReader.ts +116 -0
  883. package/skills/statechart/scripts/frontends/configSections.ts +53 -0
  884. package/skills/statechart/scripts/frontends/dot.ts +44 -38
  885. package/skills/statechart/scripts/frontends/marks.ts +63 -52
  886. package/skills/statechart/scripts/frontends/messages.ts +69 -16
  887. package/skills/statechart/scripts/frontends/spec.ts +66 -49
  888. package/skills/statechart/scripts/frontends/trace.ts +33 -18
  889. package/skills/statechart/scripts/frontends/value.ts +180 -103
  890. package/skills/statechart/scripts/frontends/view.ts +81 -71
  891. package/skills/statechart/scripts/host-env.ts +8 -0
  892. package/skills/statechart/scripts/ir.ts +159 -226
  893. package/skills/statechart/scripts/passes/annotate.ts +106 -70
  894. package/skills/statechart/scripts/passes/label.ts +128 -150
  895. package/skills/statechart/scripts/passes/lift.ts +54 -67
  896. package/skills/statechart/scripts/passes/loop-check.ts +33 -40
  897. package/skills/statechart/scripts/passes/paths.ts +82 -45
  898. package/skills/statechart/scripts/passes/reach.ts +121 -106
  899. package/skills/statechart/scripts/passes/region-check.ts +71 -69
  900. package/skills/statechart/scripts/passes/regions.ts +355 -251
  901. package/skills/statechart/scripts/pipeline.ts +18 -13
  902. package/skills/statechart/scripts/run-io.ts +159 -0
  903. package/skills/statechart/scripts/run-judge.ts +131 -0
  904. package/skills/statechart/scripts/run-tlc.ts +133 -0
  905. package/skills/statechart/scripts/run.ts +209 -442
  906. package/skills/statechart/scripts/statechart.ts +150 -121
  907. package/skills/statechart/scripts/test/attempt.ts +11 -0
  908. package/skills/statechart/scripts/test/chart-labels.test.ts +262 -0
  909. package/skills/statechart/scripts/test/chart-loops.test.ts +109 -0
  910. package/skills/statechart/scripts/test/chart-marks.test.ts +136 -0
  911. package/skills/statechart/scripts/test/chart-paths.test.ts +166 -0
  912. package/skills/statechart/scripts/test/chart-support.ts +92 -0
  913. package/skills/statechart/scripts/test/chart-truth.test.ts +277 -0
  914. package/skills/statechart/scripts/test/chart-values.test.ts +98 -0
  915. package/skills/statechart/scripts/test/chart-view.test.ts +191 -0
  916. package/skills/statechart/scripts/test/check-child.ts +8 -0
  917. package/skills/statechart/scripts/test/cli-config.test.ts +142 -0
  918. package/skills/statechart/scripts/test/cli-corpus.test.ts +160 -0
  919. package/skills/statechart/scripts/test/cli-out.test.ts +108 -0
  920. package/skills/statechart/scripts/test/cli-process-support.ts +129 -0
  921. package/skills/statechart/scripts/test/cli-report.test.ts +223 -0
  922. package/skills/statechart/scripts/test/cli-signals.test.ts +198 -0
  923. package/skills/statechart/scripts/test/cli-support.ts +88 -0
  924. package/skills/statechart/scripts/test/cli-view-labels.test.ts +208 -0
  925. package/skills/statechart/scripts/test/cli-view.test.ts +177 -0
  926. package/skills/statechart/scripts/test/config-fuzz.test.ts +191 -116
  927. package/skills/statechart/scripts/test/corpus.test.ts +92 -95
  928. package/skills/statechart/scripts/test/differential.test.ts +202 -145
  929. package/skills/statechart/scripts/test/drawn.ts +37 -16
  930. package/skills/statechart/scripts/test/exit-status.ts +8 -0
  931. package/skills/statechart/scripts/test/host-env.ts +21 -0
  932. package/skills/statechart/scripts/test/java.ts +9 -6
  933. package/skills/statechart/scripts/test/labels-oracle.ts +357 -0
  934. package/skills/statechart/scripts/test/labels.ts +120 -349
  935. package/skills/statechart/scripts/test/messages.test.ts +148 -118
  936. package/skills/statechart/scripts/test/pipeline.test.ts +52 -45
  937. package/skills/statechart/scripts/test/plain-tlc.test.ts +40 -38
  938. package/skills/statechart/scripts/test/render.test.ts +94 -69
  939. package/skills/statechart/scripts/test/tail-text.test.ts +18 -0
  940. package/skills/statechart/scripts/test/tla-text.ts +2 -0
  941. package/skills/statechart/scripts/test/tlc-out.test.ts +62 -58
  942. package/skills/statechart/scripts/test/tlc.ts +90 -70
  943. package/skills/statechart/scripts/worker.ts +3 -1
  944. package/src/credentials.ts +49 -34
  945. package/src/git.ts +94 -0
  946. package/src/host-env.ts +6 -0
  947. package/src/index.ts +299 -578
  948. package/src/jobs.ts +105 -62
  949. package/src/object-schema.ts +8 -0
  950. package/src/paths.ts +16 -0
  951. package/src/requests.ts +182 -0
  952. package/src/sandbox.ts +137 -96
  953. package/src/subagent/README.md +180 -0
  954. package/src/subagent/agent-resolution.ts +31 -0
  955. package/{agents → src/subagent/agents}/ci-watcher.md +3 -1
  956. package/{agents → src/subagent/agents}/comment-sicko.md +2 -1
  957. package/src/subagent/agents/poteto-agent.md +10 -0
  958. package/src/subagent/agents/scout.md +49 -0
  959. package/src/subagent/agents/thermo-nuclear-code-quality-review.md +24 -0
  960. package/src/subagent/agents.ts +138 -0
  961. package/src/subagent/concurrency.ts +21 -0
  962. package/src/subagent/dispatch-chain.ts +39 -0
  963. package/src/subagent/dispatch-parallel.ts +51 -0
  964. package/src/subagent/dispatch.ts +59 -0
  965. package/src/subagent/format-tool-call.ts +60 -0
  966. package/src/subagent/format.ts +29 -0
  967. package/src/subagent/index.ts +52 -0
  968. package/src/subagent/pi-invocation.ts +43 -0
  969. package/src/subagent/render-call.ts +35 -0
  970. package/src/subagent/render-result.ts +109 -0
  971. package/src/subagent/render-shared.ts +87 -0
  972. package/src/subagent/result-stream.ts +105 -0
  973. package/src/subagent/results.ts +118 -0
  974. package/src/subagent/run-in-tmux.ts +165 -0
  975. package/src/subagent/run-single.ts +107 -0
  976. package/src/subagent/schema.ts +58 -0
  977. package/src/subagent/types.ts +62 -0
  978. package/src/sweep.ts +107 -67
  979. package/src/transcript.ts +61 -51
  980. package/agents/poteto-agent.md +0 -8
  981. package/agents/thermo-nuclear-code-quality-review.md +0 -23
  982. package/skills/statechart/scripts/test/chart.test.ts +0 -1253
  983. package/skills/statechart/scripts/test/cli.test.ts +0 -1315
@@ -1,1315 +0,0 @@
1
- import assert from "node:assert/strict";
2
- import { spawn, spawnSync } from "node:child_process";
3
- import { once } from "node:events";
4
- import fs from "node:fs";
5
- import os from "node:os";
6
- import path from "node:path";
7
- import { test } from "node:test";
8
- import { setTimeout as sleep } from "node:timers/promises";
9
- import { fileURLToPath, pathToFileURL } from "node:url";
10
- import { plainText } from "../backends/plain-text.ts";
11
- import { readMessages } from "../frontends/messages.ts";
12
- import { drawn } from "./drawn.ts";
13
-
14
- const here = path.dirname(fileURLToPath(import.meta.url));
15
- const corpus = path.join(here, "corpus");
16
- const read = (file: string) => fs.readFileSync(file, "utf8");
17
-
18
- function run(
19
- dir: string,
20
- {
21
- args = [],
22
- view = path.join(dir, "view.mjs"),
23
- java = path.join(here, "java.ts"),
24
- command = [process.execPath, path.join(here, "../statechart.ts")],
25
- env = {},
26
- }: {
27
- args?: string[];
28
- view?: string;
29
- java?: string;
30
- command?: string[];
31
- env?: NodeJS.ProcessEnv;
32
- } = {},
33
- ) {
34
- const tmp = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-cli-"));
35
- const out = path.join(tmp, "out");
36
- const log = path.join(tmp, "configs.log");
37
- const name = path.basename(dir);
38
- const [file, ...entry] = command;
39
- const r = spawnSync(
40
- file,
41
- [
42
- ...entry,
43
- path.join(dir, `${name}.tla`),
44
- ...(fs.existsSync(view) ? ["--view", view] : []),
45
- "--out",
46
- out,
47
- ...args,
48
- ],
49
- {
50
- encoding: "utf8",
51
- env: {
52
- ...process.env,
53
- JAVA: java,
54
- TLA2TOOLS: "tla2tools.jar",
55
- STATECHART_REPLAY: dir,
56
- STATECHART_LOG: log,
57
- ...env,
58
- },
59
- },
60
- );
61
- const configs: { [name: string]: string } = {};
62
- if (fs.existsSync(log))
63
- for (const c of read(log).split(/^## /m)) if (c) configs[c.slice(0, c.indexOf("\n"))] = c;
64
- const files = fs.existsSync(out) ? fs.readdirSync(out).sort() : [];
65
- return {
66
- ...r,
67
- out,
68
- files,
69
- configs,
70
- report: files.includes("report.md") ? read(path.join(out, "report.md")) : "",
71
- };
72
- }
73
-
74
- function copyCase(name: string, edit: (dir: string) => void = () => {}) {
75
- const dir = path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-case-")), name);
76
- fs.cpSync(path.join(corpus, name), dir, { recursive: true });
77
- edit(dir);
78
- return dir;
79
- }
80
-
81
- const named = (report: string) => {
82
- const files: string[] = [];
83
- for (const [file] of report.matchAll(/\btlc-\w+\.out\b/g))
84
- if (!files.includes(file)) files.push(file);
85
- return files;
86
- };
87
-
88
- for (const name of fs.readdirSync(corpus)) {
89
- test(`${name} writes the committed chart and report from TLC's output`, () => {
90
- const dir = path.join(corpus, name);
91
- const r = run(dir);
92
- assert.equal(r.stderr, "");
93
- const first = path.join(dir, "verdict-1.exit");
94
- const plain = fs.existsSync(first) ? Number(read(first)) : 0;
95
- assert.equal(r.status, plain === 0 ? 0 : [11, 12, 13].includes(plain) ? 1 : 2);
96
- assert.equal(r.report, read(path.join(dir, "report.md")));
97
- assert.equal(read(path.join(r.out, "chart.mmd")), read(path.join(dir, "chart.mmd")));
98
- assert.deepEqual(r.files, ["chart.mmd", "report.md", "tlc.out", ...named(r.report)].sort());
99
- for (const f of r.files) assert.doesNotMatch(read(path.join(r.out, f)), /@!@!@/, f);
100
- assert.match(r.configs.ChartRun, /^INVARIANT ChartMark$/m);
101
- assert.match(r.configs.ChartRun, /^CONSTRAINT ChartBudget$/m);
102
- });
103
- }
104
-
105
- const launcher = path.join(here, "../statechart");
106
-
107
- const launcherTools = () => {
108
- const bin = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-bin-"));
109
- for (const tool of ["dirname", "readlink", "sed"]) {
110
- const found = spawnSync("sh", ["-c", `command -v ${tool}`], { encoding: "utf8" });
111
- fs.symlinkSync(found.stdout.trim(), path.join(bin, tool));
112
- }
113
- return bin;
114
- };
115
-
116
- const linkedLauncher = () => {
117
- const links = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-links-"));
118
- const [first, second] = [path.join(links, "a"), path.join(links, "b")];
119
- fs.mkdirSync(first);
120
- fs.mkdirSync(second);
121
- fs.symlinkSync(path.relative(second, launcher), path.join(second, "statechart"));
122
- fs.symlinkSync(path.join(second, "statechart"), path.join(first, "statechart"));
123
- return path.join(first, "statechart");
124
- };
125
-
126
- for (const [how, command] of [
127
- ["by its own path", () => launcher],
128
- ["through an absolute and a relative symlink", linkedLauncher],
129
- ] satisfies [string, () => string][]) {
130
- test(`the launcher reached ${how} writes the committed chart on this Node`, () => {
131
- const dir = path.join(corpus, "MediaPlayer");
132
- const r = run(dir, {
133
- command: [command()],
134
- env: { PATH: `${path.dirname(process.execPath)}${path.delimiter}${launcherTools()}` },
135
- });
136
- assert.equal(r.stderr, "");
137
- assert.equal(r.status, 1);
138
- assert.equal(read(path.join(r.out, "chart.mmd")), read(path.join(dir, "chart.mmd")));
139
- });
140
- }
141
-
142
- const unsetNode = () => {
143
- const bin = launcherTools();
144
- fs.writeFileSync(
145
- path.join(bin, "node"),
146
- '#!/bin/sh\necho "No version is set for node." >&2\nexit 1\n',
147
- { mode: 0o755 },
148
- );
149
- return bin;
150
- };
151
-
152
- const fakeBun = (version: string) => () => {
153
- const bin = launcherTools();
154
- fs.writeFileSync(
155
- path.join(bin, "bun"),
156
- `#!/bin/sh\n[ "$1" = --version ] && echo ${version} && exit\necho "$1"\n`,
157
- { mode: 0o755 },
158
- );
159
- return bin;
160
- };
161
-
162
- test("the launcher runs statechart.ts on Bun 1.1.5 when PATH has no Node", () => {
163
- const r = run(path.join(corpus, "Login"), {
164
- command: [launcher],
165
- env: { PATH: fakeBun("1.1.5")() },
166
- });
167
- assert.equal(r.stderr, "");
168
- assert.equal(r.status, 0);
169
- assert.equal(r.stdout, `${path.join(here, "../statechart.ts")}\n`);
170
- });
171
-
172
- for (const [what, bin] of [
173
- ["has none", launcherTools],
174
- ["has only a node that fails --version", unsetNode],
175
- ["has only Bun 1.1.4", fakeBun("1.1.4")],
176
- ] satisfies [string, () => string][]) {
177
- test(`the launcher stops with exit 127 and names only the runtimes when PATH ${what}`, () => {
178
- const r = run(path.join(corpus, "Login"), { command: [launcher], env: { PATH: bin() } });
179
- assert.equal(r.status, 127);
180
- assert.equal(
181
- r.stderr,
182
- "statechart needs Node 22.18 to 22.x, Node 23.6 or later, Bun 1.1.5 or later, or Deno 2.0 or later.\n",
183
- );
184
- assert.deepEqual(r.files, []);
185
- });
186
- }
187
-
188
- test("the order of TLC's dump and its state IDs do not change the chart or the report", () => {
189
- let seed = 7;
190
- const random = () => (seed = (seed * 48271) % 2147483647) / 2147483647;
191
- for (const name of ["DieHard", "LoginParallel", "TwoPhase"]) {
192
- const dir = copyCase(name, (d) => {
193
- const file = path.join(d, "graph.dot");
194
- const ids = new Map<string, string>();
195
- const id = (n: string) => ids.get(n) ?? ids.set(n, String(9000 - ids.size * 17)).get(n);
196
- const lines: string[] = [];
197
- for (const l of read(file).split("\n"))
198
- if (/^-?\d+ (\[|->)/.test(l))
199
- lines.push(
200
- l.replace(
201
- /^(-?\d+)(?: -> (-?\d+))?/,
202
- (_: string, a: string, b: string | undefined) => id(a) + (b ? ` -> ${id(b)}` : ""),
203
- ),
204
- );
205
- for (let i = lines.length - 1; i > 0; i--) {
206
- const j = Math.floor(random() * (i + 1));
207
- [lines[i], lines[j]] = [lines[j], lines[i]];
208
- }
209
- fs.writeFileSync(file, ["strict digraph DiskGraph {", ...lines, "}"].join("\n"));
210
- });
211
- const r = run(dir);
212
- assert.equal(r.report, read(path.join(corpus, name, "report.md")), name);
213
- assert.equal(
214
- read(path.join(r.out, "chart.mmd")),
215
- read(path.join(corpus, name, "chart.mmd")),
216
- name,
217
- );
218
- }
219
- });
220
-
221
- function startCommand(
222
- dir: string,
223
- parent: string,
224
- {
225
- java = path.join(here, "java.ts"),
226
- tmpdir = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-tmpdir-")),
227
- }: { java?: string; tmpdir?: string } = {},
228
- ) {
229
- const name = path.basename(dir);
230
- const view = path.join(dir, "view.mjs");
231
- return spawn(
232
- process.execPath,
233
- [
234
- path.join(here, "../statechart.ts"),
235
- path.join(dir, `${name}.tla`),
236
- ...(fs.existsSync(view) ? ["--view", view] : []),
237
- "--out",
238
- path.join(parent, "out"),
239
- ],
240
- {
241
- env: {
242
- ...process.env,
243
- JAVA: java,
244
- TLA2TOOLS: "tla2tools.jar",
245
- STATECHART_REPLAY: dir,
246
- TMPDIR: tmpdir,
247
- },
248
- stdio: ["ignore", "pipe", "pipe"],
249
- },
250
- );
251
- }
252
-
253
- async function signalWhile<T extends { dir: string; reached: (parent: string) => boolean }>(
254
- signal: NodeJS.Signals,
255
- setup: (fakes: string) => T & { java?: string },
256
- ) {
257
- const fakes = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-fakes-"));
258
- const parent = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-parent-"));
259
- const tmpdir = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-tmpdir-"));
260
- const phase = setup(fakes);
261
- const child = startCommand(phase.dir, parent, { java: phase.java, tmpdir });
262
- let stderr = "";
263
- child.stderr.on("data", (chunk: Buffer) => (stderr += chunk));
264
- const closed = once(child, "close");
265
- const end = Date.now() + 60_000;
266
- while (!phase.reached(parent))
267
- assert.ok(Date.now() < end, "The command did not reach the phase.");
268
- child.kill(signal);
269
- const [status] = await closed;
270
- assert.equal(stderr, `${signal} stopped the check, so the command wrote nothing.\n`);
271
- assert.equal(status, 128 + os.constants.signals[signal]);
272
- assert.deepEqual(fs.readdirSync(parent), []);
273
- assert.deepEqual(fs.readdirSync(tmpdir), []);
274
- return phase;
275
- }
276
-
277
- async function assertGone(pid: number) {
278
- for (let i = 0; ; i++) {
279
- let code: string | undefined;
280
- try {
281
- process.kill(pid, 0);
282
- } catch (error) {
283
- code = (error as NodeJS.ErrnoException).code;
284
- // macOS gives EPERM for a process group of only zombies, until they are reaped.
285
- if (code !== "EPERM") {
286
- assert.equal(code, "ESRCH");
287
- return;
288
- }
289
- }
290
- assert.ok(
291
- i < 250,
292
- `Process ${pid} ${code ? "exited, but it was not reaped" : "is still running"}.`,
293
- );
294
- await sleep(20);
295
- }
296
- }
297
-
298
- async function assertEmpty(dir: string) {
299
- for (let i = 0; i < 250 && fs.readdirSync(dir).length; i++) await sleep(20);
300
- assert.deepEqual(fs.readdirSync(dir), []);
301
- }
302
-
303
- function gridCase(n: number) {
304
- const dir = path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-case-")), "Grid");
305
- fs.cpSync(path.join(here, "grid"), dir, { recursive: true });
306
- for (const run of ["ChartRun.out", "verdict-1.out"])
307
- fs.copyFileSync(path.join(corpus, "Login", run), path.join(dir, run));
308
- const id = (x: number, y: number) => String(1_000_000 + x * n + y);
309
- const lines = ["strict digraph DiskGraph {"];
310
- for (let x = 0; x < n; x++)
311
- for (let y = 0; y < n; y++) {
312
- lines.push(
313
- `${id(x, y)} [label="/\\\\ x = ${x}\\n/\\\\ y = ${y}"${x + y ? "" : ",style = filled"}]`,
314
- );
315
- if (x + 1 < n) lines.push(`${id(x, y)} -> ${id(x + 1, y)} [label="IncX"];`);
316
- if (y + 1 < n) lines.push(`${id(x, y)} -> ${id(x, y + 1)} [label="IncY"];`);
317
- }
318
- lines.push("}");
319
- fs.writeFileSync(path.join(dir, "graph.dot"), lines.join("\n"));
320
- return dir;
321
- }
322
-
323
- function sleepyJava(fakes: string) {
324
- const java = path.join(fakes, "java.mjs");
325
- const pidFile = path.join(fakes, "java.pid");
326
- fs.writeFileSync(
327
- java,
328
- `#!/usr/bin/env node\nimport fs from "node:fs";\n` +
329
- `process.on("SIGTERM", () => {});\n` +
330
- `fs.writeFileSync(${JSON.stringify(pidFile)}, String(process.pid));\n` +
331
- `setTimeout(() => {}, 60_000);\n`,
332
- { mode: 0o755 },
333
- );
334
- return { java, pidFile };
335
- }
336
-
337
- test(
338
- "a SIGKILL of the command stops TLC, removes the temporary folder, and writes nothing",
339
- { timeout: 30_000 },
340
- async () => {
341
- const fakes = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-fakes-"));
342
- const parent = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-parent-"));
343
- const tmpdir = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-tmpdir-"));
344
- const { java, pidFile } = sleepyJava(fakes);
345
- const child = startCommand(path.join(corpus, "DieHard"), parent, { java, tmpdir });
346
- const exited = once(child, "exit");
347
- while (!fs.existsSync(pidFile)) await sleep(20);
348
- child.kill("SIGKILL");
349
- await exited;
350
- await assertGone(Number(read(pidFile)));
351
- await assertEmpty(parent);
352
- await assertEmpty(tmpdir);
353
- },
354
- );
355
-
356
- test(
357
- "a SIGKILL of the command while the view draws the chart leaves no folder behind",
358
- { timeout: 30_000 },
359
- async () => {
360
- const fakes = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-fakes-"));
361
- const parent = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-parent-"));
362
- const tmpdir = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-tmpdir-"));
363
- const drawing = path.join(fakes, "drawing");
364
- const release = path.join(fakes, "release");
365
- const dir = copyCase("Login", (d) =>
366
- fs.writeFileSync(
367
- path.join(d, "view.mjs"),
368
- `import fs from "node:fs";\n` +
369
- `export const state = (v) => {\n` +
370
- ` if (!fs.existsSync(${JSON.stringify(drawing)})) {\n` +
371
- ` fs.writeFileSync(${JSON.stringify(drawing)}, String(process.pid));\n` +
372
- ` for (const end = Date.now() + 20_000; Date.now() < end && !fs.existsSync(${JSON.stringify(release)}); );\n` +
373
- ` }\n` +
374
- ` return JSON.stringify(v);\n` +
375
- `};\n`,
376
- ),
377
- );
378
- const child = startCommand(dir, parent, { tmpdir });
379
- const exited = once(child, "exit");
380
- while (!fs.existsSync(drawing) || !read(drawing)) await sleep(20);
381
- child.kill("SIGKILL");
382
- await exited;
383
- fs.writeFileSync(release, "");
384
- await assertGone(-Number(read(drawing)));
385
- await assertEmpty(parent);
386
- await assertEmpty(tmpdir);
387
- },
388
- );
389
-
390
- test(
391
- "a check killed by a signal stops the command with exit 2, and it writes nothing",
392
- { timeout: 30_000 },
393
- async () => {
394
- const fakes = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-fakes-"));
395
- const parent = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-parent-"));
396
- const { java, pidFile } = sleepyJava(fakes);
397
- const child = startCommand(path.join(corpus, "DieHard"), parent, { java });
398
- let stderr = "";
399
- child.stderr.on("data", (chunk: Buffer) => (stderr += chunk));
400
- const closed = once(child, "close");
401
- while (!fs.existsSync(pidFile) || !read(pidFile)) await sleep(20);
402
- const ps = spawnSync("ps", ["-o", "ppid=", "-p", read(pidFile)], { encoding: "utf8" });
403
- process.kill(Number(ps.stdout), "SIGKILL");
404
- const [status] = await closed;
405
- assert.equal(stderr, "SIGKILL killed the check, so the command wrote nothing.\n");
406
- assert.equal(status, 2);
407
- assert.deepEqual(fs.readdirSync(parent), []);
408
- },
409
- );
410
-
411
- for (const signal of ["SIGINT", "SIGTERM"] satisfies NodeJS.Signals[]) {
412
- test(
413
- `${signal} stops TLC, removes the temporary folder, and writes nothing`,
414
- { timeout: 30_000 },
415
- async () => {
416
- const { pidFile } = await signalWhile(signal, (fakes) => {
417
- const fake = sleepyJava(fakes);
418
- return {
419
- dir: path.join(corpus, "DieHard"),
420
- ...fake,
421
- reached: () => fs.existsSync(fake.pidFile),
422
- };
423
- });
424
- await assertGone(Number(read(pidFile)));
425
- },
426
- );
427
-
428
- test(
429
- `${signal} while the view draws the chart stops the command, and it writes nothing`,
430
- { timeout: 60_000 },
431
- () =>
432
- signalWhile(signal, (fakes) => {
433
- const drawing = path.join(fakes, "drawing");
434
- const dir = copyCase("Login", (d) =>
435
- fs.writeFileSync(
436
- path.join(d, "view.mjs"),
437
- `import fs from "node:fs";\n` +
438
- `export const state = (v) => {\n` +
439
- ` if (!fs.existsSync(${JSON.stringify(drawing)})) {\n` +
440
- ` fs.writeFileSync(${JSON.stringify(drawing)}, "");\n` +
441
- ` for (const end = Date.now() + 30_000; Date.now() < end; );\n` +
442
- ` }\n` +
443
- ` return JSON.stringify(v);\n` +
444
- `};\n`,
445
- ),
446
- );
447
- return { dir, reached: () => fs.existsSync(drawing) };
448
- }),
449
- );
450
-
451
- test(
452
- `${signal} while the command writes its files stops it, and it writes nothing`,
453
- { timeout: 60_000 },
454
- () =>
455
- signalWhile(signal, () => ({
456
- dir: gridCase(150),
457
- reached: (parent) => {
458
- for (const f of fs.readdirSync(parent, { recursive: true, encoding: "utf8" }))
459
- if (
460
- path.basename(f) === "chart.mmd" &&
461
- fs.statSync(path.join(parent, f), { throwIfNoEntry: false })?.size
462
- )
463
- return true;
464
- return false;
465
- },
466
- })),
467
- );
468
- }
469
-
470
- for (const signal of ["SIGINT", "SIGTERM"] satisfies NodeJS.Signals[]) {
471
- test(`${signal} while the command reads TLC's last output stops the check and writes nothing`, () => {
472
- const tmp = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-late-"));
473
- const java = path.join(tmp, "java.mjs");
474
- const tmpdir = path.join(tmp, "tmpdir");
475
- fs.mkdirSync(tmpdir);
476
- const sendWhileRead = `const fs = require("node:fs");
477
- const [dot, pid, signal, graph] = process.argv.slice(1);
478
- setTimeout(() => process.exit(1), 30_000).unref();
479
- fs.open(dot, "w", (error, fd) => {
480
- process.kill(Number(pid), signal);
481
- fs.writeSync(fd, fs.readFileSync(graph));
482
- fs.closeSync(fd);
483
- });`;
484
- fs.writeFileSync(
485
- java,
486
- `#!/usr/bin/env node
487
- import { spawn, spawnSync } from "node:child_process";
488
- const args = process.argv.slice(2);
489
- const dot = args[args.indexOf("-dump") + 2] + ".dot";
490
- spawnSync("mkfifo", [dot]);
491
- const command = spawnSync("ps", ["-o", "ppid=", "-p", String(process.ppid)], { encoding: "utf8" }).stdout.trim();
492
- spawn(process.execPath, ["-e", ${JSON.stringify(sendWhileRead)}, dot, command, ${JSON.stringify(signal)}, ${JSON.stringify(path.join(corpus, "Login", "graph.dot"))}], { detached: true, stdio: "ignore" }).unref();
493
- `,
494
- { mode: 0o755 },
495
- );
496
- const r = run(path.join(corpus, "Login"), { java, env: { TMPDIR: tmpdir } });
497
- assert.equal(r.stderr, `${signal} stopped the check, so the command wrote nothing.\n`);
498
- assert.equal(r.status, 128 + os.constants.signals[signal]);
499
- assert.deepEqual(fs.readdirSync(tmpdir), []);
500
- assert.equal(fs.existsSync(r.out), false);
501
- });
502
- }
503
-
504
- test("a broken property is named in the report, and its TLC trace is in tlc-NAME.out", () => {
505
- const dir = path.join(corpus, "MediaPlayerProps");
506
- const r = run(dir);
507
- assert.equal(r.status, 1);
508
- for (const p of ["EventuallyPlays", "QuietWhenStopped"]) {
509
- assert.match(r.report, new RegExp(`^## ${p} breaks\n.*tlc-${p}\\.out`, "m"));
510
- const out = read(path.join(r.out, `tlc-${p}.out`));
511
- const from: string[] = [];
512
- for (const name of Object.keys(r.configs)) {
513
- const tool = name.startsWith("verdict-") && read(path.join(dir, `${name}.out`));
514
- if (tool && out === `${[...plainText(readMessages(tool))].join("")}\n`) from.push(name);
515
- }
516
- assert.equal(from.length, 1, p);
517
- assert.match(r.configs[from[0]], new RegExp(`^PROPERTY ${p}$`, "m"));
518
- assert.match(out, /^TLC2 Version /);
519
- assert.doesNotMatch(out, /@!@!@/);
520
- }
521
- assert.match(read(path.join(r.out, "tlc-QuietWhenStopped.out")), /^State 2: <YouTurnItUp /m);
522
- assert.match(r.report, /^## Rules that hold\n.*\bEventuallyStops\b.*\bStaysTyped\b/m);
523
- });
524
-
525
- test("TLC checks the rules and draws the chart with VIEW and SYMMETRY, and the report says an arrow can lead to a representative", () => {
526
- const dir = copyCase("MediaPlayer", (d) =>
527
- fs.appendFileSync(path.join(d, "MediaPlayer.cfg"), "\nVIEW vars\nSYMMETRY Perms\n"),
528
- );
529
- const r = run(dir);
530
- assert.equal(r.status, 1);
531
- const verdict = r.configs["verdict-1"];
532
- assert.match(verdict, /^PROPERTY EventuallyStops$/m);
533
- for (const config of [verdict, r.configs.ChartRun]) {
534
- assert.match(config, /^VIEW vars$/m);
535
- assert.match(config, /^SYMMETRY Perms$/m);
536
- }
537
- assert.match(
538
- r.report,
539
- /^With VIEW and SYMMETRY, TLC keeps one representative for each group of states that it counts as the same\. An arrow can lead to the representative rather than to the state that the step reaches\.$/m,
540
- );
541
- assert.doesNotMatch(run(path.join(corpus, "MediaPlayer")).report, /representative/);
542
- });
543
-
544
- const overBudget = (file: string) =>
545
- fs.writeFileSync(file, read(file).replace(/\b\d+( distinct states found)/g, "1234$1"));
546
-
547
- test("a check above the chart budget skips the drawing run and draws only the bug paths", () => {
548
- const dir = copyCase("FirstRule", (d) => {
549
- for (const f of fs.readdirSync(d))
550
- if (/^verdict-\d+\.out$/.test(f)) overBudget(path.join(d, f));
551
- });
552
- const r = run(dir);
553
- assert.equal(r.status, 1);
554
- assert.equal(r.configs.ChartRun, undefined);
555
- assert.ok(r.files.includes("chart.mmd"));
556
- assert.match(
557
- r.report,
558
- /^TLC reached more states than the chart budget of 500, so the chart draws only the bug paths: 4 states and 3 arrows\.$/m,
559
- );
560
- for (const rule of ["NotOne", "NotOneOrThree", "AlsoNotOne", "NoDeadlock"])
561
- assert.match(r.report, new RegExp(`^## ${rule} breaks$`, "m"));
562
- });
563
-
564
- test("a passing check above the chart budget writes no chart.mmd and gives the state count", () => {
565
- const dir = copyCase("Login", (d) => overBudget(path.join(d, "verdict-1.out")));
566
- const r = run(dir);
567
- assert.equal(r.status, 0);
568
- assert.equal(r.configs.ChartRun, undefined);
569
- assert.deepEqual(r.files, ["report.md", "tlc.out"]);
570
- assert.match(
571
- r.report,
572
- /^TLC reached 1,234 states, more than the chart budget of 500, so the command wrote no chart\.mmd\.$/m,
573
- );
574
- assert.match(r.report, /^## Rules that hold\nTypeOK, NoDeadlock$/m);
575
- });
576
-
577
- test("a property that INSTANCE actions break above the chart budget draws their qualified names and the loop", () => {
578
- const dir = copyCase("CounterInstance", (d) => overBudget(path.join(d, "verdict-1.out")));
579
- const r = run(dir);
580
- assert.equal(r.status, 1);
581
- assert.equal(r.configs.ChartRun, undefined);
582
- assert.match(
583
- r.report,
584
- /^1\. C!Up: 1\n2\. C!Up: 2\n3\. C!Back: 1\nThe run loops through "1" and "2" forever\.$/m,
585
- );
586
- assert.match(read(path.join(r.out, "chart.mmd")), /^ s\d+ --> s\d+: C!Back$/m);
587
- });
588
-
589
- test("a drawing run that counts more states than the chart budget gives only the bug paths", () => {
590
- const dir = copyCase("FirstRule", (d) => overBudget(path.join(d, "ChartRun.out")));
591
- const r = run(dir);
592
- assert.equal(r.status, 1);
593
- assert.match(r.configs.ChartRun, /^CONSTRAINT ChartBudget$/m);
594
- assert.match(
595
- r.report,
596
- /^TLC reached more states than the chart budget of 500, so the chart draws only the bug paths: 4 states and 3 arrows\.$/m,
597
- );
598
- });
599
-
600
- test("a property with no temporal operator says TLC checked it only in the initial states", () => {
601
- const r = run(path.join(corpus, "Counter"));
602
- assert.equal(r.status, 0);
603
- assert.match(r.report, /^## Rules that hold\nLow, StaysSmall\n/m);
604
- assert.match(
605
- r.report,
606
- /^TLC checked Low only in the initial states, because it has no \[\], <>, or ~>\. List it as an INVARIANT to check every state\.$/m,
607
- );
608
- assert.doesNotMatch(r.report, /TLC checked StaysSmall/);
609
- });
610
-
611
- test("a property that the config replaces with a state predicate gets the initial-states note", () => {
612
- const dir = copyCase("Counter", (d) =>
613
- fs.writeFileSync(
614
- path.join(d, "Counter.cfg"),
615
- "SPECIFICATION Spec\nCONSTANT StaysSmall <- Low\nPROPERTY StaysSmall\nCHECK_DEADLOCK FALSE\n",
616
- ),
617
- );
618
- const r = run(dir);
619
- assert.equal(r.status, 0);
620
- assert.match(r.report, /^TLC checked StaysSmall only in the initial states, /m);
621
- });
622
-
623
- test("a property that an extended module also defines as LOCAL takes the root definition's level", () => {
624
- const r = run(path.join(corpus, "Shadow"));
625
- assert.equal(r.status, 0);
626
- assert.doesNotMatch(r.report, /TLC checked Shadow/);
627
- assert.match(r.report, /^TLC checked Shade only in the initial states, /m);
628
- assert.match(r.report, /^TLC checked Hold only in the initial states, /m);
629
- });
630
-
631
- test("a property from an extended module gets the initial-states note too", () => {
632
- const dir = copyCase("MediaPlayerProps", (d) => {
633
- fs.appendFileSync(path.join(d, "MediaPlayerProps.cfg"), "\nPROPERTY TypeOK\n");
634
- fs.copyFileSync(path.join(d, "verdict-6.out"), path.join(d, "verdict-7.out"));
635
- });
636
- const r = run(dir);
637
- assert.match(r.report, /^TLC checked TypeOK only in the initial states, /m);
638
- assert.doesNotMatch(r.report, /TLC checked (EventuallyStops|StaysTyped)/);
639
- });
640
-
641
- test("a spec that SANY cannot read stops the command with exit 2", () => {
642
- const dir = copyCase("MediaPlayer", (d) => fs.writeFileSync(path.join(d, "sany.exit"), "150\n"));
643
- const r = run(dir);
644
- assert.equal(r.status, 2);
645
- assert.match(r.stderr, /SANY could not read .*MediaPlayer\.tla \(exit 150\)/);
646
- assert.deepEqual(r.files, []);
647
- });
648
-
649
- test("a first verdict run that TLC cannot finish stops the command with exit 2", () => {
650
- const dir = copyCase("Login", (d) => fs.writeFileSync(path.join(d, "verdict-1.exit"), "150\n"));
651
- const r = run(dir);
652
- assert.equal(r.status, 2);
653
- assert.match(r.stderr, /TLC could not check .*Login\.tla \(exit 150\)/);
654
- assert.deepEqual(r.files, []);
655
- });
656
-
657
- test("a later verdict run that TLC cannot finish keeps the exit and leaves its rules not checked", () => {
658
- const dir = copyCase("CounterJump", (d) =>
659
- fs.writeFileSync(path.join(d, "verdict-2.exit"), "150\n"),
660
- );
661
- const r = run(dir);
662
- assert.equal(r.status, 1);
663
- assert.match(r.report, /^## NotThree breaks$/m);
664
- assert.match(
665
- r.report,
666
- /^## Rules not checked\nNoDeadlock\nTLC stopped with exit 150 before it checked this rule:$/m,
667
- );
668
- });
669
-
670
- test("a drawing run that TLC cannot finish stops the command with exit 2", () => {
671
- const dir = copyCase("Login", (d) => {
672
- fs.rmSync(path.join(d, "graph.dot"));
673
- fs.writeFileSync(path.join(d, "ChartRun.exit"), "150\n");
674
- });
675
- const r = run(dir);
676
- assert.equal(r.status, 2);
677
- assert.match(r.stderr, /TLC could not check .*Login\.tla \(exit 150\)/);
678
- });
679
-
680
- test("a java that cannot start stops the command with exit 2 on a runtime that emits no close for it", () => {
681
- const tmp = fs.mkdtempSync(path.join(os.tmpdir(), "statechart-no-java-"));
682
- const noClose = path.join(tmp, "no-close.mjs");
683
- fs.writeFileSync(
684
- noClose,
685
- `import childProcess from "node:child_process";
686
- import { syncBuiltinESMExports } from "node:module";
687
- const { spawn } = childProcess;
688
- childProcess.spawn = (...args) => {
689
- const child = spawn(...args);
690
- const { emit } = child;
691
- child.emit = (name, ...rest) =>
692
- name === "close" && child.pid === undefined ? false : emit.call(child, name, ...rest);
693
- return child;
694
- };
695
- syncBuiltinESMExports();
696
- `,
697
- );
698
- const java = path.join(tmp, "java");
699
- const spec = path.join(corpus, "Login", "Login.tla");
700
- const r = run(path.dirname(spec), {
701
- java,
702
- command: [
703
- process.execPath,
704
- `--import=${pathToFileURL(noClose).href}`,
705
- path.join(here, "../statechart.ts"),
706
- ],
707
- });
708
- assert.equal(r.stderr, `SANY could not read ${spec} (exit null):\nspawn ${java} ENOENT\n`);
709
- assert.equal(r.status, 2);
710
- assert.equal(fs.existsSync(r.out), false);
711
- });
712
-
713
- test("a step hidden by the view is not drawn, and the report counts it", () => {
714
- const dir = path.join(corpus, "MediaPlayer");
715
- const hidden = new Set(read(path.join(dir, "graph.dot")).match(/^.* -> .*label="ACallComesIn"/gm))
716
- .size;
717
- const view = path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-view-")), "view.mjs");
718
- fs.writeFileSync(
719
- view,
720
- `export * from ${JSON.stringify(path.join(dir, "view.mjs"))};\n` +
721
- `import { step as words } from ${JSON.stringify(path.join(dir, "view.mjs"))};\n` +
722
- `export const step = (action, from, to) => action === "ACallComesIn" ? null : words(action, from, to);\n`,
723
- );
724
- const r = run(dir, { view });
725
- assert.equal(r.status, 1);
726
- assert.match(
727
- r.report,
728
- new RegExp(`^The view hides ${hidden} steps, so the chart does not draw them\\.$`, "m"),
729
- );
730
- assert.doesNotMatch(read(path.join(r.out, "chart.mmd")), /a call comes in/);
731
- assert.match(r.report, /^1\. you turn it up: Playback Stopped, Volume Loud$/m);
732
- });
733
-
734
- test("a view that hides a step of a bug path stops the command with exit 2", () => {
735
- const dir = path.join(corpus, "MediaPlayer");
736
- const view = path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-view-")), "view.mjs");
737
- fs.writeFileSync(
738
- view,
739
- `export * from ${JSON.stringify(path.join(dir, "view.mjs"))};\n` +
740
- `export const step = (action) => (action === "YouTurnItUp" ? null : action);\n`,
741
- );
742
- const r = run(dir, { view });
743
- assert.equal(r.status, 2);
744
- assert.match(r.stderr, /LoudWhenStopped/);
745
- assert.deepEqual(r.files, []);
746
- });
747
-
748
- for (const [what, body, words] of [
749
- ["state() returns a number", "export const state = (v) => 7;", /state\(\) returned 7/],
750
- ["state() reads a missing variable", "export const state = (v) => `${v.nope}`;", /undefined/],
751
- ["step() returns an empty label", 'export const step = () => "";', /step\(\) returned ""/],
752
- [
753
- "group() names no color",
754
- 'export const group = () => "Busy";\nexport const colors = {};',
755
- /group\(\) returned "Busy"/,
756
- ],
757
- ] satisfies [string, string, RegExp][]) {
758
- test(`a view whose ${what} stops the command with exit 2`, () => {
759
- const view = path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-view-")), "view.mjs");
760
- fs.writeFileSync(view, body);
761
- const r = run(path.join(corpus, "Login"), { view });
762
- assert.equal(r.status, 2);
763
- assert.match(r.stderr, words);
764
- });
765
- }
766
-
767
- const writeView = (body: string) => {
768
- const view = path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-view-")), "view.mjs");
769
- fs.writeFileSync(view, body);
770
- return view;
771
- };
772
-
773
- for (const [what, body, words] of [
774
- [
775
- "gives a group a mark class as its color",
776
- 'export const group = () => "Working";\nexport const colors = { Working: "breaks" };',
777
- /\bWorking\b[\s\S]*"breaks"[\s\S]*\bblue\b[\s\S]*\bpink\b/,
778
- ],
779
- [
780
- "gives a group a color outside the theme",
781
- 'export const group = () => "Lost";\nexport const colors = { Lost: "red" };',
782
- /^The view's colors give "Lost" the color "red"\. Give each group blue, orange, purple, yellow, teal, tan or pink\.\n$/,
783
- ],
784
- [
785
- "exports colors as a Map",
786
- 'export const colors = new Map([["Busy", "blue"]]);',
787
- /^The view's colors must be a plain object\.\n$/,
788
- ],
789
- [
790
- "exports group() but no colors",
791
- 'export const group = () => "Working";',
792
- /\bgroup\b[\s\S]*\bcolors\b/,
793
- ],
794
- [
795
- "misspells an export",
796
- "export const state = (v) => v.main;\nexport const steps = (a) => a;",
797
- /\bsteps\b[\s\S]*\bstep\b/,
798
- ],
799
- ["has a default export", "export default { state: (v) => v.main };", /\bdefault\b/],
800
- ["exports colors as a string", 'export const colors = "blue";', /\bcolors\b[\s\S]*\bobject\b/],
801
- ["exports a number as its title", "export const title = 7;", /\btitle\b[\s\S]*\bstring\b/],
802
- ] satisfies [string, string, RegExp][]) {
803
- test(`a view that ${what} stops the command with exit 2 before TLC runs`, () => {
804
- const r = run(path.join(corpus, "Login"), { view: writeView(body) });
805
- assert.equal(r.status, 2);
806
- assert.match(r.stderr, words);
807
- assert.deepEqual(r.files, []);
808
- assert.deepEqual(r.configs, {});
809
- });
810
- }
811
-
812
- test("a view module that throws null stops the command with exit 2 and no stack trace", () => {
813
- const r = run(path.join(corpus, "Login"), { view: writeView("throw null;\n") });
814
- assert.equal(r.status, 2);
815
- assert.equal(r.stderr, "null\n");
816
- assert.deepEqual(r.files, []);
817
- assert.deepEqual(r.configs, {});
818
- });
819
-
820
- test("a view module that throws an object with no prototype stops the command with exit 2", () => {
821
- const r = run(path.join(corpus, "Login"), {
822
- view: writeView("throw Object.create(null);\n"),
823
- });
824
- assert.equal(r.status, 2);
825
- assert.equal(r.stderr, "[Object: null prototype] {}\n");
826
- assert.deepEqual(r.files, []);
827
- assert.deepEqual(r.configs, {});
828
- });
829
-
830
- test("a view module that throws a plain object with a message prints the message", () => {
831
- const r = run(path.join(corpus, "Login"), {
832
- view: writeView('throw { message: "The view has no states." };\n'),
833
- });
834
- assert.equal(r.status, 2);
835
- assert.equal(r.stderr, "The view has no states.\n");
836
- assert.deepEqual(r.files, []);
837
- assert.deepEqual(r.configs, {});
838
- });
839
-
840
- test("a view that ends the check while TLC runs stops TLC, and the command exits 2 and writes nothing", async () => {
841
- const { java, pidFile } = sleepyJava(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-fakes-")));
842
- const r = run(path.join(corpus, "Login"), {
843
- java,
844
- view: writeView(
845
- 'import fs from "node:fs";\n' +
846
- `setInterval(() => fs.existsSync(${JSON.stringify(pidFile)}) && process.exit(1), 20);\n` +
847
- "export const state = (v) => JSON.stringify(v);\n",
848
- ),
849
- });
850
- assert.equal(r.status, 2);
851
- assert.deepEqual(r.files, []);
852
- await assertGone(Number(read(pidFile)));
853
- });
854
-
855
- test("a group that only a mixed chart state gets still needs a color", () => {
856
- const view = writeView(
857
- 'export const state = (v) => v.main.split(".")[0];\n' +
858
- 'export const group = (v) => v.main.includes("Checking") ? "Checking" : v.main.includes("Wrong") ? "Waiting" : undefined;\n' +
859
- 'export const colors = { Waiting: "blue" };\n',
860
- );
861
- const r = run(path.join(corpus, "Login"), { view });
862
- assert.equal(r.status, 2);
863
- assert.match(r.stderr, /group\(\) returned "Checking"/);
864
- assert.deepEqual(r.files, []);
865
- });
866
-
867
- test("a view with a group in a theme color draws that color and names the group in the Legend", () => {
868
- const view = writeView(
869
- 'export const state = (v) => v.main.split(".");\n' +
870
- 'export const group = (v) => (v.main === "Signed in" ? "Done" : undefined);\n' +
871
- 'export const colors = { Done: "teal" };\n' +
872
- 'export const title = "Login";\n',
873
- );
874
- const r = run(path.join(corpus, "Login"), { view });
875
- assert.equal(r.stderr, "");
876
- assert.equal(r.status, 0);
877
- const chart = read(path.join(r.out, "chart.mmd"));
878
- assert.match(chart, /^title: "Login"$/m);
879
- const id = chart.match(/^ {2}(s\d+): Signed in$/m)?.[1];
880
- assert.match(chart, new RegExp(`^ {2}class ${id} teal$`, "m"));
881
- const legend = chart.match(/^ {4}(lg\d+): Done$/m)?.[1];
882
- assert.match(chart, new RegExp(`^ {2}class ${legend} teal$`, "m"));
883
- });
884
-
885
- const byX = (labels: unknown[]) => `export const state = (v) => ${JSON.stringify(labels)}[v.x];\n`;
886
-
887
- const fanOut = (n: number) => {
888
- const lines = ["strict digraph DiskGraph {", '0 [label="x = 0",style = filled]'];
889
- for (let i = 1; i <= n; i++)
890
- lines.push(
891
- `${i} [label="x = ${i}"];`,
892
- `0 -> ${i} [label="Inc",color="black",fontcolor="black"];`,
893
- );
894
- return [...lines, "}"].join("\n");
895
- };
896
-
897
- test("a flat view names a label with U+0000 as written when a loop cannot take a step out of it", () => {
898
- const view = writeView(
899
- `export const state = (v) => (v.playback === "Stopped" || v.volume === "Muted" ? ${JSON.stringify("a\0b")} : v.playback);\n`,
900
- );
901
- const r = run(path.join(corpus, "MediaPlayerProps"), { view });
902
- assert.equal(r.status, 2);
903
- assert.equal(
904
- r.stderr,
905
- "The chart draws the step TheCallEnds out of a\0b, but the EventuallyPlays loop cannot take it there. Show in a label what stops it.\n",
906
- );
907
- assert.deepEqual(r.files, []);
908
- });
909
-
910
- for (const [what, c] of [
911
- [
912
- "a parent-state view keeps a label with U+0000 apart from the parent path it spells",
913
- {
914
- base: "Counter",
915
- view: byX([["a\0b"], ["a", "b"], ["c"], ["d"]]),
916
- status: 0,
917
- states: ["ab", "a", "b", "c", "d"],
918
- arrows: ["a start --> b", "ab --> a: Inc", "b --> c: Inc", "c --> d: Inc"],
919
- says: /^TLC reached 4 states and 3 steps\. The chart draws 4 states and 3 arrows\.$/m,
920
- },
921
- ],
922
- [
923
- "a regions view keeps a label with U+0000 apart from the parent path it spells, and the report names it as written",
924
- {
925
- base: "Counter",
926
- fanOut: 2,
927
- view: byX([
928
- { R: "f", S: "p" },
929
- { R: ["a\0b"], S: "q" },
930
- { R: ["a", "b"], S: "r" },
931
- ]),
932
- status: 0,
933
- states: ["R f", "S p", "R ab", "S q", "R a", "R b", "S r"],
934
- arrows: [
935
- "R f start --> S p",
936
- "R ab start --> S q",
937
- "R b start --> S r",
938
- "R a start --> R b",
939
- "S p --> R ab: Inc",
940
- "S p --> R a: Inc",
941
- ],
942
- says: /^The regions chart lets R f, S p go to R a\0b, S r by Inc, which the model never does\. So the chart draws parent states in place of regions\.$/m,
943
- },
944
- ],
945
- [
946
- "a flat view with U+0001 in a label draws each arrow between the states it joins",
947
- {
948
- base: "Counter",
949
- view: byX(["a\u0001b", "a", "b", "c"]),
950
- status: 0,
951
- states: ["a\u0001b", "a", "b", "c"],
952
- arrows: ["a\u0001b --> a: Inc", "a --> b: Inc", "b --> c: Inc"],
953
- says: /^TLC reached 4 states and 3 steps\. The chart draws 4 states and 3 arrows\.$/m,
954
- },
955
- ],
956
- [
957
- "a parent-state view with U+0001 in a label draws the chart",
958
- {
959
- base: "Counter",
960
- view: byX([["a\u0001b"], ["a", "b"], ["c"], ["d"]]),
961
- status: 0,
962
- states: ["a\u0001b", "a", "b", "c", "d"],
963
- arrows: ["a start --> b", "a\u0001b --> a: Inc", "b --> c: Inc", "c --> d: Inc"],
964
- says: /^TLC reached 4 states and 3 steps\. The chart draws 4 states and 3 arrows\.$/m,
965
- },
966
- ],
967
- [
968
- "a regions view with U+0001 in a label draws the chart",
969
- {
970
- base: "Counter",
971
- view: byX([
972
- { R: "a\u0001b", S: "p" },
973
- { R: "c", S: "p" },
974
- { R: "d", S: "p" },
975
- { R: "e", S: "p" },
976
- ]),
977
- status: 0,
978
- states: ["a\u0001b", "c", "d", "e", "p"],
979
- arrows: ["a\u0001b --> c: Inc", "c --> d: Inc", "d --> e: Inc"],
980
- says: /^TLC reached 4 states and 3 steps\. The chart draws 5 states and 3 arrows\.$/m,
981
- },
982
- ],
983
- [
984
- "a flat view reports a state with U+0002 in its label that breaks a rule",
985
- {
986
- base: "FirstRule",
987
- view: byX(["a", "b\u0002c", "d", "e"]),
988
- status: 1,
989
- states: ["a", "b\u0002c", "d", "e"],
990
- arrows: ["a --> b\u0002c: Next", "b\u0002c --> d: Next", "d --> e: Next"],
991
- says: /^## NotOne breaks\nThe shortest path has 1 step:\n0\. a\n1\. Next: b\cBc$/m,
992
- },
993
- ],
994
- [
995
- "a parent-state view reports a state with U+0002 in its label that breaks a rule",
996
- {
997
- base: "FirstRule",
998
- view: byX([["a"], ["P", "b\u0002c"], ["d"], ["e"]]),
999
- status: 1,
1000
- states: ["a", "P", "b\u0002c", "d", "e"],
1001
- arrows: ["P start --> b\u0002c", "a --> P: Next", "b\u0002c --> d: Next", "d --> e: Next"],
1002
- says: /^## NotOne breaks\nThe shortest path has 1 step:\n0\. a\n1\. Next: P \/ b\cBc$/m,
1003
- },
1004
- ],
1005
- [
1006
- "a regions view reports a state with U+0002 in its label that breaks a rule",
1007
- {
1008
- base: "FirstRule",
1009
- view: byX([
1010
- { R: "a", S: "p" },
1011
- { R: "b\u0002c", S: "p" },
1012
- { R: "d", S: "p" },
1013
- { R: "e", S: "p" },
1014
- ]),
1015
- status: 1,
1016
- states: ["a", "b\u0002c", "d", "e", "p"],
1017
- arrows: ["a --> b\u0002c: Next", "b\u0002c --> d: Next", "d --> e: Next"],
1018
- says: /^## NotOne breaks\nThe shortest path has 1 step:\n0\. R a, S p\n1\. Next: R b\cBc, S p$/m,
1019
- },
1020
- ],
1021
- [
1022
- "a regions view with U+0003 in labels draws parent states when the regions chart would invent a move",
1023
- {
1024
- base: "Counter",
1025
- fanOut: 4,
1026
- view:
1027
- byX([
1028
- { R: "f", S: "p" },
1029
- { R: "a", S: "r" },
1030
- { R: "b", S: "q" },
1031
- { R: "X\u0003a", S: "q" },
1032
- { R: "X\u0003b", S: "r" },
1033
- ]) +
1034
- `export const step = (action, from, to) => (to.x <= 2 ? ${JSON.stringify("Go\u0003X")} : "Go");\n`,
1035
- status: 0,
1036
- states: ["R f", "S p", "R a", "S r", "R b", "S q", "R X\u0003a", "S q", "R X\u0003b", "S r"],
1037
- arrows: [
1038
- "R f start --> S p",
1039
- "R a start --> S r",
1040
- "R b start --> S q",
1041
- "R X\u0003a start --> S q",
1042
- "R X\u0003b start --> S r",
1043
- "S p --> R a: Go\u0003X",
1044
- "S p --> R b: Go\u0003X",
1045
- "S p --> R X\u0003a: Go",
1046
- "S p --> R X\u0003b: Go",
1047
- ],
1048
- says: /^The regions chart lets R f, S p go to R a, S q by Go\cCX, which the model never does\. So the chart draws parent states in place of regions\.$/m,
1049
- },
1050
- ],
1051
- ] satisfies [
1052
- string,
1053
- {
1054
- base: string;
1055
- fanOut?: number;
1056
- view: string;
1057
- status: number;
1058
- states: string[];
1059
- arrows: string[];
1060
- says: RegExp;
1061
- },
1062
- ][]) {
1063
- test(what, () => {
1064
- const width = c.fanOut;
1065
- const dir = width
1066
- ? copyCase(c.base, (d) => fs.writeFileSync(path.join(d, "graph.dot"), fanOut(width)))
1067
- : path.join(corpus, c.base);
1068
- const r = run(dir, { view: writeView(c.view) });
1069
- assert.equal(r.stderr, "");
1070
- assert.equal(r.status, c.status);
1071
- assert.deepEqual(drawn(read(path.join(r.out, "chart.mmd"))), {
1072
- states: c.states,
1073
- arrows: c.arrows,
1074
- });
1075
- assert.match(r.report, c.says);
1076
- });
1077
- }
1078
-
1079
- for (const [what, args, words] of [
1080
- ["an unknown option", ["--bogus"], /Unknown option '--bogus'[\s\S]*Usage:/],
1081
- ["a second spec", ["Other.tla"], /Give one SPEC\.tla\.[\s\S]*Usage:/],
1082
- [
1083
- "a config that does not exist",
1084
- ["--config", "Missing.cfg"],
1085
- /Cannot find the TLC config Missing\.cfg/,
1086
- ],
1087
- ] satisfies [string, string[], RegExp][]) {
1088
- test(`${what} stops the command with exit 2 before TLC runs`, () => {
1089
- const r = run(path.join(corpus, "Login"), { args });
1090
- assert.equal(r.status, 2);
1091
- assert.match(r.stderr, words);
1092
- assert.deepEqual(r.configs, {});
1093
- });
1094
- }
1095
-
1096
- const contents = (p: string) => {
1097
- const stat = fs.lstatSync(p);
1098
- if (stat.isSymbolicLink()) return fs.readlinkSync(p);
1099
- if (!stat.isDirectory()) return read(p);
1100
- const files: { [name: string]: string } = {};
1101
- for (const f of fs.readdirSync(p)) files[f] = read(path.join(p, f));
1102
- return files;
1103
- };
1104
- const newPath = () => path.join(fs.mkdtempSync(path.join(os.tmpdir(), "statechart-out-")), "out");
1105
-
1106
- for (const [what, make, words] of [
1107
- [
1108
- "a folder of the user's files",
1109
- (out) => {
1110
- fs.mkdirSync(out);
1111
- fs.writeFileSync(path.join(out, ".bashrc"), "export PATH\n");
1112
- fs.writeFileSync(path.join(out, "report.md"), "# My quarterly report\n");
1113
- fs.writeFileSync(path.join(out, "tlc-Build.out"), "build log\n");
1114
- },
1115
- /is not empty\. It has \.bashrc\./,
1116
- ],
1117
- [
1118
- "a folder that holds only a dotfile",
1119
- (out) => {
1120
- fs.mkdirSync(out);
1121
- fs.writeFileSync(path.join(out, ".bashrc"), "export PATH\n");
1122
- },
1123
- /is not empty\. It has \.bashrc\./,
1124
- ],
1125
- [
1126
- "the folder of an earlier run",
1127
- (out) =>
1128
- assert.equal(run(path.join(corpus, "MediaPlayerProps"), { args: ["--out", out] }).status, 1),
1129
- /is not empty\. It has chart\.mmd\./,
1130
- ],
1131
- [
1132
- "a file",
1133
- (out) => fs.writeFileSync(out, "keep me\n"),
1134
- /cannot be the output folder\. ENOTDIR: not a directory/,
1135
- ],
1136
- [
1137
- "a broken link",
1138
- (out) => fs.symlinkSync(path.join(path.dirname(out), "gone"), out),
1139
- /cannot be the output folder\. It is a broken link\./,
1140
- ],
1141
- ] satisfies [string, (out: string) => void, RegExp][]) {
1142
- test(`an --out that is ${what} stops the command with exit 2 before TLC runs, and keeps what is there`, () => {
1143
- const out = newPath();
1144
- make(out);
1145
- const before = contents(out);
1146
- const r = run(path.join(corpus, "Login"), { args: ["--out", out] });
1147
- assert.equal(r.status, 2);
1148
- assert.ok(r.stderr.includes(out), r.stderr);
1149
- assert.match(r.stderr, words);
1150
- assert.match(r.stderr, /Pass --out with a new folder\.\n$/);
1151
- assert.deepEqual(r.configs, {});
1152
- assert.deepEqual(contents(out), before);
1153
- });
1154
- }
1155
-
1156
- test("a file that appears in --out while TLC runs is kept, and the command stops with exit 2", () => {
1157
- const out = newPath();
1158
- const mine = path.join(out, "report.md");
1159
- const java = path.join(path.dirname(out), "java.sh");
1160
- fs.writeFileSync(
1161
- java,
1162
- `#!/bin/sh\nmkdir -p ${JSON.stringify(out)}\n` +
1163
- `[ -e ${JSON.stringify(mine)} ] || echo mine > ${JSON.stringify(mine)}\n` +
1164
- `exec ${JSON.stringify(path.join(here, "java.ts"))} "$@"\n`,
1165
- { mode: 0o755 },
1166
- );
1167
- const r = run(path.join(corpus, "Login"), { args: ["--out", out], java });
1168
- assert.equal(r.status, 2);
1169
- assert.ok(r.stderr.includes(mine), r.stderr);
1170
- assert.equal(read(mine), "mine\n");
1171
- });
1172
-
1173
- test("an empty --out folder gets the chart and the report", () => {
1174
- const out = newPath();
1175
- fs.mkdirSync(out);
1176
- const r = run(path.join(corpus, "Login"), { args: ["--out", out] });
1177
- assert.equal(r.stderr, "");
1178
- assert.equal(read(path.join(out, "report.md")), read(path.join(corpus, "Login", "report.md")));
1179
- assert.deepEqual(fs.readdirSync(out).sort(), ["chart.mmd", "report.md", "tlc.out"]);
1180
- });
1181
-
1182
- for (const [what, config, words] of [
1183
- [
1184
- "a misspelled first keyword",
1185
- "\\* The rules\nINVARIENT NeverLocked\nSPECIFICATION Spec\n",
1186
- /^TLC refuses .*Login\.cfg at line 2\. It was expecting a keyword, but did not find it\.$/m,
1187
- ],
1188
- [
1189
- "a CHECK_DEADLOCK value in lower case",
1190
- "SPECIFICATION Spec\nINVARIANT TypeOK\nCHECK_DEADLOCK false\n",
1191
- /Login\.cfg at line 3\. It was expecting TRUE or FALSE, but did not find it\./,
1192
- ],
1193
- [
1194
- "an ALIAS line",
1195
- "SPECIFICATION Spec\nINVARIANT TypeOK\nVIEW vars\nALIAS Pretty\n",
1196
- /Login\.cfg at line 4\. It was expecting a keyword, but did not find it\./,
1197
- ],
1198
- [
1199
- "a comma between invariants",
1200
- "SPECIFICATION Spec\nINVARIANT TypeOK, NeverLocked\n",
1201
- /Login\.cfg at line 2\. The invariant , specified in the configuration file is not defined in the specification\./,
1202
- ],
1203
- [
1204
- "a keyword two times",
1205
- "SPECIFICATION Spec\nINVARIANT TypeOK\nSPECIFICATION Spec\n",
1206
- /Login\.cfg at line 3\. The keyword SPECIFICATION appeared twice\./,
1207
- ],
1208
- [
1209
- "a constant value that TLC cannot read",
1210
- "CONSTANT N = -1\nSPECIFICATION Spec\n",
1211
- /Login\.cfg at line 1\..*"-"/,
1212
- ],
1213
- [
1214
- "both SPECIFICATION and NEXT",
1215
- "SPECIFICATION Spec\nNEXT Next\nINVARIANT TypeOK\n",
1216
- /^TLC refuses the config .*Login\.cfg\. The configuration file cannot specify both INIT\/NEXT and SPECIFICATION fields\.$/m,
1217
- ],
1218
- [
1219
- "no SPECIFICATION and no INIT",
1220
- "\\* The rules\nINVARIANT TypeOK\n",
1221
- /^TLC refuses the config .*Login\.cfg\. The configuration file did not specify the initial state predicate\.$/m,
1222
- ],
1223
- [
1224
- "an operator constant with no arguments",
1225
- "CONSTANT f() = 1\nSPECIFICATION Spec\n",
1226
- /^TLC refuses .*Login\.cfg at line 1\. TLC gives no reason here\. An operator's arguments are one or more values in \( \), with commas between them\.$/m,
1227
- ],
1228
- [
1229
- "operator arguments with no closing parenthesis",
1230
- "SPECIFICATION Spec\n\nCONSTANT f(1, 2 = 3\n",
1231
- /^TLC refuses .*Login\.cfg at line 3\. TLC gives no reason here\. An operator's arguments are one or more values in \( \), with commas between them\.$/m,
1232
- ],
1233
- [
1234
- "a CONSTANT keyword on its own line before operator arguments with no closing parenthesis",
1235
- "SPECIFICATION Spec\nCONSTANT\nf(1, 2\n= 3\n",
1236
- /^TLC refuses .*Login\.cfg at line 2\. TLC gives no reason here\. An operator's arguments are one or more values in \( \), with commas between them\.$/m,
1237
- ],
1238
- [
1239
- "a comma invariant before a CHECK_DEADLOCK value in lower case",
1240
- "SPECIFICATION Spec\nINVARIANT ,\nCHECK_DEADLOCK false\n",
1241
- /Login\.cfg at line 3\. It was expecting TRUE or FALSE, but did not find it\./,
1242
- ],
1243
- [
1244
- "a comment that does not end",
1245
- "SPECIFICATION Spec\nINVARIANT TypeOK\n(* The view\nVIEW vars\n",
1246
- /Login\.cfg at line 3\..*\bcomment\b/,
1247
- ],
1248
- [
1249
- "CHECK_DEADLOCK FALSE in a comment that does not end",
1250
- "INVARIANT TypeOK\nSPECIFICATION Spec\n(* CHECK_DEADLOCK FALSE\n",
1251
- /Login\.cfg at line 3\. A comment starts here and does not end\./,
1252
- ],
1253
- [
1254
- "a no-break space before CHECK_DEADLOCK FALSE",
1255
- "SPECIFICATION Spec\nINVARIANT TypeOK\n\u00a0CHECK_DEADLOCK FALSE\n",
1256
- /Login\.cfg at line 3\. It cannot read the character "\u00a0" \(U\+00A0\) outside a string\./,
1257
- ],
1258
- [
1259
- "a line separator before CHECK_DEADLOCK FALSE",
1260
- "SPECIFICATION Spec\nINVARIANT TypeOK\u2028CHECK_DEADLOCK FALSE\n",
1261
- /Login\.cfg at line 2\. It cannot read the character "\u2028" \(U\+2028\) outside a string\./,
1262
- ],
1263
- [
1264
- "a byte order mark",
1265
- "\uFEFFSPECIFICATION Spec\nINVARIANT TypeOK\n",
1266
- /Login\.cfg at line 1\. The file starts with a byte order mark\. Save it as UTF-8 without one\.$/m,
1267
- ],
1268
- ] satisfies [string, string, RegExp][]) {
1269
- test(`a config with ${what} stops the command with exit 2 before TLC runs`, () => {
1270
- const dir = copyCase("Login", (d) => fs.writeFileSync(path.join(d, "Login.cfg"), config));
1271
- const r = run(dir);
1272
- assert.equal(r.status, 2);
1273
- assert.match(r.stderr, words);
1274
- assert.deepEqual(r.configs, {});
1275
- assert.deepEqual(r.files, []);
1276
- });
1277
- }
1278
-
1279
- test("a nested comment hides all of its text, as in TLC", () => {
1280
- const dir = copyCase("Login", (d) => {
1281
- const file = path.join(d, "Login.cfg");
1282
- fs.writeFileSync(file, `(* Off: (* old *) CHECK_DEADLOCK FALSE *)\n${read(file)}`);
1283
- });
1284
- const r = run(dir);
1285
- assert.equal(r.status, 0);
1286
- assert.equal(r.report, read(path.join(corpus, "Login", "report.md")));
1287
- });
1288
-
1289
- test("a string constant keeps the keywords and comment markers in it", () => {
1290
- const dir = copyCase("TwoPhase", (d) =>
1291
- fs.writeFileSync(
1292
- path.join(d, "TwoPhase.cfg"),
1293
- 'CONSTANT RM = {"INVARIANT (*", "\\\\* r2"}\nSPECIFICATION TPSpec\nINVARIANT TPTypeOK TCConsistent\n',
1294
- ),
1295
- );
1296
- const r = run(dir);
1297
- assert.equal(r.status, 1);
1298
- assert.equal(r.report, read(path.join(corpus, "TwoPhase", "report.md")));
1299
- assert.match(r.configs.ChartRun, /^CONSTANT RM = .*"INVARIANT \(\*".*"\\\\\* r2"/m);
1300
- assert.deepEqual(r.configs.ChartRun.match(/^INVARIANT.*$/gm), ["INVARIANT ChartMark"]);
1301
- });
1302
-
1303
- test("TYPE and TYPE_CONSTRAINT are config keywords, as in TLC", () => {
1304
- const dir = copyCase("Login", (d) =>
1305
- fs.writeFileSync(
1306
- path.join(d, "Login.cfg"),
1307
- "SPECIFICATION Spec\nINVARIANT TypeOK\nTYPE TypeOK\nTYPE_CONSTRAINT TypeOK\nVIEW vars\n",
1308
- ),
1309
- );
1310
- const r = run(dir);
1311
- assert.equal(r.status, 0);
1312
- assert.equal(r.report, read(path.join(corpus, "Login", "report.md")));
1313
- assert.match(r.configs.ChartRun, /^TYPE TypeOK$/m);
1314
- assert.match(r.configs.ChartRun, /^TYPE_CONSTRAINT TypeOK$/m);
1315
- });