moonwall 1.0.0-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (301) hide show
  1. package/LICENSE +681 -0
  2. package/README.md +54 -0
  3. package/config_schema.json +811 -0
  4. package/dist/api/constants/accounts.d.ts +36 -0
  5. package/dist/api/constants/accounts.d.ts.map +1 -0
  6. package/dist/api/constants/accounts.js +67 -0
  7. package/dist/api/constants/chain.d.ts +134 -0
  8. package/dist/api/constants/chain.d.ts.map +1 -0
  9. package/dist/api/constants/chain.js +149 -0
  10. package/dist/api/constants/index.d.ts +4 -0
  11. package/dist/api/constants/index.d.ts.map +1 -0
  12. package/dist/api/constants/index.js +3 -0
  13. package/dist/api/constants/smartContract.d.ts +29 -0
  14. package/dist/api/constants/smartContract.d.ts.map +1 -0
  15. package/dist/api/constants/smartContract.js +118 -0
  16. package/dist/api/testing/blocks.d.ts +59 -0
  17. package/dist/api/testing/blocks.d.ts.map +1 -0
  18. package/dist/api/testing/blocks.js +147 -0
  19. package/dist/api/testing/contracts.d.ts +5 -0
  20. package/dist/api/testing/contracts.d.ts.map +1 -0
  21. package/dist/api/testing/contracts.js +32 -0
  22. package/dist/api/testing/ethers.d.ts +3 -0
  23. package/dist/api/testing/ethers.d.ts.map +1 -0
  24. package/dist/api/testing/ethers.js +38 -0
  25. package/dist/api/testing/events.d.ts +12 -0
  26. package/dist/api/testing/events.d.ts.map +1 -0
  27. package/dist/api/testing/events.js +23 -0
  28. package/dist/api/testing/extrinsics.d.ts +5 -0
  29. package/dist/api/testing/extrinsics.d.ts.map +1 -0
  30. package/dist/api/testing/extrinsics.js +10 -0
  31. package/dist/api/testing/index.d.ts +9 -0
  32. package/dist/api/testing/index.d.ts.map +1 -0
  33. package/dist/api/testing/index.js +8 -0
  34. package/dist/api/testing/jumping.d.ts +8 -0
  35. package/dist/api/testing/jumping.d.ts.map +1 -0
  36. package/dist/api/testing/jumping.js +78 -0
  37. package/dist/api/testing/providers.d.ts +18 -0
  38. package/dist/api/testing/providers.d.ts.map +1 -0
  39. package/dist/api/testing/providers.js +34 -0
  40. package/dist/api/testing/viem.d.ts +139 -0
  41. package/dist/api/testing/viem.d.ts.map +1 -0
  42. package/dist/api/testing/viem.js +247 -0
  43. package/dist/api/types/config.d.ts +609 -0
  44. package/dist/api/types/config.d.ts.map +1 -0
  45. package/dist/api/types/config.js +1 -0
  46. package/dist/api/types/context.d.ts +125 -0
  47. package/dist/api/types/context.d.ts.map +1 -0
  48. package/dist/api/types/context.js +1 -0
  49. package/dist/api/types/contracts.d.ts +66 -0
  50. package/dist/api/types/contracts.d.ts.map +1 -0
  51. package/dist/api/types/contracts.js +1 -0
  52. package/dist/api/types/eth.d.ts +3 -0
  53. package/dist/api/types/eth.d.ts.map +1 -0
  54. package/dist/api/types/eth.js +1 -0
  55. package/dist/api/types/foundations.d.ts +11 -0
  56. package/dist/api/types/foundations.d.ts.map +1 -0
  57. package/dist/api/types/foundations.js +1 -0
  58. package/dist/api/types/helpers.d.ts +7 -0
  59. package/dist/api/types/helpers.d.ts.map +1 -0
  60. package/dist/api/types/helpers.js +1 -0
  61. package/dist/api/types/index.d.ts +8 -0
  62. package/dist/api/types/index.d.ts.map +1 -0
  63. package/dist/api/types/index.js +7 -0
  64. package/dist/api/types/runner.d.ts +490 -0
  65. package/dist/api/types/runner.d.ts.map +1 -0
  66. package/dist/api/types/runner.js +1 -0
  67. package/dist/cli/cmds/components/LogViewer.d.ts +17 -0
  68. package/dist/cli/cmds/components/LogViewer.d.ts.map +1 -0
  69. package/dist/cli/cmds/components/LogViewer.js +171 -0
  70. package/dist/cli/cmds/entrypoint.d.ts +6 -0
  71. package/dist/cli/cmds/entrypoint.d.ts.map +1 -0
  72. package/dist/cli/cmds/entrypoint.js +192 -0
  73. package/dist/cli/cmds/interactiveCmds/chopsticksIntCmds.d.ts +2 -0
  74. package/dist/cli/cmds/interactiveCmds/chopsticksIntCmds.d.ts.map +1 -0
  75. package/dist/cli/cmds/interactiveCmds/chopsticksIntCmds.js +117 -0
  76. package/dist/cli/cmds/interactiveCmds/devIntCmds.d.ts +2 -0
  77. package/dist/cli/cmds/interactiveCmds/devIntCmds.d.ts.map +1 -0
  78. package/dist/cli/cmds/interactiveCmds/devIntCmds.js +103 -0
  79. package/dist/cli/cmds/interactiveCmds/index.d.ts +4 -0
  80. package/dist/cli/cmds/interactiveCmds/index.d.ts.map +1 -0
  81. package/dist/cli/cmds/interactiveCmds/index.js +3 -0
  82. package/dist/cli/cmds/interactiveCmds/zombieIntCmds.d.ts +2 -0
  83. package/dist/cli/cmds/interactiveCmds/zombieIntCmds.d.ts.map +1 -0
  84. package/dist/cli/cmds/interactiveCmds/zombieIntCmds.js +32 -0
  85. package/dist/cli/cmds/main.d.ts +2 -0
  86. package/dist/cli/cmds/main.d.ts.map +1 -0
  87. package/dist/cli/cmds/main.js +336 -0
  88. package/dist/cli/cmds/runNetwork.d.ts +3 -0
  89. package/dist/cli/cmds/runNetwork.d.ts.map +1 -0
  90. package/dist/cli/cmds/runNetwork.js +292 -0
  91. package/dist/cli/cmds/runTests.d.ts +12 -0
  92. package/dist/cli/cmds/runTests.d.ts.map +1 -0
  93. package/dist/cli/cmds/runTests.js +257 -0
  94. package/dist/cli/internal/cmdFunctions/downloader.d.ts +4 -0
  95. package/dist/cli/internal/cmdFunctions/downloader.d.ts.map +1 -0
  96. package/dist/cli/internal/cmdFunctions/downloader.js +49 -0
  97. package/dist/cli/internal/cmdFunctions/fetchArtifact.d.ts +10 -0
  98. package/dist/cli/internal/cmdFunctions/fetchArtifact.d.ts.map +1 -0
  99. package/dist/cli/internal/cmdFunctions/fetchArtifact.js +145 -0
  100. package/dist/cli/internal/cmdFunctions/index.d.ts +5 -0
  101. package/dist/cli/internal/cmdFunctions/index.d.ts.map +1 -0
  102. package/dist/cli/internal/cmdFunctions/index.js +4 -0
  103. package/dist/cli/internal/cmdFunctions/initialisation.d.ts +20 -0
  104. package/dist/cli/internal/cmdFunctions/initialisation.d.ts.map +1 -0
  105. package/dist/cli/internal/cmdFunctions/initialisation.js +150 -0
  106. package/dist/cli/internal/cmdFunctions/tempLogs.d.ts +3 -0
  107. package/dist/cli/internal/cmdFunctions/tempLogs.d.ts.map +1 -0
  108. package/dist/cli/internal/cmdFunctions/tempLogs.js +37 -0
  109. package/dist/cli/internal/commandParsers.d.ts +59 -0
  110. package/dist/cli/internal/commandParsers.d.ts.map +1 -0
  111. package/dist/cli/internal/commandParsers.js +305 -0
  112. package/dist/cli/internal/deriveTestIds.d.ts +8 -0
  113. package/dist/cli/internal/deriveTestIds.d.ts.map +1 -0
  114. package/dist/cli/internal/deriveTestIds.js +123 -0
  115. package/dist/cli/internal/effect/index.d.ts +6 -0
  116. package/dist/cli/internal/effect/index.d.ts.map +1 -0
  117. package/dist/cli/internal/effect/index.js +5 -0
  118. package/dist/cli/internal/fileCheckers.d.ts +11 -0
  119. package/dist/cli/internal/fileCheckers.d.ts.map +1 -0
  120. package/dist/cli/internal/fileCheckers.js +165 -0
  121. package/dist/cli/internal/foundations/index.d.ts +4 -0
  122. package/dist/cli/internal/foundations/index.d.ts.map +1 -0
  123. package/dist/cli/internal/foundations/index.js +4 -0
  124. package/dist/cli/internal/index.d.ts +12 -0
  125. package/dist/cli/internal/index.d.ts.map +1 -0
  126. package/dist/cli/internal/index.js +11 -0
  127. package/dist/cli/internal/launcherCommon.d.ts +4 -0
  128. package/dist/cli/internal/launcherCommon.d.ts.map +1 -0
  129. package/dist/cli/internal/launcherCommon.js +130 -0
  130. package/dist/cli/internal/localNode.d.ts +16 -0
  131. package/dist/cli/internal/localNode.d.ts.map +1 -0
  132. package/dist/cli/internal/localNode.js +362 -0
  133. package/dist/cli/internal/logging.d.ts +2 -0
  134. package/dist/cli/internal/logging.d.ts.map +1 -0
  135. package/dist/cli/internal/logging.js +26 -0
  136. package/dist/cli/internal/node.d.ts +33 -0
  137. package/dist/cli/internal/node.d.ts.map +1 -0
  138. package/dist/cli/internal/node.js +228 -0
  139. package/dist/cli/internal/processHelpers.d.ts +17 -0
  140. package/dist/cli/internal/processHelpers.d.ts.map +1 -0
  141. package/dist/cli/internal/processHelpers.js +56 -0
  142. package/dist/cli/internal/providerFactories.d.ts +48 -0
  143. package/dist/cli/internal/providerFactories.d.ts.map +1 -0
  144. package/dist/cli/internal/providerFactories.js +442 -0
  145. package/dist/cli/internal/testIdParser.d.ts +34 -0
  146. package/dist/cli/internal/testIdParser.d.ts.map +1 -0
  147. package/dist/cli/internal/testIdParser.js +167 -0
  148. package/dist/cli/lib/binariesHelpers.d.ts +15 -0
  149. package/dist/cli/lib/binariesHelpers.d.ts.map +1 -0
  150. package/dist/cli/lib/binariesHelpers.js +99 -0
  151. package/dist/cli/lib/configReader.d.ts +8 -0
  152. package/dist/cli/lib/configReader.d.ts.map +1 -0
  153. package/dist/cli/lib/configReader.js +115 -0
  154. package/dist/cli/lib/contractFunctions.d.ts +2 -0
  155. package/dist/cli/lib/contractFunctions.d.ts.map +1 -0
  156. package/dist/cli/lib/contractFunctions.js +2 -0
  157. package/dist/cli/lib/globalContext.d.ts +46 -0
  158. package/dist/cli/lib/globalContext.d.ts.map +1 -0
  159. package/dist/cli/lib/globalContext.js +710 -0
  160. package/dist/cli/lib/governanceProcedures.d.ts +27 -0
  161. package/dist/cli/lib/governanceProcedures.d.ts.map +1 -0
  162. package/dist/cli/lib/governanceProcedures.js +458 -0
  163. package/dist/cli/lib/handlers/index.d.ts +5 -0
  164. package/dist/cli/lib/handlers/index.d.ts.map +1 -0
  165. package/dist/cli/lib/handlers/index.js +5 -0
  166. package/dist/cli/lib/repoDefinitions/index.d.ts +6 -0
  167. package/dist/cli/lib/repoDefinitions/index.d.ts.map +1 -0
  168. package/dist/cli/lib/repoDefinitions/index.js +21 -0
  169. package/dist/cli/lib/repoDefinitions/moonbeam.d.ts +4 -0
  170. package/dist/cli/lib/repoDefinitions/moonbeam.d.ts.map +1 -0
  171. package/dist/cli/lib/repoDefinitions/moonbeam.js +30 -0
  172. package/dist/cli/lib/repoDefinitions/polkadot.d.ts +4 -0
  173. package/dist/cli/lib/repoDefinitions/polkadot.d.ts.map +1 -0
  174. package/dist/cli/lib/repoDefinitions/polkadot.js +11 -0
  175. package/dist/cli/lib/repoDefinitions/tanssi.d.ts +4 -0
  176. package/dist/cli/lib/repoDefinitions/tanssi.d.ts.map +1 -0
  177. package/dist/cli/lib/repoDefinitions/tanssi.js +14 -0
  178. package/dist/cli/lib/rpcFunctions.d.ts +2 -0
  179. package/dist/cli/lib/rpcFunctions.d.ts.map +1 -0
  180. package/dist/cli/lib/rpcFunctions.js +26 -0
  181. package/dist/cli/lib/runnerContext.d.ts +32 -0
  182. package/dist/cli/lib/runnerContext.d.ts.map +1 -0
  183. package/dist/cli/lib/runnerContext.js +156 -0
  184. package/dist/cli/lib/shardManager.d.ts +40 -0
  185. package/dist/cli/lib/shardManager.d.ts.map +1 -0
  186. package/dist/cli/lib/shardManager.js +80 -0
  187. package/dist/cli/lib/upgradeProcedures.d.ts +5 -0
  188. package/dist/cli/lib/upgradeProcedures.d.ts.map +1 -0
  189. package/dist/cli/lib/upgradeProcedures.js +221 -0
  190. package/dist/cli.d.ts +4 -0
  191. package/dist/cli.d.ts.map +1 -0
  192. package/dist/cli.js +3 -0
  193. package/dist/contracts/contractInteraction.d.ts +17 -0
  194. package/dist/contracts/contractInteraction.d.ts.map +1 -0
  195. package/dist/contracts/contractInteraction.js +170 -0
  196. package/dist/contracts/index.d.ts +2 -0
  197. package/dist/contracts/index.d.ts.map +1 -0
  198. package/dist/contracts/index.js +1 -0
  199. package/dist/foundations/chopsticks/handler.d.ts +3 -0
  200. package/dist/foundations/chopsticks/handler.d.ts.map +1 -0
  201. package/dist/foundations/chopsticks/handler.js +93 -0
  202. package/dist/foundations/chopsticks/helpers.d.ts +27 -0
  203. package/dist/foundations/chopsticks/helpers.d.ts.map +1 -0
  204. package/dist/foundations/chopsticks/helpers.js +133 -0
  205. package/dist/foundations/dev/handler.d.ts +3 -0
  206. package/dist/foundations/dev/handler.d.ts.map +1 -0
  207. package/dist/foundations/dev/handler.js +136 -0
  208. package/dist/foundations/dev/helpers.d.ts +27 -0
  209. package/dist/foundations/dev/helpers.d.ts.map +1 -0
  210. package/dist/foundations/dev/helpers.js +161 -0
  211. package/dist/foundations/read-only/handler.d.ts +3 -0
  212. package/dist/foundations/read-only/handler.d.ts.map +1 -0
  213. package/dist/foundations/read-only/handler.js +32 -0
  214. package/dist/foundations/zombie/handler.d.ts +3 -0
  215. package/dist/foundations/zombie/handler.d.ts.map +1 -0
  216. package/dist/foundations/zombie/handler.js +92 -0
  217. package/dist/foundations/zombie/helpers.d.ts +16 -0
  218. package/dist/foundations/zombie/helpers.d.ts.map +1 -0
  219. package/dist/foundations/zombie/helpers.js +97 -0
  220. package/dist/index.d.ts +17 -0
  221. package/dist/index.d.ts.map +1 -0
  222. package/dist/index.js +47 -0
  223. package/dist/internal/common.d.ts +3 -0
  224. package/dist/internal/common.d.ts.map +1 -0
  225. package/dist/internal/common.js +41 -0
  226. package/dist/internal/index.d.ts +4 -0
  227. package/dist/internal/index.d.ts.map +1 -0
  228. package/dist/internal/index.js +3 -0
  229. package/dist/internal/logger.d.ts +24 -0
  230. package/dist/internal/logger.d.ts.map +1 -0
  231. package/dist/internal/logger.js +66 -0
  232. package/dist/internal/logging.d.ts +7 -0
  233. package/dist/internal/logging.d.ts.map +1 -0
  234. package/dist/internal/logging.js +36 -0
  235. package/dist/moondebug.d.ts +3 -0
  236. package/dist/moondebug.d.ts.map +1 -0
  237. package/dist/moondebug.js +2 -0
  238. package/dist/services/cache/FileLock.d.ts +11 -0
  239. package/dist/services/cache/FileLock.d.ts.map +1 -0
  240. package/dist/services/cache/FileLock.js +68 -0
  241. package/dist/services/cache/StartupCacheService.d.ts +23 -0
  242. package/dist/services/cache/StartupCacheService.d.ts.map +1 -0
  243. package/dist/services/cache/StartupCacheService.js +159 -0
  244. package/dist/services/cache/index.d.ts +3 -0
  245. package/dist/services/cache/index.d.ts.map +1 -0
  246. package/dist/services/cache/index.js +2 -0
  247. package/dist/services/chopsticks/ChopsticksMultiChain.d.ts +158 -0
  248. package/dist/services/chopsticks/ChopsticksMultiChain.d.ts.map +1 -0
  249. package/dist/services/chopsticks/ChopsticksMultiChain.js +282 -0
  250. package/dist/services/chopsticks/ChopsticksService.d.ts +313 -0
  251. package/dist/services/chopsticks/ChopsticksService.d.ts.map +1 -0
  252. package/dist/services/chopsticks/ChopsticksService.js +77 -0
  253. package/dist/services/chopsticks/chopsticksConfigParser.d.ts +40 -0
  254. package/dist/services/chopsticks/chopsticksConfigParser.d.ts.map +1 -0
  255. package/dist/services/chopsticks/chopsticksConfigParser.js +201 -0
  256. package/dist/services/chopsticks/index.d.ts +5 -0
  257. package/dist/services/chopsticks/index.d.ts.map +1 -0
  258. package/dist/services/chopsticks/index.js +4 -0
  259. package/dist/services/chopsticks/launchChopsticksEffect.d.ts +225 -0
  260. package/dist/services/chopsticks/launchChopsticksEffect.d.ts.map +1 -0
  261. package/dist/services/chopsticks/launchChopsticksEffect.js +623 -0
  262. package/dist/services/config/configAccessors.d.ts +41 -0
  263. package/dist/services/config/configAccessors.d.ts.map +1 -0
  264. package/dist/services/config/configAccessors.js +149 -0
  265. package/dist/services/config/index.d.ts +2 -0
  266. package/dist/services/config/index.d.ts.map +1 -0
  267. package/dist/services/config/index.js +1 -0
  268. package/dist/services/errors.d.ts +72 -0
  269. package/dist/services/errors.d.ts.map +1 -0
  270. package/dist/services/errors.js +31 -0
  271. package/dist/services/index.d.ts +7 -0
  272. package/dist/services/index.d.ts.map +1 -0
  273. package/dist/services/index.js +6 -0
  274. package/dist/services/network/NodeReadinessService.d.ts +35 -0
  275. package/dist/services/network/NodeReadinessService.d.ts.map +1 -0
  276. package/dist/services/network/NodeReadinessService.js +120 -0
  277. package/dist/services/network/PortDiscoveryService.d.ts +22 -0
  278. package/dist/services/network/PortDiscoveryService.d.ts.map +1 -0
  279. package/dist/services/network/PortDiscoveryService.js +77 -0
  280. package/dist/services/network/RpcPortDiscoveryService.d.ts +25 -0
  281. package/dist/services/network/RpcPortDiscoveryService.d.ts.map +1 -0
  282. package/dist/services/network/RpcPortDiscoveryService.js +136 -0
  283. package/dist/services/network/index.d.ts +4 -0
  284. package/dist/services/network/index.d.ts.map +1 -0
  285. package/dist/services/network/index.js +3 -0
  286. package/dist/services/process/ProcessManagerService.d.ts +49 -0
  287. package/dist/services/process/ProcessManagerService.d.ts.map +1 -0
  288. package/dist/services/process/ProcessManagerService.js +162 -0
  289. package/dist/services/process/index.d.ts +3 -0
  290. package/dist/services/process/index.d.ts.map +1 -0
  291. package/dist/services/process/index.js +2 -0
  292. package/dist/services/process/launchNodeEffect.d.ts +40 -0
  293. package/dist/services/process/launchNodeEffect.d.ts.map +1 -0
  294. package/dist/services/process/launchNodeEffect.js +86 -0
  295. package/dist/util/functions/index.d.ts +3 -0
  296. package/dist/util/functions/index.d.ts.map +1 -0
  297. package/dist/util/functions/index.js +4 -0
  298. package/dist/util/index.d.ts +4 -0
  299. package/dist/util/index.d.ts.map +1 -0
  300. package/dist/util/index.js +2 -0
  301. package/package.json +157 -0
