alchemy 2.0.0-beta.70 → 2.0.0-beta.71

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 (299) hide show
  1. package/LICENSE +201 -0
  2. package/NOTICE +5 -0
  3. package/README.md +3 -1
  4. package/THIRD_PARTY_LICENSES.md +127 -0
  5. package/bin/exec.js +25 -9
  6. package/bin/exec.js.map +1 -1
  7. package/lib/AWS/DataZone/Domain.d.ts.map +1 -1
  8. package/lib/AWS/DataZone/Domain.js +7 -7
  9. package/lib/AWS/DataZone/Domain.js.map +1 -1
  10. package/lib/AWS/EC2/InternetGateway.d.ts.map +1 -1
  11. package/lib/AWS/EC2/InternetGateway.js +14 -16
  12. package/lib/AWS/EC2/InternetGateway.js.map +1 -1
  13. package/lib/AWS/EC2/LingeringEnis.d.ts +2 -2
  14. package/lib/AWS/EC2/LingeringEnis.d.ts.map +1 -1
  15. package/lib/AWS/EC2/LingeringEnis.js +9 -7
  16. package/lib/AWS/EC2/LingeringEnis.js.map +1 -1
  17. package/lib/AWS/RDSData/Marshall.d.ts +23 -0
  18. package/lib/AWS/RDSData/Marshall.d.ts.map +1 -0
  19. package/lib/AWS/RDSData/Marshall.js +87 -0
  20. package/lib/AWS/RDSData/Marshall.js.map +1 -0
  21. package/lib/AWS/RDSData/index.d.ts +1 -0
  22. package/lib/AWS/RDSData/index.d.ts.map +1 -1
  23. package/lib/AWS/RDSData/index.js +1 -0
  24. package/lib/AWS/RDSData/index.js.map +1 -1
  25. package/lib/AWS/ResourceGroups/Group.d.ts.map +1 -1
  26. package/lib/AWS/ResourceGroups/Group.js +3 -1
  27. package/lib/AWS/ResourceGroups/Group.js.map +1 -1
  28. package/lib/AWS/S3Tables/Namespace.d.ts.map +1 -1
  29. package/lib/AWS/S3Tables/Namespace.js +3 -1
  30. package/lib/AWS/S3Tables/Namespace.js.map +1 -1
  31. package/lib/AWS/S3Tables/TableBucket.d.ts.map +1 -1
  32. package/lib/AWS/S3Tables/TableBucket.js +8 -2
  33. package/lib/AWS/S3Tables/TableBucket.js.map +1 -1
  34. package/lib/AWS/S3Vectors/VectorBucket.d.ts.map +1 -1
  35. package/lib/AWS/S3Vectors/VectorBucket.js +6 -1
  36. package/lib/AWS/S3Vectors/VectorBucket.js.map +1 -1
  37. package/lib/AWS/Website/cfcode.d.ts.map +1 -1
  38. package/lib/AWS/Website/cfcode.js +2 -0
  39. package/lib/AWS/Website/cfcode.js.map +1 -1
  40. package/lib/Apply.d.ts.map +1 -1
  41. package/lib/Apply.js +22 -8
  42. package/lib/Apply.js.map +1 -1
  43. package/lib/Auth/AuthProvider.d.ts.map +1 -1
  44. package/lib/Auth/AuthProvider.js +1 -1
  45. package/lib/Auth/AuthProvider.js.map +1 -1
  46. package/lib/Bundle/Bundle.js +2 -2
  47. package/lib/Bundle/Bundle.js.map +1 -1
  48. package/lib/Cli/commands/cloudflare.js +1 -1
  49. package/lib/Cli/commands/cloudflare.js.map +1 -1
  50. package/lib/Cli/commands/logs.d.ts.map +1 -1
  51. package/lib/Cli/commands/logs.js +2 -1
  52. package/lib/Cli/commands/logs.js.map +1 -1
  53. package/lib/Cli/commands/nuke.js +1 -1
  54. package/lib/Cli/commands/nuke.js.map +1 -1
  55. package/lib/Cli/commands/tail.d.ts.map +1 -1
  56. package/lib/Cli/commands/tail.js +2 -1
  57. package/lib/Cli/commands/tail.js.map +1 -1
  58. package/lib/Cloudflare/AI/LanguageModel.js +1 -1
  59. package/lib/Cloudflare/AI/LanguageModel.js.map +1 -1
  60. package/lib/Cloudflare/Access.js +1 -1
  61. package/lib/Cloudflare/Access.js.map +1 -1
  62. package/lib/Cloudflare/Containers/ContainerBundle.d.ts +1 -1
  63. package/lib/Cloudflare/Containers/ContainerBundle.js +1 -1
  64. package/lib/Cloudflare/Containers/ContainerProvider.d.ts.map +1 -1
  65. package/lib/Cloudflare/Containers/ContainerProvider.js +24 -2
  66. package/lib/Cloudflare/Containers/ContainerProvider.js.map +1 -1
  67. package/lib/Cloudflare/Containers/LocalContainerProvider.d.ts +1 -1
  68. package/lib/Cloudflare/Containers/LocalContainerProvider.js +1 -1
  69. package/lib/Cloudflare/D1/Database.d.ts +2 -2
  70. package/lib/Cloudflare/D1/Database.d.ts.map +1 -1
  71. package/lib/Cloudflare/D1/LocalD1Gateway.d.ts +3 -3
  72. package/lib/Cloudflare/D1/LocalD1Gateway.d.ts.map +1 -1
  73. package/lib/Cloudflare/D1/LocalD1Gateway.js +3 -3
  74. package/lib/Cloudflare/D1/LocalD1Gateway.js.map +1 -1
  75. package/lib/Cloudflare/KV/LocalKVGateway.js +2 -2
  76. package/lib/Cloudflare/KV/LocalKVGateway.js.map +1 -1
  77. package/lib/Cloudflare/LocalGateway.d.ts +1 -1
  78. package/lib/Cloudflare/LocalGateway.d.ts.map +1 -1
  79. package/lib/Cloudflare/LocalGateway.js +1 -1
  80. package/lib/Cloudflare/LocalGateway.js.map +1 -1
  81. package/lib/Cloudflare/LocalRuntime.d.ts +1 -1
  82. package/lib/Cloudflare/LocalRuntime.d.ts.map +1 -1
  83. package/lib/Cloudflare/LocalRuntime.js +5 -4
  84. package/lib/Cloudflare/LocalRuntime.js.map +1 -1
  85. package/lib/Cloudflare/Queues/Consumer.d.ts +22 -5
  86. package/lib/Cloudflare/Queues/Consumer.d.ts.map +1 -1
  87. package/lib/Cloudflare/Queues/Consumer.js +129 -38
  88. package/lib/Cloudflare/Queues/Consumer.js.map +1 -1
  89. package/lib/Cloudflare/Queues/Queue.d.ts +4 -3
  90. package/lib/Cloudflare/Queues/Queue.d.ts.map +1 -1
  91. package/lib/Cloudflare/Queues/Queue.js +115 -6
  92. package/lib/Cloudflare/Queues/Queue.js.map +1 -1
  93. package/lib/Cloudflare/R2/LocalR2Gateway.js +2 -2
  94. package/lib/Cloudflare/R2/LocalR2Gateway.js.map +1 -1
  95. package/lib/Cloudflare/SecretsStore/LocalSecretsStoreGateway.d.ts +4 -4
  96. package/lib/Cloudflare/SecretsStore/LocalSecretsStoreGateway.d.ts.map +1 -1
  97. package/lib/Cloudflare/SecretsStore/LocalSecretsStoreGateway.js +2 -2
  98. package/lib/Cloudflare/SecretsStore/LocalSecretsStoreGateway.js.map +1 -1
  99. package/lib/Cloudflare/SecretsStore/Secret.d.ts +2 -2
  100. package/lib/Cloudflare/SecretsStore/Secret.d.ts.map +1 -1
  101. package/lib/Cloudflare/StateStore/Api.js +7 -0
  102. package/lib/Cloudflare/StateStore/Api.js.map +1 -1
  103. package/lib/Cloudflare/Website/Astro.d.ts +19 -11
  104. package/lib/Cloudflare/Website/Astro.d.ts.map +1 -1
  105. package/lib/Cloudflare/Website/Astro.js +16 -9
  106. package/lib/Cloudflare/Website/Astro.js.map +1 -1
  107. package/lib/Cloudflare/Website/Nextjs.d.ts +7 -4
  108. package/lib/Cloudflare/Website/Nextjs.d.ts.map +1 -1
  109. package/lib/Cloudflare/Website/Nextjs.js +10 -8
  110. package/lib/Cloudflare/Website/Nextjs.js.map +1 -1
  111. package/lib/Cloudflare/Website/Nuxt.d.ts +5 -4
  112. package/lib/Cloudflare/Website/Nuxt.d.ts.map +1 -1
  113. package/lib/Cloudflare/Website/Nuxt.js +4 -3
  114. package/lib/Cloudflare/Website/Nuxt.js.map +1 -1
  115. package/lib/Cloudflare/Website/Octane.d.ts +4 -3
  116. package/lib/Cloudflare/Website/Octane.d.ts.map +1 -1
  117. package/lib/Cloudflare/Website/Octane.js +5 -4
  118. package/lib/Cloudflare/Website/Octane.js.map +1 -1
  119. package/lib/Cloudflare/Website/SvelteKit.d.ts +17 -10
  120. package/lib/Cloudflare/Website/SvelteKit.d.ts.map +1 -1
  121. package/lib/Cloudflare/Website/SvelteKit.js +9 -5
  122. package/lib/Cloudflare/Website/SvelteKit.js.map +1 -1
  123. package/lib/Cloudflare/Website/Waku.d.ts +20 -9
  124. package/lib/Cloudflare/Website/Waku.d.ts.map +1 -1
  125. package/lib/Cloudflare/Website/Waku.js +10 -4
  126. package/lib/Cloudflare/Website/Waku.js.map +1 -1
  127. package/lib/Cloudflare/Workers/Assets.d.ts +54 -1
  128. package/lib/Cloudflare/Workers/Assets.d.ts.map +1 -1
  129. package/lib/Cloudflare/Workers/Assets.js +60 -26
  130. package/lib/Cloudflare/Workers/Assets.js.map +1 -1
  131. package/lib/Cloudflare/Workers/LocalWorkerProvider.d.ts +2 -2
  132. package/lib/Cloudflare/Workers/LocalWorkerProvider.d.ts.map +1 -1
  133. package/lib/Cloudflare/Workers/LocalWorkerProvider.js +153 -49
  134. package/lib/Cloudflare/Workers/LocalWorkerProvider.js.map +1 -1
  135. package/lib/Cloudflare/Workers/RuntimeBindings.d.ts +3 -3
  136. package/lib/Cloudflare/Workers/RuntimeBindings.d.ts.map +1 -1
  137. package/lib/Cloudflare/Workers/RuntimeBindings.js +2 -2
  138. package/lib/Cloudflare/Workers/RuntimeBindings.js.map +1 -1
  139. package/lib/Cloudflare/Workers/Source.d.ts +1 -1
  140. package/lib/Cloudflare/Workers/Source.d.ts.map +1 -1
  141. package/lib/Cloudflare/Workers/Source.js +1 -1
  142. package/lib/Cloudflare/Workers/Source.js.map +1 -1
  143. package/lib/Cloudflare/Workers/Sources/Rolldown.d.ts.map +1 -1
  144. package/lib/Cloudflare/Workers/Sources/Rolldown.js +3 -4
  145. package/lib/Cloudflare/Workers/Sources/Rolldown.js.map +1 -1
  146. package/lib/Cloudflare/Workers/Sources/Vite.d.ts +1 -1
  147. package/lib/Cloudflare/Workers/Sources/Vite.d.ts.map +1 -1
  148. package/lib/Cloudflare/Workers/Sources/Vite.js +36 -17
  149. package/lib/Cloudflare/Workers/Sources/Vite.js.map +1 -1
  150. package/lib/Cloudflare/Workers/ViteChild.d.ts.map +1 -1
  151. package/lib/Cloudflare/Workers/ViteChild.js +6 -0
  152. package/lib/Cloudflare/Workers/ViteChild.js.map +1 -1
  153. package/lib/Cloudflare/Workers/ViteChild.shared.d.ts +1 -1
  154. package/lib/Cloudflare/Workers/ViteChild.shared.d.ts.map +1 -1
  155. package/lib/Cloudflare/Workers/ViteChildRunner.js +5 -10
  156. package/lib/Cloudflare/Workers/ViteChildRunner.js.map +1 -1
  157. package/lib/Cloudflare/Workers/Worker.d.ts +11 -4
  158. package/lib/Cloudflare/Workers/Worker.d.ts.map +1 -1
  159. package/lib/Cloudflare/Workers/Worker.js.map +1 -1
  160. package/lib/Cloudflare/Workers/WorkerProvider.d.ts +1 -1
  161. package/lib/Cloudflare/Workers/WorkerProvider.d.ts.map +1 -1
  162. package/lib/Cloudflare/Workers/WorkerProvider.js +12 -2
  163. package/lib/Cloudflare/Workers/WorkerProvider.js.map +1 -1
  164. package/lib/Docker/Docker.d.ts.map +1 -1
  165. package/lib/Docker/Docker.js +6 -2
  166. package/lib/Docker/Docker.js.map +1 -1
  167. package/lib/Drizzle/{DurableObject.d.ts → Cloudflare.d.ts} +2 -1
  168. package/lib/Drizzle/Cloudflare.d.ts.map +1 -0
  169. package/lib/Drizzle/{DurableObject.js → Cloudflare.js} +2 -1
  170. package/lib/Drizzle/Cloudflare.js.map +1 -0
  171. package/lib/Drizzle/MySQL.d.ts +2 -2
  172. package/lib/Drizzle/MySQL.d.ts.map +1 -1
  173. package/lib/Drizzle/MySQL.js +5 -3
  174. package/lib/Drizzle/MySQL.js.map +1 -1
  175. package/lib/Drizzle/Postgres.d.ts +1 -1
  176. package/lib/Drizzle/Postgres.d.ts.map +1 -1
  177. package/lib/Drizzle/Postgres.js +4 -2
  178. package/lib/Drizzle/Postgres.js.map +1 -1
  179. package/lib/Drizzle/index.d.ts +0 -3
  180. package/lib/Drizzle/index.d.ts.map +1 -1
  181. package/lib/Drizzle/index.js +5 -3
  182. package/lib/Drizzle/index.js.map +1 -1
  183. package/lib/Neon/Migrations.d.ts.map +1 -1
  184. package/lib/Neon/Migrations.js +1 -5
  185. package/lib/Neon/Migrations.js.map +1 -1
  186. package/lib/PhysicalName.d.ts +8 -0
  187. package/lib/PhysicalName.d.ts.map +1 -1
  188. package/lib/PhysicalName.js +5 -2
  189. package/lib/PhysicalName.js.map +1 -1
  190. package/lib/Plan.d.ts.map +1 -1
  191. package/lib/Plan.js +16 -9
  192. package/lib/Plan.js.map +1 -1
  193. package/lib/ProviderMode.d.ts +45 -0
  194. package/lib/ProviderMode.d.ts.map +1 -1
  195. package/lib/ProviderMode.js +51 -0
  196. package/lib/ProviderMode.js.map +1 -1
  197. package/lib/SQL/ConnectionSource.d.ts +45 -0
  198. package/lib/SQL/ConnectionSource.d.ts.map +1 -0
  199. package/lib/SQL/ConnectionSource.js +51 -0
  200. package/lib/SQL/ConnectionSource.js.map +1 -0
  201. package/lib/SQL/MySQLDriver.d.ts +21 -0
  202. package/lib/SQL/MySQLDriver.d.ts.map +1 -0
  203. package/lib/SQL/MySQLDriver.js +31 -0
  204. package/lib/SQL/MySQLDriver.js.map +1 -0
  205. package/lib/SQL/PostgresDriver.d.ts +21 -0
  206. package/lib/SQL/PostgresDriver.d.ts.map +1 -0
  207. package/lib/SQL/PostgresDriver.js +29 -0
  208. package/lib/SQL/PostgresDriver.js.map +1 -0
  209. package/lib/State/HttpStateApi.d.ts +11 -11
  210. package/lib/State/LocalState.d.ts.map +1 -1
  211. package/lib/State/LocalState.js +17 -1
  212. package/lib/State/LocalState.js.map +1 -1
  213. package/lib/State/ResourceState.d.ts +6 -2
  214. package/lib/State/ResourceState.d.ts.map +1 -1
  215. package/lib/State/StateEncoding.d.ts +8 -0
  216. package/lib/State/StateEncoding.d.ts.map +1 -1
  217. package/lib/State/StateEncoding.js +38 -0
  218. package/lib/State/StateEncoding.js.map +1 -1
  219. package/lib/Sync.d.ts.map +1 -1
  220. package/lib/Sync.js +4 -2
  221. package/lib/Sync.js.map +1 -1
  222. package/lib/Test/Alchemy.d.ts.map +1 -1
  223. package/lib/Test/Alchemy.js +24 -14
  224. package/lib/Test/Alchemy.js.map +1 -1
  225. package/lib/Test/Core.d.ts +25 -8
  226. package/lib/Test/Core.d.ts.map +1 -1
  227. package/lib/Test/Core.js +24 -7
  228. package/lib/Test/Core.js.map +1 -1
  229. package/package.json +49 -40
  230. package/src/AWS/DataZone/Domain.ts +15 -13
  231. package/src/AWS/EC2/InternetGateway.ts +28 -32
  232. package/src/AWS/EC2/LingeringEnis.ts +11 -9
  233. package/src/AWS/RDSData/Marshall.ts +106 -0
  234. package/src/AWS/RDSData/index.ts +1 -0
  235. package/src/AWS/ResourceGroups/Group.ts +5 -1
  236. package/src/AWS/S3Tables/Namespace.ts +3 -1
  237. package/src/AWS/S3Tables/TableBucket.ts +8 -2
  238. package/src/AWS/S3Vectors/VectorBucket.ts +6 -1
  239. package/src/AWS/Website/cfcode.ts +2 -0
  240. package/src/Apply.ts +22 -9
  241. package/src/Auth/AuthProvider.ts +4 -7
  242. package/src/Bundle/Bundle.ts +2 -2
  243. package/src/Cli/commands/cloudflare.ts +1 -1
  244. package/src/Cli/commands/logs.ts +2 -1
  245. package/src/Cli/commands/nuke.ts +1 -1
  246. package/src/Cli/commands/tail.ts +2 -1
  247. package/src/Cloudflare/AI/LanguageModel.ts +3 -0
  248. package/src/Cloudflare/Access.ts +1 -1
  249. package/src/Cloudflare/Containers/ContainerBundle.ts +1 -1
  250. package/src/Cloudflare/Containers/ContainerProvider.ts +35 -5
  251. package/src/Cloudflare/Containers/LocalContainerProvider.ts +1 -1
  252. package/src/Cloudflare/D1/Database.ts +1 -1
  253. package/src/Cloudflare/D1/LocalD1Gateway.ts +4 -4
  254. package/src/Cloudflare/KV/LocalKVGateway.ts +2 -2
  255. package/src/Cloudflare/LocalGateway.ts +1 -1
  256. package/src/Cloudflare/LocalRuntime.ts +6 -4
  257. package/src/Cloudflare/Queues/Consumer.ts +183 -45
  258. package/src/Cloudflare/Queues/Queue.ts +157 -5
  259. package/src/Cloudflare/R2/LocalR2Gateway.ts +2 -2
  260. package/src/Cloudflare/SecretsStore/LocalSecretsStoreGateway.ts +2 -2
  261. package/src/Cloudflare/SecretsStore/Secret.ts +1 -1
  262. package/src/Cloudflare/StateStore/Api.ts +7 -0
  263. package/src/Cloudflare/Website/Astro.ts +20 -12
  264. package/src/Cloudflare/Website/Nextjs.ts +13 -8
  265. package/src/Cloudflare/Website/Nuxt.ts +6 -5
  266. package/src/Cloudflare/Website/Octane.ts +6 -4
  267. package/src/Cloudflare/Website/SvelteKit.ts +18 -11
  268. package/src/Cloudflare/Website/Waku.ts +21 -10
  269. package/src/Cloudflare/Workers/Assets.ts +122 -20
  270. package/src/Cloudflare/Workers/LocalWorkerProvider.ts +228 -81
  271. package/src/Cloudflare/Workers/RuntimeBindings.ts +3 -3
  272. package/src/Cloudflare/Workers/Source.ts +2 -2
  273. package/src/Cloudflare/Workers/Sources/Rolldown.ts +3 -4
  274. package/src/Cloudflare/Workers/Sources/Vite.ts +46 -24
  275. package/src/Cloudflare/Workers/ViteChild.shared.ts +1 -1
  276. package/src/Cloudflare/Workers/ViteChild.ts +6 -0
  277. package/src/Cloudflare/Workers/ViteChildRunner.ts +5 -10
  278. package/src/Cloudflare/Workers/Worker.ts +26 -6
  279. package/src/Cloudflare/Workers/WorkerProvider.ts +19 -2
  280. package/src/Docker/Docker.ts +17 -11
  281. package/src/Drizzle/{DurableObject.ts → Cloudflare.ts} +1 -0
  282. package/src/Drizzle/MySQL.ts +13 -3
  283. package/src/Drizzle/Postgres.ts +10 -2
  284. package/src/Drizzle/index.ts +6 -3
  285. package/src/Neon/Migrations.ts +1 -10
  286. package/src/PhysicalName.ts +17 -1
  287. package/src/Plan.ts +20 -9
  288. package/src/ProviderMode.ts +56 -0
  289. package/src/SQL/ConnectionSource.ts +101 -0
  290. package/src/SQL/MySQLDriver.ts +49 -0
  291. package/src/SQL/PostgresDriver.ts +45 -0
  292. package/src/State/LocalState.ts +24 -0
  293. package/src/State/ResourceState.ts +6 -2
  294. package/src/State/StateEncoding.ts +37 -0
  295. package/src/Sync.ts +4 -2
  296. package/src/Test/Alchemy.ts +17 -6
  297. package/src/Test/Core.ts +42 -15
  298. package/lib/Drizzle/DurableObject.d.ts.map +0 -1
  299. package/lib/Drizzle/DurableObject.js.map +0 -1
package/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
package/NOTICE ADDED
@@ -0,0 +1,5 @@
1
+ Alchemy
2
+ Copyright 2026 Functionless Corp.
3
+
4
+ This product includes software developed by third parties. See
5
+ THIRD_PARTY_LICENSES.md for attribution and license details.
package/README.md CHANGED
@@ -97,4 +97,6 @@ dependencies or breaking conventions.
97
97
 
98
98
  ## License
99
99
 
100
- Apache-2.0
100
+ Licensed under the [Apache License 2.0](./LICENSE). See
101
+ [Third-Party Licenses](./THIRD_PARTY_LICENSES.md) for code incorporated from
102
+ upstream projects.
@@ -0,0 +1,127 @@
1
+ # Third-Party Licenses
2
+
3
+ Alchemy is licensed under the Apache License 2.0. Portions of the repository
4
+ are derived from the projects listed below and remain subject to their
5
+ respective license notices.
6
+
7
+ ## Astro
8
+
9
+ Portions of `packages/cloudflare-frameworks/src/astro` are derived from
10
+ `@astrojs/cloudflare`.
11
+
12
+ Copyright (c) 2021 Fred K. Schott
13
+
14
+ MIT License
15
+
16
+ Permission is hereby granted, free of charge, to any person obtaining a copy
17
+ of this software and associated documentation files (the "Software"), to deal
18
+ in the Software without restriction, including without limitation the rights
19
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
20
+ copies of the Software, and to permit persons to whom the Software is
21
+ furnished to do so, subject to the following conditions:
22
+
23
+ The above copyright notice and this permission notice shall be included in all
24
+ copies or substantial portions of the Software.
25
+
26
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
27
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
28
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
29
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
30
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
31
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
32
+ SOFTWARE.
33
+
34
+ ## SvelteKit
35
+
36
+ Portions of `packages/cloudflare-frameworks/src/sveltekit` are derived from
37
+ `@sveltejs/adapter-cloudflare`.
38
+
39
+ Copyright (c) 2020 SvelteKit contributors
40
+
41
+ The SvelteKit portions are provided under the MIT License reproduced in the
42
+ Astro section above.
43
+
44
+ ## Waku
45
+
46
+ Portions of `packages/cloudflare-frameworks/src/waku` are derived from Waku.
47
+
48
+ Copyright (c) 2023 Daishi Kato
49
+
50
+ The Waku portions are provided under the MIT License reproduced in the Astro
51
+ section above.
52
+
53
+ ## Cloudflare Workers SDK and Miniflare
54
+
55
+ Portions of `packages/cloudflare-runtime`, including the vendored
56
+ `workers-shared` and `workflows-shared` source trees and local binding
57
+ implementations adapted from Miniflare, are derived from Cloudflare's
58
+ `workers-sdk` repository. Alchemy uses these portions under the MIT option of
59
+ the upstream `MIT OR Apache-2.0` license.
60
+
61
+ Copyright (c) 2020 Cloudflare, Inc. <wrangler@cloudflare.com>
62
+
63
+ The Cloudflare Workers SDK and Miniflare portions are provided under the MIT
64
+ License reproduced in the Astro section above.
65
+
66
+ ## OpenNext for Cloudflare
67
+
68
+ Portions of `packages/cloudflare-frameworks/src/nextjs`, including the build
69
+ runner and development-context integration, are derived from OpenNext for
70
+ Cloudflare.
71
+
72
+ Copyright (c) 2020 Cloudflare, Inc.
73
+
74
+ The OpenNext portions are provided under the MIT License reproduced in the
75
+ Astro section above.
76
+
77
+ ## SST
78
+
79
+ `packages/alchemy/src/AWS/Website/cfcode.ts` contains CloudFront Function code
80
+ ported from SST's Router component.
81
+
82
+ Copyright (c) 2024 SST
83
+
84
+ The SST portions are provided under the MIT License reproduced in the Astro
85
+ section above.
86
+
87
+ ## node-sanitize-filename
88
+
89
+ Path-sanitization expressions in
90
+ `packages/cloudflare-runtime/src/core/internal/shared.worker.ts` are adapted
91
+ from `node-sanitize-filename` and used under its ISC license option.
92
+
93
+ Copyright Parsha Pourkhomami
94
+
95
+ Permission to use, copy, modify, and/or distribute this software for any
96
+ purpose with or without fee is hereby granted, provided that the above
97
+ copyright notice and this permission notice appear in all copies.
98
+
99
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
100
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
101
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
102
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
103
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
104
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
105
+ PERFORMANCE OF THIS SOFTWARE.
106
+
107
+ ## SQLite
108
+
109
+ The D1 simulator contains a TypeScript port of SQLite shell quoting logic.
110
+ SQLite's deliverable source code, including its command-line interface, has
111
+ been dedicated to the public domain. See <https://www.sqlite.org/copyright.html>.
112
+
113
+ ## Upstream source references
114
+
115
+ - Astro: <https://github.com/withastro/astro>
116
+ - SvelteKit: <https://github.com/sveltejs/kit>
117
+ - Waku: <https://github.com/wakujs/waku>
118
+ - Cloudflare Workers SDK: <https://github.com/cloudflare/workers-sdk>
119
+ - OpenNext for Cloudflare: <https://github.com/opennextjs/opennextjs-cloudflare>
120
+ - SST: <https://github.com/sst/sst>
121
+ - node-sanitize-filename: <https://github.com/parshap/node-sanitize-filename>
122
+ - SQLite: <https://github.com/sqlite/sqlite>
123
+
124
+ The external `.vendor` Git submodules are separate works governed by the
125
+ license files in their respective repositories. This notice covers code copied
126
+ or adapted into the Alchemy repository; it does not replace the license
127
+ documentation within those submodules.
package/bin/exec.js CHANGED
@@ -178,7 +178,7 @@ var init_AuthProvider$1 = __esm({ "lib/Auth/AuthProvider.js": (() => {
178
178
  ]);
179
179
  INTERACTIVE_METHODS = new Set(["login", "configure"]);
180
180
  interactiveMutex = Semaphore.makeUnsafe(1);
181
- AuthError = class extends Schema.TaggedErrorClass()("AuthError", {
181
+ AuthError = class extends Schema.TaggedError()("AuthError", {
182
182
  message: Schema.String,
183
183
  cause: Schema.optional(Schema.Defect())
184
184
  }) {};
@@ -440,10 +440,18 @@ var init_Provider = __esm({ "lib/Provider.js": (() => {
440
440
 
441
441
  //#endregion
442
442
  //#region lib/ProviderMode.js
443
- var ProviderModePolicy, defaultProviderMode;
443
+ var ProviderModePolicy, LOCAL_ID_PREFIX, hasLocalIdentity, stampedMode, defaultProviderMode;
444
444
  var init_ProviderMode = __esm({ "lib/ProviderMode.js": (() => {
445
445
  init_AlchemyContext();
446
446
  ProviderModePolicy = EffectContext.Reference("ProviderModePolicy", { defaultValue: () => void 0 });
447
+ LOCAL_ID_PREFIX = "dev:";
448
+ hasLocalIdentity = (value) => {
449
+ if (typeof value === "string") return value.startsWith(LOCAL_ID_PREFIX);
450
+ if (Array.isArray(value)) return value.some(hasLocalIdentity);
451
+ if (typeof value === "object" && value !== null) return Object.values(value).some(hasLocalIdentity);
452
+ return false;
453
+ };
454
+ stampedMode = (row) => row.providerMode ?? (hasLocalIdentity(row.attr) ? "local" : "live");
447
455
  defaultProviderMode = Effect.gen(function* () {
448
456
  if (yield* ProviderModePolicy) return "live";
449
457
  const ctx = yield* Effect.serviceOption(AlchemyContext);
@@ -1596,11 +1604,14 @@ const make = (stack, options$7 = {}) => Effect.gen(function* () {
1596
1604
  });
1597
1605
  /**
1598
1606
  * Has this resource switched provider modes since it was last
1599
- * reconciled? Rows without a persisted mode (legacy rows, or rows
1600
- * written by a mode-agnostic provider) are assumed to already be in
1601
- * the current run's mode no replacement churn.
1607
+ * reconciled? Rows without a persisted mode were written by a
1608
+ * pre-provider-mode engine (or a provider that only became dual-mode
1609
+ * later) their physical resource is LIVE unless its attrs carry a
1610
+ * `dev:` identity marker proving it was reconciled locally (see
1611
+ * {@link stampedMode}). A dev run replaces unstamped live rows exactly
1612
+ * like stamped live rows; live runs replace unstamped marker rows.
1602
1613
  */
1603
- const hasModeSwitched = (mode, oldState) => mode !== void 0 && oldState?.providerMode !== void 0 && oldState.providerMode !== mode;
1614
+ const hasModeSwitched = (mode, oldState) => mode !== void 0 && oldState !== void 0 && stampedMode(oldState) !== mode;
1604
1615
  const resourceFqns = yield* state.list({
1605
1616
  stack: stackName,
1606
1617
  stage: stage$1
@@ -2177,7 +2188,7 @@ const make = (stack, options$7 = {}) => Effect.gen(function* () {
2177
2188
  if (migratedRowFqns.has(fqn)) return;
2178
2189
  const { logicalId } = parseFqn(fqn);
2179
2190
  const resourceType = oldState.resourceType;
2180
- const providerOption = yield* tryFindProviderByType(resourceType, oldState.providerMode);
2191
+ const providerOption = yield* tryFindProviderByType(resourceType, stampedMode(oldState));
2181
2192
  if (Option.isNone(providerOption)) return yield* Effect.die(missingProviderError(resourceType, fqn));
2182
2193
  return [fqn, {
2183
2194
  action: "delete",
@@ -2269,6 +2280,7 @@ init_Diff();
2269
2280
  init_InstanceId();
2270
2281
  init_Output();
2271
2282
  init_Provider();
2283
+ init_ProviderMode();
2272
2284
  init_Stack();
2273
2285
  init_Stage();
2274
2286
  init_sha256();
@@ -2403,6 +2415,10 @@ const executeNode = (fqn, node, tracker, ready, readyStable, terminalStatuses, s
2403
2415
  status,
2404
2416
  providerMode: node.mode
2405
2417
  });
2418
+ if (node.mode === "local") {
2419
+ const url = tracker[fqn]?.output?.url;
2420
+ if (typeof url === "string" && url.length > 0) yield* scopedSession.note(`ready at ${url}`);
2421
+ }
2406
2422
  if (inCycle) return;
2407
2423
  yield* session.emit({
2408
2424
  kind: "status-change",
@@ -2682,7 +2698,7 @@ const executeNode = (fqn, node, tracker, ready, readyStable, terminalStatuses, s
2682
2698
  else replState = node.state;
2683
2699
  const deleteOldGenerations = (old) => Effect.gen(function* () {
2684
2700
  const retain = node.resource.RemovalPolicy === "retain";
2685
- if (old.attr !== void 0 && !retain) yield* (yield* findProviderByType(node.resource.Type, old.providerMode)).delete({
2701
+ if (old.attr !== void 0 && !retain) yield* (yield* findProviderByType(node.resource.Type, stampedMode(old))).delete({
2686
2702
  id: logicalId,
2687
2703
  fqn,
2688
2704
  instanceId: old.instanceId,
@@ -3121,7 +3137,7 @@ const collectGarbage = Effect.fn(function* (plan, session) {
3121
3137
  downstream: node.old.downstream,
3122
3138
  props: node.old.props,
3123
3139
  attr: node.old.attr,
3124
- provider: yield* tryFindProviderByType(node.old.resourceType, node.old.providerMode).pipe(Effect.flatMap(Option.match({
3140
+ provider: yield* tryFindProviderByType(node.old.resourceType, stampedMode(node.old)).pipe(Effect.flatMap(Option.match({
3125
3141
  onNone: () => Effect.die(missingProviderError(node.old.resourceType, node.fqn)),
3126
3142
  onSome: Effect.succeed
3127
3143
  }))),