@@ -0,0 +1,167 @@
1
+ import { Lang, parse, findInFiles } from "@ast-grep/napi";
2
+ /**
3
+ * Extracts the "id" property value from an object literal AST node.
4
+ * Traverses children to find a "pair" node where the key is "id".
5
+ */
6
+ function extractIdFromObject(objNode) {
7
+ for (const child of objNode.children()) {
8
+ if (child.kind() === "pair") {
9
+ const key = child.field("key");
10
+ const value = child.field("value");
11
+ if (key?.text() === "id" && value) {
12
+ // Remove quotes from the string literal
13
+ return value.text().replace(/^['"`]|['"`]$/g, "");
14
+ }
15
+ }
16
+ }
17
+ return undefined;
18
+ }
19
+ /**
20
+ * Finds the "id" property node within an object literal for replacement.
21
+ */
22
+ function findIdValueNode(objNode) {
23
+ for (const child of objNode.children()) {
24
+ if (child.kind() === "pair") {
25
+ const key = child.field("key");
26
+ const value = child.field("value");
27
+ if (key?.text() === "id" && value) {
28
+ return value;
29
+ }
30
+ }
31
+ }
32
+ return undefined;
33
+ }
34
+ /**
35
+ * Extracts suite and test IDs from a Moonwall test file using AST parsing.
36
+ * This is more robust than regex as it handles comments, multiline formatting, etc.
37
+ */
38
+ export function extractTestIds(fileContent) {
39
+ const ast = parse(Lang.TypeScript, fileContent);
40
+ const root = ast.root();
41
+ // Find describeSuite({ id: "...", ... })
42
+ const describeSuiteCall = root.find("describeSuite($OPTS)");
43
+ let suiteId;
44
+ if (describeSuiteCall) {
45
+ const optsNode = describeSuiteCall.getMatch("OPTS");
46
+ if (optsNode && optsNode.kind() === "object") {
47
+ suiteId = extractIdFromObject(optsNode);
48
+ }
49
+ }
50
+ // Find all it({ id: "...", ... }) calls
51
+ const testIds = [];
52
+ const itCalls = root.findAll("it($OPTS)");
53
+ for (const itCall of itCalls) {
54
+ const optsNode = itCall.getMatch("OPTS");
55
+ if (optsNode && optsNode.kind() === "object") {
56
+ const testId = extractIdFromObject(optsNode);
57
+ if (testId) {
58
+ testIds.push(testId);
59
+ }
60
+ }
61
+ }
62
+ return { suiteId, testIds };
63
+ }
64
+ /**
65
+ * Replaces the suite ID in a Moonwall test file.
66
+ * Returns the modified file content, or undefined if no describeSuite was found.
67
+ */
68
+ export function replaceSuiteId(fileContent, newId) {
69
+ const ast = parse(Lang.TypeScript, fileContent);
70
+ const root = ast.root();
71
+ // Find describeSuite({ id: "...", ... })
72
+ const describeSuiteCall = root.find("describeSuite($OPTS)");
73
+ if (!describeSuiteCall) {
74
+ return undefined;
75
+ }
76
+ const optsNode = describeSuiteCall.getMatch("OPTS");
77
+ if (!optsNode || optsNode.kind() !== "object") {
78
+ return undefined;
79
+ }
80
+ // Find the id property value node
81
+ const idValueNode = findIdValueNode(optsNode);
82
+ if (!idValueNode) {
83
+ return undefined;
84
+ }
85
+ // Determine the quote style used in the original
86
+ const originalText = idValueNode.text();
87
+ const quoteChar = originalText[0];
88
+ // Create edit to replace the ID value
89
+ const edit = idValueNode.replace(`${quoteChar}${newId}${quoteChar}`);
90
+ return root.commitEdits([edit]);
91
+ }
92
+ /**
93
+ * Checks if a file contains a describeSuite call (is a Moonwall test file).
94
+ */
95
+ export function hasSuiteDefinition(fileContent) {
96
+ const ast = parse(Lang.TypeScript, fileContent);
97
+ const root = ast.root();
98
+ return root.find("describeSuite($$$)") !== null;
99
+ }
100
+ /**
101
+ * Finds all test files matching the pattern using ast-grep's parallel file search.
102
+ * Uses Rust threads for efficient parsing and searching.
103
+ *
104
+ * @param testDirs - Directories to search for test files
105
+ * @param includeGlobs - Glob patterns for files to include (e.g., ["*test*.ts", "*spec*.ts"])
106
+ * @param idPattern - Regex pattern to match against suite/test IDs
107
+ * @returns Promise resolving to array of matching file paths
108
+ */
109
+ export async function findTestFilesMatchingPattern(testDirs, includeGlobs, idPattern) {
110
+ const matches = [];
111
+ let processedCount = 0;
112
+ let expectedCount;
113
+ await new Promise((resolve, reject) => {
114
+ findInFiles(Lang.TypeScript, {
115
+ paths: testDirs,
116
+ matcher: { rule: { pattern: "describeSuite($OPTS)" } },
117
+ languageGlobs: includeGlobs,
118
+ }, (err, nodes) => {
119
+ if (err) {
120
+ reject(err);
121
+ return;
122
+ }
123
+ if (nodes.length === 0)
124
+ return;
125
+ // Get file info from the first node
126
+ const node = nodes[0];
127
+ const filePath = node.getRoot().filename();
128
+ const root = node.getRoot().root();
129
+ // Extract suite ID from the describeSuite call
130
+ const optsNode = node.getMatch("OPTS");
131
+ if (!optsNode || optsNode.kind() !== "object")
132
+ return;
133
+ const suiteId = extractIdFromObject(optsNode);
134
+ if (!suiteId)
135
+ return;
136
+ // Extract test IDs
137
+ const testIds = [];
138
+ const itCalls = root.findAll("it($OPTS)");
139
+ for (const itCall of itCalls) {
140
+ const itOpts = itCall.getMatch("OPTS");
141
+ if (itOpts && itOpts.kind() === "object") {
142
+ const testId = extractIdFromObject(itOpts);
143
+ if (testId)
144
+ testIds.push(testId);
145
+ }
146
+ }
147
+ // Check if any ID matches the pattern
148
+ const allIds = [suiteId, ...testIds.map((tid) => suiteId + tid)];
149
+ if (allIds.some((id) => idPattern.test(id))) {
150
+ matches.push(filePath);
151
+ }
152
+ processedCount++;
153
+ if (expectedCount !== undefined && processedCount >= expectedCount) {
154
+ resolve();
155
+ }
156
+ })
157
+ .then((count) => {
158
+ expectedCount = count;
159
+ // If all files already processed or no files found, resolve immediately
160
+ if (count === 0 || processedCount >= count) {
161
+ resolve();
162
+ }
163
+ })
164
+ .catch(reject);
165
+ });
166
+ return matches;
167
+ }
@@ -0,0 +1,15 @@
1
+ export declare const BINARY_DIRECTORY: string;
2
+ export declare const RUNTIME_DIRECTORY: string;
3
+ export declare const SPECS_DIRECTORY: string;
4
+ export declare function getGithubReleaseBinary(url: string, binaryPath: string): Promise<string>;
5
+ export declare function getMoonbeamReleaseBinary(binaryTag: string): Promise<string>;
6
+ export declare function getPolkadotReleaseBinary(binaryTag: string): Promise<string>;
7
+ export declare function getTanssiReleaseBinary(binaryTag: string): Promise<string>;
8
+ export declare function getTagSha8(binaryTag: string): Promise<string>;
9
+ export declare function getMoonbeamDockerBinary(binaryTag: string): Promise<string>;
10
+ export declare function getRuntimeWasm(runtimeName: "moonbase" | "moonriver" | "moonbeam", runtimeTag: "local" | string, localPath?: string): Promise<string>;
11
+ export declare function getPlainSpecsFromTag(runtimeName: "moonbase-local" | "moonriver-local" | "moonbeam-local", tag: string): Promise<string>;
12
+ export declare function getRawSpecsFromTag(runtimeName: "moonbase-local" | "moonriver-local" | "moonbeam-local", tag: string): Promise<string>;
13
+ export declare function generatePlainSpecs(binaryPath: string, runtimeName: "moonbase-local" | "moonriver-local" | "moonbeam-local"): Promise<string>;
14
+ export declare function generateRawSpecs(binaryPath: string, runtimeName: "moonbase-local" | "moonriver-local" | "moonbeam-local"): Promise<string>;
15
+ //# sourceMappingURL=binariesHelpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"binariesHelpers.d.ts","sourceRoot":"","sources":["../../../src/cli/lib/binariesHelpers.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,gBAAgB,QAA6C,CAAC;AAC3E,eAAO,MAAM,iBAAiB,QAA8C,CAAC;AAC7E,eAAO,MAAM,eAAe,QAAyC,CAAC;AAEtE,wBAAsB,sBAAsB,CAAC,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAY7F;AAGD,wBAAsB,wBAAwB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAMjF;AAED,wBAAsB,wBAAwB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAMjF;AAED,wBAAsB,sBAAsB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAM/E;AAED,wBAAsB,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAMnE;AAED,wBAAsB,uBAAuB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAkBhF;AAGD,wBAAsB,cAAc,CAClC,WAAW,EAAE,UAAU,GAAG,WAAW,GAAG,UAAU,EAClD,UAAU,EAAE,OAAO,GAAG,MAAM,EAC5B,SAAS,CAAC,EAAE,MAAM,GACjB,OAAO,CAAC,MAAM,CAAC,CA6BjB;AAED,wBAAsB,oBAAoB,CACxC,WAAW,EAAE,gBAAgB,GAAG,iBAAiB,GAAG,gBAAgB,EACpE,GAAG,EAAE,MAAM,mBAIZ;AAED,wBAAsB,kBAAkB,CACtC,WAAW,EAAE,gBAAgB,GAAG,iBAAiB,GAAG,gBAAgB,EACpE,GAAG,EAAE,MAAM,mBAIZ;AAgBD,wBAAsB,kBAAkB,CACtC,UAAU,EAAE,MAAM,EAClB,WAAW,EAAE,gBAAgB,GAAG,iBAAiB,GAAG,gBAAgB,mBAGrE;AAED,wBAAsB,gBAAgB,CACpC,UAAU,EAAE,MAAM,EAClB,WAAW,EAAE,gBAAgB,GAAG,iBAAiB,GAAG,gBAAgB,mBAGrE"}
@@ -0,0 +1,99 @@
1
+ import path from "node:path";
2
+ import fs from "node:fs";
3
+ import child_process from "node:child_process";
4
+ import { OVERRIDE_RUNTIME_PATH } from "../../util/index.js";
5
+ export const BINARY_DIRECTORY = process.env.BINARY_DIRECTORY || "binaries";
6
+ export const RUNTIME_DIRECTORY = process.env.RUNTIME_DIRECTORY || "runtimes";
7
+ export const SPECS_DIRECTORY = process.env.SPECS_DIRECTORY || "specs";
8
+ export async function getGithubReleaseBinary(url, binaryPath) {
9
+ if (!fs.existsSync(binaryPath)) {
10
+ console.log(` Missing ${binaryPath} locally, downloading it...`);
11
+ child_process.execSync(`mkdir -p ${path.dirname(binaryPath)} &&` +
12
+ ` wget -q ${url}` +
13
+ ` -O ${binaryPath} &&` +
14
+ ` chmod u+x ${binaryPath}`);
15
+ console.log(`${binaryPath} downloaded !`);
16
+ }
17
+ return binaryPath;
18
+ }
19
+ // Downloads the binary and return the filepath
20
+ export async function getMoonbeamReleaseBinary(binaryTag) {
21
+ const binaryPath = path.join(BINARY_DIRECTORY, `moonbeam-${binaryTag}`);
22
+ return getGithubReleaseBinary(`https://github.com/PureStake/moonbeam/releases/download/${binaryTag}/moonbeam`, binaryPath);
23
+ }
24
+ export async function getPolkadotReleaseBinary(binaryTag) {
25
+ const binaryPath = path.join(BINARY_DIRECTORY, `polkadot-${binaryTag}`);
26
+ return getGithubReleaseBinary(`https://github.com/paritytech/polkadot-sdk/releases/download/${binaryTag}/polkadot`, binaryPath);
27
+ }
28
+ export async function getTanssiReleaseBinary(binaryTag) {
29
+ const binaryPath = path.join(BINARY_DIRECTORY, `polkadot-${binaryTag}`);
30
+ return getGithubReleaseBinary(`https://github.com/moondance-labs/tanssi/releases/download/${binaryTag}/polkadot`, binaryPath);
31
+ }
32
+ export async function getTagSha8(binaryTag) {
33
+ const sha = child_process.execSync(`git rev-list -1 ${binaryTag}`).toString();
34
+ if (!sha) {
35
+ throw new Error(`Invalid runtime tag ${binaryTag}`);
36
+ }
37
+ return sha.slice(0, 8);
38
+ }
39
+ export async function getMoonbeamDockerBinary(binaryTag) {
40
+ const sha8 = await getTagSha8(binaryTag);
41
+ const binaryPath = path.join(BINARY_DIRECTORY, `moonbeam-${sha8}`);
42
+ if (!fs.existsSync(binaryPath)) {
43
+ if (process.platform !== "linux") {
44
+ console.error("docker binaries are only supported on linux.");
45
+ throw new Error("docker binaries are only supported on linux.");
46
+ }
47
+ const dockerImage = `purestake/moonbeam:sha-${sha8}`;
48
+ console.log(` Missing ${binaryPath} locally, downloading it...`);
49
+ child_process.execSync(`mkdir -p ${path.dirname(binaryPath)} && \
50
+ docker create --pull always --name moonbeam-tmp ${dockerImage} && \
51
+ docker cp moonbeam-tmp:/moonbeam/moonbeam ${binaryPath} && \
52
+ docker rm moonbeam-tmp`);
53
+ console.log(`${binaryPath} downloaded !`);
54
+ }
55
+ return binaryPath;
56
+ }
57
+ // Downloads the runtime and return the filepath
58
+ export async function getRuntimeWasm(runtimeName, runtimeTag, localPath) {
59
+ const runtimePath = path.join(RUNTIME_DIRECTORY, `${runtimeName}-${runtimeTag}.wasm`);
60
+ if (!fs.existsSync(RUNTIME_DIRECTORY)) {
61
+ fs.mkdirSync(RUNTIME_DIRECTORY, { recursive: true });
62
+ }
63
+ if (runtimeTag === "local") {
64
+ const builtRuntimePath = localPath
65
+ ? localPath
66
+ : path.join(OVERRIDE_RUNTIME_PATH || `../target/release/wbuild/${runtimeName}-runtime/`, `${runtimeName}_runtime.compact.compressed.wasm`);
67
+ const code = fs.readFileSync(builtRuntimePath);
68
+ fs.writeFileSync(runtimePath, `0x${code.toString("hex")}`);
69
+ }
70
+ else if (!fs.existsSync(runtimePath)) {
71
+ console.log(` Missing ${runtimePath} locally, downloading it...`);
72
+ child_process.execSync(`mkdir -p ${path.dirname(runtimePath)} && wget -q https://github.com/PureStake/moonbeam/releases/download/${runtimeTag}/${runtimeName}-${runtimeTag}.wasm -O ${runtimePath}.bin`);
73
+ const code = fs.readFileSync(`${runtimePath}.bin`);
74
+ fs.writeFileSync(runtimePath, `0x${code.toString("hex")}`);
75
+ console.log(`${runtimePath} downloaded !`);
76
+ }
77
+ return runtimePath;
78
+ }
79
+ export async function getPlainSpecsFromTag(runtimeName, tag) {
80
+ const binaryPath = await getMoonbeamDockerBinary(tag);
81
+ return generateSpecs(binaryPath, runtimeName, false);
82
+ }
83
+ export async function getRawSpecsFromTag(runtimeName, tag) {
84
+ const binaryPath = await getMoonbeamDockerBinary(tag);
85
+ return generateSpecs(binaryPath, runtimeName, true);
86
+ }
87
+ async function generateSpecs(binaryPath, runtimeName, raw) {
88
+ const specPath = path.join(SPECS_DIRECTORY, `${runtimeName}-${raw ? "raw" : "plain"}-specs.json`);
89
+ child_process.execSync(`mkdir -p ${path.dirname(specPath)} && ` +
90
+ `${binaryPath} build-spec --chain ${runtimeName} ` +
91
+ `${raw ? "--raw" : ""} --disable-default-bootnode > ${specPath}`);
92
+ return specPath;
93
+ }
94
+ export async function generatePlainSpecs(binaryPath, runtimeName) {
95
+ return generateSpecs(binaryPath, runtimeName, false);
96
+ }
97
+ export async function generateRawSpecs(binaryPath, runtimeName) {
98
+ return generateSpecs(binaryPath, runtimeName, true);
99
+ }
@@ -0,0 +1,8 @@
1
+ import type { MoonwallConfig } from "../../api/types/index.js";
2
+ export { importJsonConfig, cacheConfig, getEnvironmentFromConfig, isEthereumDevConfig, isEthereumZombieConfig, isOptionSet, loadEnvVars, } from "../../services/config/index.js";
3
+ export declare function configExists(): Promise<boolean>;
4
+ export declare function configSetup(args: string[]): void;
5
+ export declare function importConfig(configPath: string): Promise<MoonwallConfig>;
6
+ export declare function importAsyncConfig(): Promise<MoonwallConfig>;
7
+ export declare function parseZombieConfigForBins(zombieConfigPath: string): string[];
8
+ //# sourceMappingURL=configReader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"configReader.d.ts","sourceRoot":"","sources":["../../../src/cli/lib/configReader.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,iCAAiC;AAQ/D,OAAO,EACL,gBAAgB,EAChB,WAAW,EACX,wBAAwB,EACxB,mBAAmB,EACnB,sBAAsB,EACtB,WAAW,EACX,WAAW,GACZ,uCAAuC;AAIxC,wBAAsB,YAAY,qBAOjC;AAED,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,QAyBzC;AAsCD,wBAAsB,YAAY,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC,CAE9E;AAED,wBAAsB,iBAAiB,IAAI,OAAO,CAAC,cAAc,CAAC,CAuBjE;AAED,wBAAgB,wBAAwB,CAAC,gBAAgB,EAAE,MAAM,YAiBhE"}
@@ -0,0 +1,115 @@
1
+ var __rewriteRelativeImportExtension = (this && this.__rewriteRelativeImportExtension) || function (path, preserveJsx) {
2
+ if (typeof path === "string" && /^\.\.?\//.test(path)) {
3
+ return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
4
+ return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
5
+ });
6
+ }
7
+ return path;
8
+ };
9
+ import { readFile, access } from "node:fs/promises";
10
+ import { readFileSync, existsSync, constants } from "node:fs";
11
+ import JSONC from "jsonc-parser";
12
+ import path, { extname } from "node:path";
13
+ import { getCachedConfig, setCachedConfig } from "../../services/config/index.js";
14
+ // Re-export from services/config for backwards compatibility
15
+ export { importJsonConfig, cacheConfig, getEnvironmentFromConfig, isEthereumDevConfig, isEthereumZombieConfig, isOptionSet, loadEnvVars, } from "../../services/config/index.js";
16
+ // CLI-specific functions below
17
+ export async function configExists() {
18
+ try {
19
+ await access(process.env.MOON_CONFIG_PATH || "", constants.R_OK);
20
+ return true;
21
+ }
22
+ catch {
23
+ return false;
24
+ }
25
+ }
26
+ export function configSetup(args) {
27
+ if (args.includes("--configFile") || process.argv.includes("-c")) {
28
+ const index = process.argv.indexOf("--configFile") !== -1
29
+ ? process.argv.indexOf("--configFile")
30
+ : process.argv.indexOf("-c") !== -1
31
+ ? process.argv.indexOf("-c")
32
+ : 0;
33
+ if (index === 0) {
34
+ throw new Error("Invalid configFile argument");
35
+ }
36
+ const configFile = process.argv[index + 1];
37
+ if (!existsSync(configFile)) {
38
+ throw new Error(`Config file not found at "${configFile}"`);
39
+ }
40
+ process.env.MOON_CONFIG_PATH = configFile;
41
+ }
42
+ if (!process.env.MOON_CONFIG_PATH) {
43
+ process.env.MOON_CONFIG_PATH = "moonwall.config.json";
44
+ }
45
+ }
46
+ async function parseConfig(filePath) {
47
+ let result;
48
+ const file = await readFile(filePath, "utf8");
49
+ switch (extname(filePath)) {
50
+ case ".json":
51
+ result = JSON.parse(file);
52
+ break;
53
+ case ".config":
54
+ result = JSONC.parse(file);
55
+ break;
56
+ default:
57
+ result = undefined;
58
+ break;
59
+ }
60
+ return result;
61
+ }
62
+ function replaceEnvVars(value) {
63
+ if (typeof value === "string") {
64
+ return value.replace(/\$\{([^}]+)\}/g, (match, group) => {
65
+ const envVarValue = process.env[group];
66
+ return envVarValue || match;
67
+ });
68
+ }
69
+ if (Array.isArray(value)) {
70
+ return value.map(replaceEnvVars);
71
+ }
72
+ if (typeof value === "object" && value !== null) {
73
+ return Object.fromEntries(Object.entries(value).map(([k, v]) => [k, replaceEnvVars(v)]));
74
+ }
75
+ return value;
76
+ }
77
+ export async function importConfig(configPath) {
78
+ return await import(__rewriteRelativeImportExtension(configPath));
79
+ }
80
+ export async function importAsyncConfig() {
81
+ const cached = getCachedConfig();
82
+ if (cached) {
83
+ return cached;
84
+ }
85
+ const configPath = process.env.MOON_CONFIG_PATH;
86
+ if (!configPath) {
87
+ throw new Error("No moonwall config path set. This is a defect, please raise it.");
88
+ }
89
+ const filePath = path.isAbsolute(configPath) ? configPath : path.join(process.cwd(), configPath);
90
+ try {
91
+ const config = await parseConfig(filePath);
92
+ const replacedConfig = replaceEnvVars(config);
93
+ setCachedConfig(replacedConfig);
94
+ return replacedConfig;
95
+ }
96
+ catch (e) {
97
+ console.error(e);
98
+ throw new Error(`Error import config at ${filePath}`, { cause: e });
99
+ }
100
+ }
101
+ export function parseZombieConfigForBins(zombieConfigPath) {
102
+ const config = JSON.parse(readFileSync(zombieConfigPath, "utf8"));
103
+ const commands = [];
104
+ if (config.relaychain?.default_command) {
105
+ commands.push(path.basename(config.relaychain.default_command));
106
+ }
107
+ if (config.parachains) {
108
+ for (const parachain of config.parachains) {
109
+ if (parachain.collator?.command) {
110
+ commands.push(path.basename(parachain.collator.command));
111
+ }
112
+ }
113
+ }
114
+ return [...new Set(commands)].sort();
115
+ }
@@ -0,0 +1,2 @@
1
+ export { fetchCompiledContract, recursiveSearch, interactWithPrecompileContract, interactWithContract, deployCreateCompiledContract, } from "../../contracts/index.js";
2
+ //# sourceMappingURL=contractFunctions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contractFunctions.d.ts","sourceRoot":"","sources":["../../../src/cli/lib/contractFunctions.ts"],"names":[],"mappings":"AACA,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,8BAA8B,EAC9B,oBAAoB,EACpB,4BAA4B,GAC7B,iCAAiC"}
@@ -0,0 +1,2 @@
1
+ // Re-export from contracts module for backwards compatibility
2
+ export { fetchCompiledContract, recursiveSearch, interactWithPrecompileContract, interactWithContract, deployCreateCompiledContract, } from "../../contracts/index.js";
@@ -0,0 +1,46 @@
1
+ import type { ConnectedProvider, FoundationType, LaunchOverrides, MoonwallConfig, MoonwallEnvironment, MoonwallProvider } from "../../api/types/index.js";
2
+ import { type Network } from "@zombienet/orchestrator";
3
+ import Docker from "dockerode";
4
+ import { ChildProcess } from "node:child_process";
5
+ import net from "node:net";
6
+ export declare class MoonwallContext {
7
+ private static instance;
8
+ configured: boolean;
9
+ environment: MoonwallEnvironment;
10
+ providers: ConnectedProvider[];
11
+ nodes: (ChildProcess | Docker.Container)[];
12
+ foundation: FoundationType;
13
+ zombieNetwork?: Network;
14
+ rtUpgradePath?: string;
15
+ ipcServer?: net.Server;
16
+ injectedOptions?: LaunchOverrides;
17
+ private nodeCleanupHandlers;
18
+ constructor(config: MoonwallConfig, options?: LaunchOverrides);
19
+ setupFoundation(): Promise<void>;
20
+ private handleZombie;
21
+ private handleDev;
22
+ private handleReadOnly;
23
+ private handleChopsticks;
24
+ private startZombieNetwork;
25
+ startNetwork(): Promise<void | MoonwallContext>;
26
+ connectEnvironment(silent?: boolean): Promise<MoonwallContext>;
27
+ private handleZombiePostConnection;
28
+ disconnect(providerName?: string): Promise<void>;
29
+ static getContext(config?: MoonwallConfig, options?: LaunchOverrides, force?: boolean): Promise<MoonwallContext>;
30
+ static destroy(reason?: string): Promise<void>;
31
+ }
32
+ export declare const contextCreator: (options?: LaunchOverrides) => Promise<MoonwallContext>;
33
+ export declare const runNetworkOnly: () => Promise<void>;
34
+ export interface IGlobalContextFoundation {
35
+ name: string;
36
+ context?: object;
37
+ providers?: MoonwallProvider[];
38
+ nodes?: {
39
+ name?: string;
40
+ cmd: string;
41
+ args: string[];
42
+ launch: boolean;
43
+ }[];
44
+ foundationType: FoundationType;
45
+ }
46
+ //# sourceMappingURL=globalContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"globalContext.d.ts","sourceRoot":"","sources":["../../../src/cli/lib/globalContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,iBAAiB,EAEjB,cAAc,EACd,eAAe,EACf,cAAc,EACd,mBAAmB,EACnB,gBAAgB,EAEjB,iCAAiC;AAGlC,OAAe,EAAE,KAAK,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,MAAM,MAAM,WAAW,CAAC;AAC/B,OAAO,EAAE,YAAY,EAAkB,MAAM,oBAAoB,CAAC;AAElE,OAAO,GAAG,MAAM,UAAU,CAAC;AAoC3B,qBAAa,eAAe;IAC1B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAA8B;IACrD,UAAU,UAAS;IACnB,WAAW,EAAG,mBAAmB,CAAC;IAClC,SAAS,EAAE,iBAAiB,EAAE,CAAC;IAC/B,KAAK,EAAE,CAAC,YAAY,GAAG,MAAM,CAAC,SAAS,CAAC,EAAE,CAAC;IAC3C,UAAU,EAAE,cAAc,CAAC;IAC3B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC;IACvB,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,OAAO,CAAC,mBAAmB,CAA+B;gBAE9C,MAAM,EAAE,cAAc,EAAE,OAAO,CAAC,EAAE,eAAe;IAUhD,eAAe;YAyBd,YAAY;YAmBZ,SAAS;YA2BT,cAAc;YAed,gBAAgB;YAgBhB,kBAAkB;IAwOnB,YAAY;IAkIZ,kBAAkB,CAAC,MAAM,UAAQ,GAAG,OAAO,CAAC,eAAe,CAAC;YA8F3D,0BAA0B;IA4D3B,UAAU,CAAC,YAAY,CAAC,EAAE,MAAM;WA2EzB,UAAU,CAC5B,MAAM,CAAC,EAAE,cAAc,EACvB,OAAO,CAAC,EAAE,eAAe,EACzB,KAAK,UAAQ,GACZ,OAAO,CAAC,eAAe,CAAC;WAgBP,OAAO,CAAC,MAAM,CAAC,EAAE,MAAM;CA8F5C;AAED,eAAO,MAAM,cAAc,GAAU,UAAU,eAAe,6BAM7D,CAAC;AAEF,eAAO,MAAM,cAAc,qBAI1B,CAAC;AAEF,MAAM,WAAW,wBAAwB;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,gBAAgB,EAAE,CAAC;IAC/B,KAAK,CAAC,EAAE;QACN,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,GAAG,EAAE,MAAM,CAAC;QACZ,IAAI,EAAE,MAAM,EAAE,CAAC;QACf,MAAM,EAAE,OAAO,CAAC;KACjB,EAAE,CAAC;IACJ,cAAc,EAAE,cAAc,CAAC;CAChC"}