@akterjs/cli 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/{Argument-D81dqizB.mjs → Argument-BKjmk8CZ.mjs} +1 -1
- package/dist/{ChildProcess-BCIwxPGc.mjs → ChildProcess-UWPy-kPn.mjs} +2 -2
- package/dist/{CliError-Cf5xqkkj.mjs → CliError-CphGZMfO.mjs} +2 -2
- package/dist/{Command-Dzq9KM-h.mjs → Command-D3hF_i6F.mjs} +8 -8
- package/dist/{Config-B6OND9WR.mjs → Config-DEUiBxw4.mjs} +2 -2
- package/dist/{Console-BKHUkH6a.mjs → Console-DY7H086H.mjs} +1 -1
- package/dist/{Digest-CBd3uv5B.mjs → Digest-CnBYV3Oh.mjs} +2 -2
- package/dist/{Effect-CKFpqbmw.mjs → Effect-CFIPV2Jg.mjs} +44 -4
- package/dist/{FileSystem-4pPcEb_i.mjs → FileSystem-iEC-kUB-.mjs} +2 -2
- package/dist/{HttpClientError-BUeMWx70.mjs → HttpClientError-BVd83gxQ.mjs} +1 -1
- package/dist/{HttpClientResponse-D5ZKICVV.mjs → HttpClientResponse-CifutXCF.mjs} +4 -4
- package/dist/{Path-Djdv_eF5.mjs → Path-BRnAx8py.mjs} +1 -1
- package/dist/{Queue-CO5UQ6os.mjs → Queue-CyWN-MDp.mjs} +1 -1
- package/dist/{Ref-BIPOxJNH.mjs → Ref-CX3ghLq6.mjs} +1 -1
- package/dist/{Runtime-BInIAwK3.mjs → Runtime-CyqeMpLX.mjs} +1 -1
- package/dist/{Schema-MiKt5K1v.mjs → Schema-O3QUdX3B.mjs} +1 -1
- package/dist/{SecureRandom-B_U4ysO3.mjs → SecureRandom-DYpl-YDn.mjs} +2 -2
- package/dist/{Semaphore-DOVJ4ZGS.mjs → Semaphore-DHYKAQSv.mjs} +1 -1
- package/dist/{Stdio-KylmOBX_.mjs → Stdio-7l23nD6W.mjs} +1 -1
- package/dist/{Stream-bK9QIETN.mjs → Stream-BeqiANg7.mjs} +3 -3
- package/dist/{TerminalCapabilities-w_44MAca.mjs → TerminalCapabilities-R2LPyCNs.mjs} +3 -3
- package/dist/{WebCrypto-ZI_GNVlw.mjs → WebCrypto-C_95GMdw.mjs} +1 -1
- package/dist/{actor-call.service-CGM_vD9u.mjs → actor-call.service-vJm8gKjI.mjs} +15 -15
- package/dist/{actor-client.adapter-Coem7gF1.mjs → actor-client.adapter-CfKUj7Gi.mjs} +32 -16
- package/dist/{akter-program.config-Bhpa-tW7.mjs → akter-program.config-C-mFiZp1.mjs} +252 -39
- package/dist/akter.cli.mjs +1 -1
- package/dist/app-cli.config.mjs +4 -3
- package/dist/archive/akter-archive.schema.mjs +1 -1
- package/dist/archive/akter-archive.service.mjs +7 -7
- package/dist/archive/archive-cli.config.mjs +6 -6
- package/dist/archive/archive-invalid.errors.mjs +1 -1
- package/dist/archive/tar.pure.mjs +1 -1
- package/dist/archive/zstd.adapter.mjs +2 -2
- package/dist/bench/bench-report.pure.mjs +7 -2
- package/dist/bench/bench-runner.pure.mjs +40 -3
- package/dist/bench/bench.service.mjs +17 -14
- package/dist/{cli-runtime.layer-BqK2mmVL.mjs → cli-runtime.layer-Bwuqll8h.mjs} +13 -13
- package/dist/cli-runtime.layer.mjs +1 -1
- package/dist/{cloud-client.adapter-Cy1BjDbG.mjs → cloud-client.adapter-Ce4oyGNh.mjs} +94 -17
- package/dist/{cloud-client.adapter-DOVMoYAj.mjs → cloud-client.adapter-Dln8NW-9.mjs} +9 -9
- package/dist/command/akter-commands.config.mjs +2 -2
- package/dist/command/akter-program.config.mjs +1 -1
- package/dist/credentials/credentials.service.mjs +5 -5
- package/dist/credentials/keychain.adapter.mjs +3 -3
- package/dist/credentials/login.config.mjs +9 -9
- package/dist/deploy/auth/api-attempt.service.mjs +4 -4
- package/dist/deploy/auth/token-refresh.errors.mjs +1 -1
- package/dist/deploy/build-bundle.adapter.mjs +8 -8
- package/dist/deploy/cloud-client.adapter.mjs +1 -1
- package/dist/deploy/cloud-url.pure.mjs +2 -2
- package/dist/deploy/deploy-failed.errors.mjs +2 -2
- package/dist/deploy/deploy.service.mjs +6 -6
- package/dist/deploy/request-failure.pure.mjs +3 -3
- package/dist/docs/docs.config.mjs +1 -1
- package/dist/{docs.config-CWSzsV0h.mjs → docs.config-Dy0MFrKd.mjs} +9 -9
- package/dist/export/actor-export.service.mjs +10 -10
- package/dist/export/export-failed.errors.mjs +1 -1
- package/dist/export/export-failure.pure.mjs +14 -3
- package/dist/export/ordered-lines.pure.mjs +3 -3
- package/dist/export/ranged-download.pure.mjs +3 -3
- package/dist/export/snapshot-download.pure.mjs +3 -3
- package/dist/{hosted-runtime.layer-Cx3IPsEd.mjs → hosted-runtime.layer-BDXPqzSp.mjs} +128 -99
- package/dist/local/environment-cli.config.mjs +4 -4
- package/dist/local/local-cli.config.mjs +9 -9
- package/dist/logs/log-follow.config.mjs +2 -2
- package/dist/logs/log-follow.service.mjs +7 -7
- package/dist/logs/log-lines.pure.mjs +4 -4
- package/dist/{operation-input.pure-CS9iUhqK.mjs → operation-input.pure-B72BbxCG.mjs} +2 -2
- package/dist/operation-output.pure-ChUlePFj.mjs +120 -0
- package/dist/{operation-registry.pure-DVC8EDgj.mjs → operation-registry.pure-DeoTbR3J.mjs} +2 -2
- package/dist/registry/actor-call.service.mjs +1 -1
- package/dist/registry/actor-commands.config.mjs +6 -6
- package/dist/registry/approval.service.mjs +5 -5
- package/dist/registry/cloud-commands.config.mjs +3 -3
- package/dist/registry/cloud-served.pure.mjs +1 -1
- package/dist/registry/operation-call.service.mjs +42 -23
- package/dist/registry/operation-input.pure.mjs +1 -1
- package/dist/registry/operation-output.pure.mjs +1 -91
- package/dist/registry/served-command.config.mjs +6 -6
- package/dist/runner-exited.errors.mjs +2 -2
- package/dist/terminal/cli-exit.errors.mjs +2 -2
- package/dist/terminal/cli-failure.pure.mjs +7 -7
- package/dist/terminal/confirm.adapter.mjs +2 -2
- package/package.json +3 -3
|
@@ -5,7 +5,7 @@ const benchRunner = join([
|
|
|
5
5
|
"import { writeFileSync } from \"node:fs\";",
|
|
6
6
|
"import { arch, cpus, platform, release, totalmem } from \"node:os\";",
|
|
7
7
|
"import { createInterface } from \"node:readline\";",
|
|
8
|
-
"import { Cause, Effect, Exit, Layer, Option } from \"effect\";",
|
|
8
|
+
"import { Cause, Effect, Exit, Fiber, Layer, Option } from \"effect\";",
|
|
9
9
|
...typeScriptImports,
|
|
10
10
|
"",
|
|
11
11
|
"const config = JSON.parse(process.argv[2]);",
|
|
@@ -46,14 +46,51 @@ const benchRunner = join([
|
|
|
46
46
|
" samples.push([outcomeOf(exit), performance.now() - started]);",
|
|
47
47
|
" }",
|
|
48
48
|
" });",
|
|
49
|
+
"// --rate: an open loop. Steps start on a schedule, rate a second, whatever the answers; a step's latency counts from",
|
|
50
|
+
"// its scheduled start, so a slow server shows as latency and not as fewer steps. One that would pass --concurrency in",
|
|
51
|
+
"// flight doesn't start and counts as failed, so the run reports the server's ceiling and not the generator's queue.",
|
|
52
|
+
"const overCap = \"failed: over \" + config.concurrency + \" in flight\";",
|
|
53
|
+
"const openLoop = (session, deadline) =>",
|
|
54
|
+
" Effect.gen(function* () {",
|
|
55
|
+
" const fibers = [];",
|
|
56
|
+
" const started = performance.now();",
|
|
57
|
+
" let inFlight = 0;",
|
|
58
|
+
" for (let next = 0; started + (next * 1000) / config.rate < deadline; ) {",
|
|
59
|
+
" const now = performance.now();",
|
|
60
|
+
" for (let due = started + (next * 1000) / config.rate; due <= now && due < deadline; due = started + (++next * 1000) / config.rate) {",
|
|
61
|
+
" if (inFlight >= config.concurrency) {",
|
|
62
|
+
" samples.push([overCap, 0]);",
|
|
63
|
+
" continue;",
|
|
64
|
+
" }",
|
|
65
|
+
" inFlight += 1;",
|
|
66
|
+
" const scheduled = due;",
|
|
67
|
+
" const timed = Effect.exit(Effect.timeoutOption(workload.step(session), config.stepTimeoutMillis));",
|
|
68
|
+
" fibers.push(",
|
|
69
|
+
" yield* Effect.forkChild(",
|
|
70
|
+
" Effect.map(timed, (exit) => {",
|
|
71
|
+
" inFlight -= 1;",
|
|
72
|
+
" samples.push([outcomeOf(exit), performance.now() - scheduled]);",
|
|
73
|
+
" }),",
|
|
74
|
+
" ),",
|
|
75
|
+
" );",
|
|
76
|
+
" }",
|
|
77
|
+
" yield* Effect.sleep(1);",
|
|
78
|
+
" }",
|
|
79
|
+
" yield* Fiber.joinAll(fibers);",
|
|
80
|
+
" });",
|
|
49
81
|
"const opened = Effect.flatMap(Effect.timeoutOption(workload.open, config.stepTimeoutMillis), (session) =>",
|
|
50
82
|
" Option.isSome(session) ? Effect.succeed(session.value) : Effect.fail(new Error(\"open got no answer within \" + config.stepTimeoutMillis + \" ms\")),",
|
|
51
83
|
");",
|
|
52
84
|
"const run = Effect.gen(function* () {",
|
|
53
85
|
" const session = yield* opened;",
|
|
54
86
|
" const started = performance.now();",
|
|
55
|
-
" const
|
|
56
|
-
"
|
|
87
|
+
" const deadline = started + config.durationMillis;",
|
|
88
|
+
" if (config.rate === undefined) {",
|
|
89
|
+
" const workers = Array.from({ length: config.concurrency }, () => worker(session, deadline));",
|
|
90
|
+
" yield* Effect.all(workers, { concurrency: \"unbounded\", discard: true });",
|
|
91
|
+
" } else {",
|
|
92
|
+
" yield* openLoop(session, deadline);",
|
|
93
|
+
" }",
|
|
57
94
|
" return performance.now() - started;",
|
|
58
95
|
"});",
|
|
59
96
|
"// A comparison workload reaches its own system; an Akter workload gets the Akter client.",
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { C as isReadonlyArrayEmpty, T as join, j as map, r as contains, y as head } from "../Array-B4kuTQeW.mjs";
|
|
2
|
-
import { P as currentTimeMillis } from "../HttpClientResponse-
|
|
3
|
-
import { n as log, t as error } from "../Console-
|
|
4
|
-
import { At as provideContext, B as flatMap, Dt as orElseSucceed, Et as orDie, K as forEach, Q as fromOption, R as filterOrFail, T as context, Tt as option, U as fn,
|
|
5
|
-
import { t as FileSystem } from "../FileSystem-
|
|
6
|
-
import { S as none, _ as isSome, f as getOrElse, h as isNone, u as fromNullishOr, w as some, x as match } from "../Option-DkxSnBhp.mjs";
|
|
7
|
-
import { t as Path } from "../Path-
|
|
8
|
-
import { g as take, l as offer, v as unbounded } from "../Queue-
|
|
9
|
-
import { F as String, I as Struct, S as Literals, X as Unknown, an as optionalKey, cr as getSomes, or as fromEntries, pt as fromJsonString, st as encodeEffect, tt as decodeEffect } from "../Schema-
|
|
2
|
+
import { P as currentTimeMillis } from "../HttpClientResponse-CifutXCF.mjs";
|
|
3
|
+
import { n as log, t as error } from "../Console-DY7H086H.mjs";
|
|
4
|
+
import { At as provideContext, B as flatMap, Dt as orElseSucceed, Et as orDie, K as forEach, Q as fromOption, R as filterOrFail, T as context, Tt as option, U as fn, Un as effect, X as forkScoped, Xt as succeed, _r as make, a as all, dt as map$1, et as gen, lr as _await, o as andThen, on as timeoutOrElse, sa as Service, sn as transposeOption, tn as tap, yr as succeed$1, z as findFirst } from "../Effect-CFIPV2Jg.mjs";
|
|
5
|
+
import { t as FileSystem } from "../FileSystem-iEC-kUB-.mjs";
|
|
6
|
+
import { S as none, _ as isSome, f as getOrElse, h as isNone, r as exists, u as fromNullishOr, w as some, x as match } from "../Option-DkxSnBhp.mjs";
|
|
7
|
+
import { t as Path } from "../Path-BRnAx8py.mjs";
|
|
8
|
+
import { g as take, l as offer, v as unbounded } from "../Queue-CyWN-MDp.mjs";
|
|
9
|
+
import { F as String, I as Struct, S as Literals, X as Unknown, an as optionalKey, cr as getSomes, or as fromEntries, pt as fromJsonString, st as encodeEffect, tt as decodeEffect } from "../Schema-O3QUdX3B.mjs";
|
|
10
10
|
import { i as value } from "../Redacted-RkJrG5Me.mjs";
|
|
11
|
-
import { K as splitLines, O as mapEffect, Q as tick, W as runForEach, c as drop, i as decodeText, l as empty, nt as unwrap, r as concat, u as encodeText, v as fromEffect } from "../Stream-
|
|
12
|
-
import { i as sha256, t as Digest } from "../Digest-
|
|
13
|
-
import { a as ChildProcessSpawner, n as make$1 } from "../ChildProcess-
|
|
11
|
+
import { K as splitLines, O as mapEffect, Q as tick, W as runForEach, c as drop, i as decodeText, l as empty, nt as unwrap, r as concat, u as encodeText, v as fromEffect } from "../Stream-BeqiANg7.mjs";
|
|
12
|
+
import { i as sha256, t as Digest } from "../Digest-CnBYV3Oh.mjs";
|
|
13
|
+
import { a as ChildProcessSpawner, n as make$1 } from "../ChildProcess-UWPy-kPn.mjs";
|
|
14
14
|
import { BenchSamples, benchReport, reportLines } from "./bench-report.pure.mjs";
|
|
15
15
|
import { benchRunner } from "./bench-runner.pure.mjs";
|
|
16
16
|
import { Credentials } from "../credentials/credentials.service.mjs";
|
|
17
|
-
import { t as CloudClient } from "../cloud-client.adapter-
|
|
17
|
+
import { t as CloudClient } from "../cloud-client.adapter-Dln8NW-9.mjs";
|
|
18
18
|
import { devRunner } from "../dev-runner.pure.mjs";
|
|
19
19
|
import { millisOf } from "../history-since.pure.mjs";
|
|
20
20
|
import { RunnerExitedError } from "../runner-exited.errors.mjs";
|
|
@@ -255,6 +255,7 @@ const sampled = fn("sampled")(function* sampled(options, timing, scratch) {
|
|
|
255
255
|
durationMillis: timing.durationMillis,
|
|
256
256
|
id: `bench-${now}`,
|
|
257
257
|
out: path.join(scratch, "samples.json"),
|
|
258
|
+
...getSomes({ rate: options.rate }),
|
|
258
259
|
stepTimeoutMillis: timing.stepTimeoutMillis,
|
|
259
260
|
workload: workload.href
|
|
260
261
|
};
|
|
@@ -274,7 +275,8 @@ const printed = (report, json) => {
|
|
|
274
275
|
const runBench = fn("runBench")(function* runBench(options) {
|
|
275
276
|
const durationMillis = getOrElse(millisOf(options.duration), () => anyPort);
|
|
276
277
|
const stepTimeoutMillis = getOrElse(millisOf(options.stepTimeout), () => anyPort);
|
|
277
|
-
|
|
278
|
+
const rateBelowOne = exists(options.rate, (rate) => rate < fewestWorkers);
|
|
279
|
+
if (durationMillis <= anyPort || stepTimeoutMillis <= anyPort || options.concurrency < fewestWorkers || rateBelowOne) return yield* usage("--duration and --step-timeout take a whole number and a unit, like 30s or 5m, and --concurrency and --rate at least 1.");
|
|
278
280
|
const scratch = yield* (yield* FileSystem).makeTempDirectoryScoped({ prefix: "akter-bench-" });
|
|
279
281
|
const [{ kind, run, target }, environment] = yield* all([sampled(options, {
|
|
280
282
|
durationMillis,
|
|
@@ -287,7 +289,8 @@ const runBench = fn("runBench")(function* runBench(options) {
|
|
|
287
289
|
concurrency: options.concurrency,
|
|
288
290
|
durationMillis,
|
|
289
291
|
kind,
|
|
290
|
-
target
|
|
292
|
+
target,
|
|
293
|
+
...getSomes({ rate: options.rate })
|
|
291
294
|
}
|
|
292
295
|
});
|
|
293
296
|
return yield* printed(report, options.json);
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { On as pipeArguments, Sn as identity, d as fromUndefinedOr, dn as isUndefined, en as isNotNull, nn as isNotUndefined, rn as isNullish, vn as constVoid, x as match } from "./Option-DkxSnBhp.mjs";
|
|
2
|
-
import { $t as suspend, A as ensuring, At as provideContext, B as flatMap,
|
|
2
|
+
import { $n as addFinalizerExit, $t as suspend, A as ensuring, Ar as isSuccess, At as provideContext, B as flatMap, Bn as isDoneCause, C as catch_, Cr as fail, F as failSync, Fr as Done, Gt as scoped, Hr as done, K as forEach, Ln as catchDone, M as fail$1, Nr as succeed$1, Nt as raceFirst, Pr as void_, Qn as addFinalizer, St as onExit, Un as effect, W as fnUntraced, Wt as scope, X as forkScoped, Xn as succeed$2, Xt as succeed, Yn as provideMerge, Yt as sleep, Zn as Scope, ar as makeUnsafe, ca as add, dr as doneUnsafe, dt as map, en as sync, er as close, et as gen, fn as uninterruptible, fr as fail$2, gn as void_$1, gr as isDoneUnsafe, hr as isDone, ht as mapError, i as addFinalizer$1, kr as isFailure, l as as, ln as try_, lr as _await, n as acquireRelease, nt as ignoreCause, o as andThen, p as callback, pn as uninterruptibleMask, q as forever, qn as mergeAll, rt as interrupt, tt as ignore, ua as get$2, vr as makeUnsafe$1, xt as onError, yn as withFiber, zr as UnknownError, zt as runForkWith } from "./Effect-CFIPV2Jg.mjs";
|
|
3
3
|
import { F as of } from "./Array-B4kuTQeW.mjs";
|
|
4
4
|
import { a as isFinite, m as toMillis, n as fromInputUnsafe } from "./Duration-EH9Vy4U6.mjs";
|
|
5
|
-
import { A as merge, J as suspend$1, Z as tapError, _ as fromChannel, at as mapDone, bt as runIn, f as fail$3, ft as makeUnsafe$2, gt as interrupt$1, ht as getCurrent, it as fromTransform, l as empty, nt as unwrap$1, tt as transduce, w as isStream, yt as join, z as run } from "./Stream-
|
|
6
|
-
import { c as make$4, d as offerUnsafe, f as poll, g as take, h as sliding, i as endUnsafe } from "./Queue-
|
|
7
|
-
import { n as layerWebCrypto } from "./SecureRandom-
|
|
8
|
-
import { c as handleErrnoException, o as layer$7, s as layer$6 } from "./hosted-runtime.layer-
|
|
9
|
-
import { a as drain, l as badArgument, o as fromChannel$1, s as isSink, t as FileSystem, u as systemError } from "./FileSystem-
|
|
10
|
-
import { n as layerWebCrypto$1 } from "./Digest-
|
|
5
|
+
import { A as merge, J as suspend$1, Z as tapError, _ as fromChannel, at as mapDone, bt as runIn, f as fail$3, ft as makeUnsafe$2, gt as interrupt$1, ht as getCurrent, it as fromTransform, l as empty, nt as unwrap$1, tt as transduce, w as isStream, yt as join, z as run } from "./Stream-BeqiANg7.mjs";
|
|
6
|
+
import { c as make$4, d as offerUnsafe, f as poll, g as take, h as sliding, i as endUnsafe } from "./Queue-CyWN-MDp.mjs";
|
|
7
|
+
import { n as layerWebCrypto } from "./SecureRandom-DYpl-YDn.mjs";
|
|
8
|
+
import { c as handleErrnoException, o as layer$7, s as layer$6 } from "./hosted-runtime.layer-BDXPqzSp.mjs";
|
|
9
|
+
import { a as drain, l as badArgument, o as fromChannel$1, s as isSink, t as FileSystem, u as systemError } from "./FileSystem-iEC-kUB-.mjs";
|
|
10
|
+
import { n as layerWebCrypto$1 } from "./Digest-CnBYV3Oh.mjs";
|
|
11
11
|
import { i as value, t as isRedacted } from "./Redacted-RkJrG5Me.mjs";
|
|
12
|
-
import { a as ChildProcessSpawner, c as make$6, i as display, l as makeHandle, n as make$5, o as ExitCode, r as parseFdName, s as ProcessId, t as fdName } from "./ChildProcess-
|
|
12
|
+
import { a as ChildProcessSpawner, c as make$6, i as display, l as makeHandle, n as make$5, o as ExitCode, r as parseFdName, s as ProcessId, t as fdName } from "./ChildProcess-UWPy-kPn.mjs";
|
|
13
13
|
import { t as make$7 } from "./MutableRef-D4Qv592C.mjs";
|
|
14
|
-
import { t as Path } from "./Path-
|
|
15
|
-
import { n as make$8, t as Stdio } from "./Stdio-
|
|
16
|
-
import { S as Terminal, w as make$9, x as QuitError } from "./TerminalCapabilities-
|
|
17
|
-
import { r as layer$8 } from "./cloud-client.adapter-
|
|
14
|
+
import { t as Path } from "./Path-BRnAx8py.mjs";
|
|
15
|
+
import { n as make$8, t as Stdio } from "./Stdio-7l23nD6W.mjs";
|
|
16
|
+
import { S as Terminal, w as make$9, x as QuitError } from "./TerminalCapabilities-R2LPyCNs.mjs";
|
|
17
|
+
import { r as layer$8 } from "./cloud-client.adapter-Dln8NW-9.mjs";
|
|
18
18
|
import { AkterArchive } from "./archive/akter-archive.service.mjs";
|
|
19
19
|
import { Bench } from "./bench/bench.service.mjs";
|
|
20
20
|
import { Deployment } from "./deploy/deploy.service.mjs";
|
|
21
21
|
import { ActorExport } from "./export/actor-export.service.mjs";
|
|
22
|
-
import { t as ActorCall } from "./actor-call.service-
|
|
22
|
+
import { t as ActorCall } from "./actor-call.service-vJm8gKjI.mjs";
|
|
23
23
|
import { OperationCall } from "./registry/operation-call.service.mjs";
|
|
24
24
|
import * as NodeChildProcess from "node:child_process";
|
|
25
25
|
import { PassThrough, finished } from "node:stream";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as cliRuntime } from "./cli-runtime.layer-
|
|
1
|
+
export { t as cliRuntime } from "./cli-runtime.layer-Bwuqll8h.mjs";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { n as Error } from "./Data-CeCULr0-.mjs";
|
|
2
|
-
import { $t as suspend, B as flatMap, Dt as orElseSucceed, E as contextWith,
|
|
3
|
-
import { $t as isUnique, Ct as isFinite, Dt as isGreaterThanOrEqualTo, F as String$1, Ft as isLessThanOrEqualTo, Gn as CurrentRedactedNames, I as Struct, In as CurrentRedactedNames$1, Jn as fromRecordUnsafe, Jt as isPropertyNames, M as Record, Rt as isMaxCodePoints, S as Literals, U as Tuple, Ut as isMinLength, W as TupleWithRest, Xn as isRedactedName, Y as Union, a as Boolean, an as optionalKey, g as Finite, jt as isInt, k as Number$1, n as ArraySchema, qt as isPattern, rn as makeFilterGroup, v as Int, wt as isGreaterThan, x as Literal, zn as redactUrl } from "./Schema-
|
|
4
|
-
import { J as suspend$1, d as ensuring, nt as unwrap } from "./Stream-
|
|
5
|
-
import { C as put, E as setUrlParams, N as Clock, O as make$3, a as WebSourceSymbol, b as patch, c as TypeId$2, g as del, i as matchStatus, m as bodyJsonUnsafe, n as filterStatusOk$1, o as getWebSource, t as TypeId$1, u as schemaBodyJson, v as get, w as setHeaders, x as post, y as make$2 } from "./HttpClientResponse-
|
|
2
|
+
import { $t as suspend, B as flatMap, Cr as fail$1, Dt as orElseSucceed, E as contextWith, Jr as hasInterrupts, M as fail, N as failCause, Qi as DisablePropagation, Un as effect, Xt as succeed, _a as merge, bn as withParentSpan, cr as TracerTimingEnabled, dt as map, en as sync, gn as void_, hn as useSpan, mn as updateContext, oa as Reference, pn as uninterruptibleMask, sa as Service, vt as matchCauseEffect, wt as onInterrupt, yn as withFiber } from "./Effect-CFIPV2Jg.mjs";
|
|
3
|
+
import { $t as isUnique, Ct as isFinite, Dt as isGreaterThanOrEqualTo, F as String$1, Ft as isLessThanOrEqualTo, Gn as CurrentRedactedNames, I as Struct, In as CurrentRedactedNames$1, Jn as fromRecordUnsafe, Jt as isPropertyNames, M as Record, Rt as isMaxCodePoints, S as Literals, U as Tuple, Ut as isMinLength, W as TupleWithRest, Xn as isRedactedName, Y as Union, a as Boolean, an as optionalKey, g as Finite, jt as isInt, k as Number$1, n as ArraySchema, qt as isPattern, rn as makeFilterGroup, v as Int, wt as isGreaterThan, x as Literal, zn as redactUrl } from "./Schema-O3QUdX3B.mjs";
|
|
4
|
+
import { J as suspend$1, d as ensuring, nt as unwrap } from "./Stream-BeqiANg7.mjs";
|
|
5
|
+
import { C as put, E as setUrlParams, N as Clock, O as make$3, a as WebSourceSymbol, b as patch, c as TypeId$2, g as del, i as matchStatus, m as bodyJsonUnsafe, n as filterStatusOk$1, o as getWebSource, t as TypeId$1, u as schemaBodyJson, v as get, w as setHeaders, x as post, y as make$2 } from "./HttpClientResponse-CifutXCF.mjs";
|
|
6
6
|
import { Ct as NodeInspectSymbol, On as pipeArguments, bn as dual, bt as setStackTraceLimit, gn as constTrue, hn as constFalse, m as getOrUndefined, x as match, xt as BaseProto, yt as getStackTraceLimit } from "./Option-DkxSnBhp.mjs";
|
|
7
7
|
import { $ as isFailure } from "./Array-B4kuTQeW.mjs";
|
|
8
|
-
import { i as HttpClientError, o as InvalidUrlError, s as StatusCodeError } from "./HttpClientError-
|
|
8
|
+
import { i as HttpClientError, o as InvalidUrlError, s as StatusCodeError } from "./HttpClientError-BVd83gxQ.mjs";
|
|
9
9
|
// ../../node_modules/.pnpm/effect@4.1.2_patch_hash=0e61176203bb1256381ce1c5b488d7951983ce38ff698647d3f4617383abbf07/node_modules/effect/dist/http/HttpMethod.js
|
|
10
10
|
/**
|
|
11
11
|
* Provides a readonly set containing every supported `HttpMethod` literal.
|
|
@@ -860,6 +860,20 @@ const ActorErasedErrorEncoded = Struct({
|
|
|
860
860
|
"_tag": Literal("ActorErasedError"),
|
|
861
861
|
"actor": String$1
|
|
862
862
|
}).annotate({ "identifier": "ActorErasedErrorEncoded" });
|
|
863
|
+
const ComputerSecretRef = Struct({
|
|
864
|
+
"header": String$1,
|
|
865
|
+
"host": String$1,
|
|
866
|
+
"prefix": optionalKey(String$1),
|
|
867
|
+
"secret": String$1
|
|
868
|
+
}).annotate({ "identifier": "ComputerSecretRef" });
|
|
869
|
+
const ComputerState = Literals([
|
|
870
|
+
"starting",
|
|
871
|
+
"running",
|
|
872
|
+
"paused",
|
|
873
|
+
"stopped",
|
|
874
|
+
"failed",
|
|
875
|
+
"gone"
|
|
876
|
+
]).annotate({ "identifier": "ComputerState" });
|
|
863
877
|
const ExportSnapshotId = String$1.annotate({ "description": "Names one export snapshot of one actor." }).check(isPattern(new globalThis.RegExp("^[0-9a-f]{32}$", "u")).annotate({
|
|
864
878
|
"expected": "a string matching the RegExp ^[0-9a-f]{32}$",
|
|
865
879
|
"identifier": "ExportSnapshotId"
|
|
@@ -893,7 +907,7 @@ const ForkId = String$1.annotate({ "description": "Names this fork. A retry with
|
|
|
893
907
|
"expected": "a string with at most 200 code points",
|
|
894
908
|
"identifier": "ForkId"
|
|
895
909
|
}));
|
|
896
|
-
const ActorKey_1 = String$1.annotate({ "description": "The free key the copy is created under.
|
|
910
|
+
const ActorKey_1 = String$1.annotate({ "description": "The free key the copy is created under. It may be on another shard than the parent's; the copy's computers are copied there too." }).check(isMinLength(1).annotate({
|
|
897
911
|
"expected": "a value with a length of at least 1",
|
|
898
912
|
"identifier": "ActorKey_1"
|
|
899
913
|
}));
|
|
@@ -979,6 +993,10 @@ const BillingStatus = Literals([
|
|
|
979
993
|
"description": "none: no card yet. checkoutOpen: a checkout link is waiting for a person. active: billed monthly. pastDue: a payment failed; new spend stops after a grace period. canceled: back to no card after a final invoice.",
|
|
980
994
|
"identifier": "BillingStatus"
|
|
981
995
|
});
|
|
996
|
+
const ReturnUrl = String$1.annotate({ "description": "Where Stripe sends the person back to, whether they added a card or not. A checkout link still open is handed back as it is, with the return it was opened with." }).check(isMaxCodePoints(2e3).annotate({ "expected": "a string with at most 2000 code points" })).check(isPattern(new globalThis.RegExp("^(?:https:\\/\\/app\\.akter\\.dev)(?:[/?][^\\s\\\\]*)?$", "u")).annotate({
|
|
997
|
+
"expected": "a string matching the RegExp ^(?:https:\\/\\/app\\.akter\\.dev)(?:[/?][^\\s\\\\]*)?$",
|
|
998
|
+
"identifier": "ReturnUrl"
|
|
999
|
+
}));
|
|
982
1000
|
const SpendCap_3 = Number$1.annotate({ "description": "The monthly cap to start the paid plan with. Defaults to the plan's starting cap." }).check(isInt().annotate({ "expected": "an integer" })).check(isGreaterThanOrEqualTo(1).annotate({ "expected": "a value greater than or equal to 1" })).check(isLessThanOrEqualTo(9007199254740991).annotate({
|
|
983
1001
|
"expected": "a value less than or equal to 9007199254740991",
|
|
984
1002
|
"identifier": "SpendCap_3"
|
|
@@ -987,6 +1005,11 @@ const CheckoutLink = Struct({
|
|
|
987
1005
|
"expiresAt": String$1,
|
|
988
1006
|
"url": String$1.annotate({ "description": "A Stripe-hosted page where a person adds a card. Card details go to Stripe only, never to Akter, the CLI or an agent." })
|
|
989
1007
|
}).annotate({ "identifier": "CheckoutLink" });
|
|
1008
|
+
const ReturnUrl_1 = String$1.annotate({ "description": "Where Stripe sends the person back to: a URL on one of these exact origins, https://app.akter.dev, at most 2000 characters. Absent, it is the Cloud API's own plain-text page, which tells the person to return to their terminal." }).check(isMaxCodePoints(2e3).annotate({ "expected": "a string with at most 2000 code points" })).check(isPattern(new globalThis.RegExp("^(?:https:\\/\\/app\\.akter\\.dev)(?:[/?][^\\s\\\\]*)?$", "u")).annotate({
|
|
1009
|
+
"expected": "a string matching the RegExp ^(?:https:\\/\\/app\\.akter\\.dev)(?:[/?][^\\s\\\\]*)?$",
|
|
1010
|
+
"identifier": "ReturnUrl_1"
|
|
1011
|
+
}));
|
|
1012
|
+
const PortalLink = Struct({ "url": String$1.annotate({ "description": "A Stripe-hosted page where the person updates their card, reads their invoices and cancels. It is short-lived: open it right away." }) }).annotate({ "identifier": "PortalLink" });
|
|
990
1013
|
const Usd_3 = Number$1.annotate({ "description": "The most an organization without a card may spend in a month." }).check(isFinite().annotate({
|
|
991
1014
|
"expected": "a finite number",
|
|
992
1015
|
"identifier": "Usd_3"
|
|
@@ -1039,11 +1062,6 @@ const FeatureNotEnabledErrorEncoded = Struct({
|
|
|
1039
1062
|
"_tag": Literal("FeatureNotEnabledError"),
|
|
1040
1063
|
"flag": FlagName
|
|
1041
1064
|
}).annotate({ "identifier": "FeatureNotEnabledErrorEncoded" });
|
|
1042
|
-
const SnapshotLimitErrorEncoded = Struct({
|
|
1043
|
-
"_tag": Literal("SnapshotLimitError"),
|
|
1044
|
-
"environment": EnvironmentName,
|
|
1045
|
-
"limit": Number$1.annotate({ "description": "Snapshots one environment may hold. Deleted snapshots count too, because the storage provider keeps their data until it can be removed; delete the environment to start again." }).check(isInt().annotate({ "expected": "an integer" })).check(isGreaterThanOrEqualTo(-9007199254740991).annotate({ "expected": "a value greater than or equal to -9007199254740991" })).check(isLessThanOrEqualTo(9007199254740991).annotate({ "expected": "a value less than or equal to 9007199254740991" }))
|
|
1046
|
-
}).annotate({ "identifier": "SnapshotLimitErrorEncoded" });
|
|
1047
1065
|
const InUseErrorEncoded = Struct({
|
|
1048
1066
|
"_tag": Literal("InUseError"),
|
|
1049
1067
|
"branches": optionalKey(ArraySchema(EnvironmentName).annotate({ "description": "With environmentHasBranches: the live branches of the environment named by key." })),
|
|
@@ -1229,6 +1247,17 @@ const CommandEntry = Struct({
|
|
|
1229
1247
|
"description": "One journal row, as the host recorded it. Decode it with the app's contract; a row the contract no longer reads is unreadable there, not here.",
|
|
1230
1248
|
"identifier": "CommandEntry"
|
|
1231
1249
|
});
|
|
1250
|
+
const ActorComputer = Struct({
|
|
1251
|
+
"egress": ArraySchema(String$1).annotate({ "description": "The hosts or rules the computer may reach." }),
|
|
1252
|
+
"image": String$1,
|
|
1253
|
+
"name": String$1.annotate({ "description": "The computer's name, unique among its actor's computers." }),
|
|
1254
|
+
"secrets": optionalKey(ArraySchema(ComputerSecretRef)),
|
|
1255
|
+
"size": Struct({
|
|
1256
|
+
"memoryMib": Int.check(isGreaterThanOrEqualTo(-9007199254740991).annotate({ "expected": "a value greater than or equal to -9007199254740991" })).check(isLessThanOrEqualTo(9007199254740991).annotate({ "expected": "a value less than or equal to 9007199254740991" })),
|
|
1257
|
+
"vcpu": Int.check(isGreaterThanOrEqualTo(-9007199254740991).annotate({ "expected": "a value greater than or equal to -9007199254740991" })).check(isLessThanOrEqualTo(9007199254740991).annotate({ "expected": "a value less than or equal to 9007199254740991" }))
|
|
1258
|
+
}),
|
|
1259
|
+
"state": ComputerState
|
|
1260
|
+
}).annotate({ "identifier": "ActorComputer" });
|
|
1232
1261
|
const ExportSnapshot = Struct({
|
|
1233
1262
|
"actor": ActorType,
|
|
1234
1263
|
"bytes": Int.check(isLessThanOrEqualTo(9007199254740991).annotate({ "expected": "a value less than or equal to 9007199254740991" })).check(isGreaterThan(0).annotate({ "expected": "a value greater than 0" })),
|
|
@@ -1303,7 +1332,11 @@ const BillingAccount = Struct({
|
|
|
1303
1332
|
"spendCap": SpendCap_2,
|
|
1304
1333
|
"status": BillingStatus
|
|
1305
1334
|
}).annotate({ "identifier": "BillingAccount" });
|
|
1306
|
-
Struct({
|
|
1335
|
+
Struct({
|
|
1336
|
+
"returnUrl": optionalKey(ReturnUrl),
|
|
1337
|
+
"spendCap": optionalKey(SpendCap_3)
|
|
1338
|
+
}).annotate({ "identifier": "StartCheckout" });
|
|
1339
|
+
Struct({ "returnUrl": optionalKey(ReturnUrl_1) }).annotate({ "identifier": "OpenPortal" });
|
|
1307
1340
|
const CardRequiredErrorEncoded = Struct({
|
|
1308
1341
|
"_tag": Literal("CardRequiredError"),
|
|
1309
1342
|
"allowanceUsd": Usd_3
|
|
@@ -1429,6 +1462,7 @@ const CommandHistoryPage = Struct({
|
|
|
1429
1462
|
"description": "Commands in seq order. When the page is full, next is its last seq: pass it as after for the next page.",
|
|
1430
1463
|
"identifier": "CommandHistoryPage"
|
|
1431
1464
|
});
|
|
1465
|
+
const ActorComputerList = Struct({ "items": ArraySchema(ActorComputer) }).annotate({ "identifier": "ActorComputerList" });
|
|
1432
1466
|
const MemberPage = Struct({
|
|
1433
1467
|
"items": ArraySchema(Member),
|
|
1434
1468
|
"nextCursor": optionalKey(String$1.annotate({ "description": "Pass as cursor for the next page." }))
|
|
@@ -1758,11 +1792,7 @@ const SnapshotsCreate202 = Snapshot;
|
|
|
1758
1792
|
const SnapshotsCreate401 = UnauthorizedErrorEncoded;
|
|
1759
1793
|
const SnapshotsCreate403 = ForbiddenErrorEncoded;
|
|
1760
1794
|
const SnapshotsCreate404 = Union([NotFoundErrorEncoded, FeatureNotEnabledErrorEncoded]);
|
|
1761
|
-
const SnapshotsCreate409 = Union([
|
|
1762
|
-
AlreadyExistsErrorEncoded,
|
|
1763
|
-
InUseErrorEncoded,
|
|
1764
|
-
SnapshotLimitErrorEncoded
|
|
1765
|
-
]);
|
|
1795
|
+
const SnapshotsCreate409 = Union([AlreadyExistsErrorEncoded, InUseErrorEncoded]);
|
|
1766
1796
|
const SnapshotsCreate503 = Union([
|
|
1767
1797
|
ActorUnavailableErrorEncoded,
|
|
1768
1798
|
AuthUnavailableErrorEncoded,
|
|
@@ -2019,6 +2049,18 @@ const ActorsErase503 = Union([
|
|
|
2019
2049
|
BuildStorageUnavailableErrorEncoded,
|
|
2020
2050
|
ExecUnavailableErrorEncoded
|
|
2021
2051
|
]);
|
|
2052
|
+
const ActorsComputers200 = ActorComputerList;
|
|
2053
|
+
const ActorsComputers401 = UnauthorizedErrorEncoded;
|
|
2054
|
+
const ActorsComputers403 = ForbiddenErrorEncoded;
|
|
2055
|
+
const ActorsComputers404 = Union([NotFoundErrorEncoded, FeatureNotEnabledErrorEncoded]);
|
|
2056
|
+
const ActorsComputers410 = ActorErasedErrorEncoded;
|
|
2057
|
+
const ActorsComputers503 = Union([
|
|
2058
|
+
ActorUnavailableErrorEncoded,
|
|
2059
|
+
AuthUnavailableErrorEncoded,
|
|
2060
|
+
BillingUnavailableErrorEncoded,
|
|
2061
|
+
BuildStorageUnavailableErrorEncoded,
|
|
2062
|
+
ExecUnavailableErrorEncoded
|
|
2063
|
+
]);
|
|
2022
2064
|
const ActorsExportShard200 = ExportShardPage;
|
|
2023
2065
|
const ActorsExportShard401 = UnauthorizedErrorEncoded;
|
|
2024
2066
|
const ActorsExportShard403 = ForbiddenErrorEncoded;
|
|
@@ -2280,6 +2322,18 @@ const BillingCheckout503 = Union([
|
|
|
2280
2322
|
BuildStorageUnavailableErrorEncoded,
|
|
2281
2323
|
ExecUnavailableErrorEncoded
|
|
2282
2324
|
]);
|
|
2325
|
+
const BillingPortal201 = PortalLink;
|
|
2326
|
+
const BillingPortal401 = UnauthorizedErrorEncoded;
|
|
2327
|
+
const BillingPortal402 = CardRequiredErrorEncoded;
|
|
2328
|
+
const BillingPortal403 = ForbiddenErrorEncoded;
|
|
2329
|
+
const BillingPortal404 = Union([NotFoundErrorEncoded, FeatureNotEnabledErrorEncoded]);
|
|
2330
|
+
const BillingPortal503 = Union([
|
|
2331
|
+
ActorUnavailableErrorEncoded,
|
|
2332
|
+
AuthUnavailableErrorEncoded,
|
|
2333
|
+
BillingUnavailableErrorEncoded,
|
|
2334
|
+
BuildStorageUnavailableErrorEncoded,
|
|
2335
|
+
ExecUnavailableErrorEncoded
|
|
2336
|
+
]);
|
|
2283
2337
|
const BillingSetCap200 = BillingAccount;
|
|
2284
2338
|
const BillingSetCap401 = UnauthorizedErrorEncoded;
|
|
2285
2339
|
const BillingSetCap402 = CardRequiredErrorEncoded;
|
|
@@ -2855,6 +2909,20 @@ const make = (httpClient, options = {}) => {
|
|
|
2855
2909
|
"204": () => void_,
|
|
2856
2910
|
orElse: unexpectedStatus
|
|
2857
2911
|
}))))),
|
|
2912
|
+
"actorsComputers": (organization, app, actor, key, options) => __makePathRequest(get, [
|
|
2913
|
+
organization,
|
|
2914
|
+
app,
|
|
2915
|
+
actor,
|
|
2916
|
+
key
|
|
2917
|
+
], () => "/v1/organizations/" + __encodePathParam(organization) + "/apps/" + __encodePathParam(app) + "/actors/" + __encodePathParam(actor) + "/" + __encodePathParam(key) + "/computers").pipe(flatMap((request) => request.pipe(withResponse(options?.config)(matchStatus({
|
|
2918
|
+
"2xx": decodeSuccess(ActorsComputers200),
|
|
2919
|
+
"401": decodeError("ActorsComputers401", ActorsComputers401),
|
|
2920
|
+
"403": decodeError("ActorsComputers403", ActorsComputers403),
|
|
2921
|
+
"404": decodeError("ActorsComputers404", ActorsComputers404),
|
|
2922
|
+
"410": decodeError("ActorsComputers410", ActorsComputers410),
|
|
2923
|
+
"503": decodeError("ActorsComputers503", ActorsComputers503),
|
|
2924
|
+
orElse: unexpectedStatus
|
|
2925
|
+
}))))),
|
|
2858
2926
|
"actorsExportShard": (organization, app, shard, options) => __makePathRequest(get, [
|
|
2859
2927
|
organization,
|
|
2860
2928
|
app,
|
|
@@ -3102,6 +3170,15 @@ const make = (httpClient, options = {}) => {
|
|
|
3102
3170
|
"503": decodeError("BillingCheckout503", BillingCheckout503),
|
|
3103
3171
|
orElse: unexpectedStatus
|
|
3104
3172
|
}))))),
|
|
3173
|
+
"billingPortal": (organization, options) => __makePathRequest(post, [organization], () => "/v1/organizations/" + __encodePathParam(organization) + "/billing/portal").pipe(flatMap((request) => request.pipe(bodyJsonUnsafe(options.payload), withResponse(options.config)(matchStatus({
|
|
3174
|
+
"2xx": decodeSuccess(BillingPortal201),
|
|
3175
|
+
"401": decodeError("BillingPortal401", BillingPortal401),
|
|
3176
|
+
"402": decodeError("BillingPortal402", BillingPortal402),
|
|
3177
|
+
"403": decodeError("BillingPortal403", BillingPortal403),
|
|
3178
|
+
"404": decodeError("BillingPortal404", BillingPortal404),
|
|
3179
|
+
"503": decodeError("BillingPortal503", BillingPortal503),
|
|
3180
|
+
orElse: unexpectedStatus
|
|
3181
|
+
}))))),
|
|
3105
3182
|
"billingSetCap": (organization, options) => __makePathRequest(put, [organization], () => "/v1/organizations/" + __encodePathParam(organization) + "/billing/cap").pipe(flatMap((request) => request.pipe(bodyJsonUnsafe(options.payload), withResponse(options.config)(matchStatus({
|
|
3106
3183
|
"2xx": decodeSuccess(BillingSetCap200),
|
|
3107
3184
|
"401": decodeError("BillingSetCap401", BillingSetCap401),
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { P as currentTimeMillis, S as prependUrl, f as bearerToken, r as fromWeb } from "./HttpClientResponse-
|
|
2
|
-
import { A as ensuring, At as provideContext, B as flatMap, Dt as orElseSucceed, L as filterOrElse, Lt as retry, M as fail, T as context, Tt as option, U as fn,
|
|
3
|
-
import { B as TaggedStruct, Qn as remove, Zn as merge, ir as toEpochMillis, mt as is, qn as fromInput, tt as decodeEffect, u as DateTimeUtcFromString } from "./Schema-
|
|
1
|
+
import { P as currentTimeMillis, S as prependUrl, f as bearerToken, r as fromWeb } from "./HttpClientResponse-CifutXCF.mjs";
|
|
2
|
+
import { A as ensuring, At as provideContext, B as flatMap, Dt as orElseSucceed, L as filterOrElse, Lt as retry, M as fail, T as context, Tt as option, U as fn, Un as effect, W as fnUntraced, Xt as succeed, cn as tryPromise, d as asVoid, dt as map, en as sync, et as gen, fa as getOrUndefined, ft as mapBoth, ht as mapError, in as timeout, jt as provideService, o as andThen, oa as Reference, p as callback, rt as interrupt, sa as Service, xt as onError, ya as pick } from "./Effect-CFIPV2Jg.mjs";
|
|
3
|
+
import { B as TaggedStruct, Qn as remove, Zn as merge, ir as toEpochMillis, mt as is, qn as fromInput, tt as decodeEffect, u as DateTimeUtcFromString } from "./Schema-O3QUdX3B.mjs";
|
|
4
4
|
import { S as none, _ as isSome, b as map$1, r as exists, w as some, x as match } from "./Option-DkxSnBhp.mjs";
|
|
5
5
|
import { i as value, n as make } from "./Redacted-RkJrG5Me.mjs";
|
|
6
|
-
import { o as set, r as make$1, s as update, t as get } from "./Ref-
|
|
7
|
-
import { t as make$2 } from "./Semaphore-
|
|
8
|
-
import { $ as toReadableStreamEffect, C as interruptWhen, d as ensuring$1, j as mkArrayBuffer } from "./Stream-
|
|
9
|
-
import { _ as mapRequestEffect, d as make$4, f as HttpClient, g as mapRequest, h as make$3, m as layerMergedContext, p as filterStatusOk, v as transformResponse } from "./cloud-client.adapter-
|
|
10
|
-
import { c as TransportError, i as HttpClientError, r as EncodeError, s as StatusCodeError } from "./HttpClientError-
|
|
6
|
+
import { o as set, r as make$1, s as update, t as get } from "./Ref-CX3ghLq6.mjs";
|
|
7
|
+
import { t as make$2 } from "./Semaphore-DHYKAQSv.mjs";
|
|
8
|
+
import { $ as toReadableStreamEffect, C as interruptWhen, d as ensuring$1, j as mkArrayBuffer } from "./Stream-BeqiANg7.mjs";
|
|
9
|
+
import { _ as mapRequestEffect, d as make$4, f as HttpClient, g as mapRequest, h as make$3, m as layerMergedContext, p as filterStatusOk, v as transformResponse } from "./cloud-client.adapter-Ce4oyGNh.mjs";
|
|
10
|
+
import { c as TransportError, i as HttpClientError, r as EncodeError, s as StatusCodeError } from "./HttpClientError-BVd83gxQ.mjs";
|
|
11
11
|
import { DeployFailedError } from "./deploy/deploy-failed.errors.mjs";
|
|
12
12
|
import { ApiAttempt } from "./deploy/auth/api-attempt.service.mjs";
|
|
13
13
|
import { exchangeFailure, progressWait, retriedSignIn, signInRetries } from "./deploy/request-failure.pure.mjs";
|
|
14
|
-
import { signInFailure } from "./
|
|
14
|
+
import { l as signInFailure } from "./operation-output.pure-ChUlePFj.mjs";
|
|
15
15
|
// ../../node_modules/.pnpm/effect@4.1.2_patch_hash=0e61176203bb1256381ce1c5b488d7951983ce38ff698647d3f4617383abbf07/node_modules/effect/dist/http/FetchHttpClient.js
|
|
16
16
|
/**
|
|
17
17
|
* Fetch-based implementation of the Effect HTTP client service.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { a as withSubcommands, i as withDescription, t as make } from "../Command-
|
|
1
|
+
import { a as withSubcommands, i as withDescription, t as make } from "../Command-D3hF_i6F.mjs";
|
|
2
2
|
import { importApp } from "../archive/archive-cli.config.mjs";
|
|
3
3
|
import { bench, deploy, exportApp } from "../app-cli.config.mjs";
|
|
4
4
|
import { login, logout, signup } from "../credentials/login.config.mjs";
|
|
5
|
-
import { t as docs } from "../docs.config-
|
|
5
|
+
import { t as docs } from "../docs.config-Dy0MFrKd.mjs";
|
|
6
6
|
import { localCommands } from "../local/environment-cli.config.mjs";
|
|
7
7
|
import { logCommands } from "../logs/log-follow.config.mjs";
|
|
8
8
|
import { actorCommands } from "../registry/actor-commands.config.mjs";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as runAkter } from "../akter-program.config-
|
|
1
|
+
export { t as runAkter } from "../akter-program.config-C-mFiZp1.mjs";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { t as match } from "../Boolean-kILIvmhE.mjs";
|
|
2
|
-
import { a as option, i as String, r as Redacted } from "../Config-
|
|
3
|
-
import { At as provideContext, B as flatMap, Dt as orElseSucceed, Et as orDie,
|
|
4
|
-
import { t as FileSystem } from "../FileSystem-
|
|
2
|
+
import { a as option, i as String, r as Redacted } from "../Config-DEUiBxw4.mjs";
|
|
3
|
+
import { At as provideContext, B as flatMap, Dt as orElseSucceed, Et as orDie, Jn as provide, M as fail, Q as fromOption, T as context, Tt as option$1, Un as effect, W as fnUntraced, Xt as succeed, _n as when, dt as map, et as gen, f as cached, gn as void_, ht as mapError, sa as Service, tt as ignore } from "../Effect-CFIPV2Jg.mjs";
|
|
4
|
+
import { t as FileSystem } from "../FileSystem-iEC-kUB-.mjs";
|
|
5
5
|
import { C as orElse, S as none, _ as isSome, a as firstSomeOf, b as map$1, d as fromUndefinedOr, f as getOrElse, h as isNone, i as filter, o as flatMap$1, w as some, x as match$1 } from "../Option-DkxSnBhp.mjs";
|
|
6
|
-
import { t as Path } from "../Path-
|
|
6
|
+
import { t as Path } from "../Path-BRnAx8py.mjs";
|
|
7
7
|
import { i as value, n as make$1 } from "../Redacted-RkJrG5Me.mjs";
|
|
8
|
-
import { F as String$1, I as Struct, a as Boolean, an as optionalKey, pt as fromJsonString, st as encodeEffect, tt as decodeEffect, x as Literal } from "../Schema-
|
|
8
|
+
import { F as String$1, I as Struct, a as Boolean, an as optionalKey, pt as fromJsonString, st as encodeEffect, tt as decodeEffect, x as Literal } from "../Schema-O3QUdX3B.mjs";
|
|
9
9
|
import { s as isNonEmpty } from "../String-q5dcsVe4.mjs";
|
|
10
10
|
import { CliExitError } from "../terminal/cli-exit.errors.mjs";
|
|
11
11
|
import { Keychain } from "./keychain.adapter.mjs";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { j as map } from "../Array-B4kuTQeW.mjs";
|
|
2
|
-
import { Dt as orElseSucceed, Gt as scoped, K as forEach, Pt as reduce,
|
|
2
|
+
import { Dt as orElseSucceed, Gt as scoped, K as forEach, Pt as reduce, Un as effect, W as fnUntraced, Xt as succeed, a as all, dt as map$1, et as gen, in as timeout, jt as provideService, sa as Service } from "../Effect-CFIPV2Jg.mjs";
|
|
3
3
|
import { S as none, _ as isSome, b as map$2, i as filter, w as some } from "../Option-DkxSnBhp.mjs";
|
|
4
|
-
import { M as mkString, T as make, V as runDrain, i as decodeText } from "../Stream-
|
|
4
|
+
import { M as mkString, T as make, V as runDrain, i as decodeText } from "../Stream-BeqiANg7.mjs";
|
|
5
5
|
import { f as replaceAll, s as isNonEmpty, y as trimEnd } from "../String-q5dcsVe4.mjs";
|
|
6
|
-
import { a as ChildProcessSpawner, n as make$1 } from "../ChildProcess-
|
|
6
|
+
import { a as ChildProcessSpawner, n as make$1 } from "../ChildProcess-UWPy-kPn.mjs";
|
|
7
7
|
// src/credentials/keychain.adapter.ts
|
|
8
8
|
const service = "akter-cli";
|
|
9
9
|
const label = "Akter CLI";
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { t as match } from "../Boolean-kILIvmhE.mjs";
|
|
2
|
-
import { n as log } from "../Console-
|
|
3
|
-
import { C as catch_, M as fail, U as fn, W as fnUntraced, et as gen, gn as void_, ht as mapError, in as timeout, l as as } from "../Effect-
|
|
2
|
+
import { n as log } from "../Console-DY7H086H.mjs";
|
|
3
|
+
import { C as catch_, M as fail, U as fn, W as fnUntraced, et as gen, gn as void_, ht as mapError, in as timeout, l as as } from "../Effect-CFIPV2Jg.mjs";
|
|
4
4
|
import { S as none, _ as isSome, f as getOrElse, h as isNone, p as getOrNull, v as liftPredicate, w as some, x as match$1 } from "../Option-DkxSnBhp.mjs";
|
|
5
5
|
import { i as value, n as make } from "../Redacted-RkJrG5Me.mjs";
|
|
6
|
-
import { B as TaggedStruct, F as String, I as Struct, S as Literals, mt as is, ot as decodeUnknownOption } from "../Schema-
|
|
7
|
-
import { t as Stdio } from "../Stdio-
|
|
8
|
-
import { M as mkString, i as decodeText } from "../Stream-
|
|
6
|
+
import { B as TaggedStruct, F as String, I as Struct, S as Literals, mt as is, ot as decodeUnknownOption } from "../Schema-O3QUdX3B.mjs";
|
|
7
|
+
import { t as Stdio } from "../Stdio-7l23nD6W.mjs";
|
|
8
|
+
import { M as mkString, i as decodeText } from "../Stream-BeqiANg7.mjs";
|
|
9
9
|
import { o as isEmpty, v as trim } from "../String-q5dcsVe4.mjs";
|
|
10
|
-
import { f as optional, i as withDescription$1, l as String$1, m as withDescription, o as Boolean, p as withDefault, t as make$1 } from "../Command-
|
|
11
|
-
import { c as String$2, d as run, o as Password, t as TerminalCapabilities } from "../TerminalCapabilities-
|
|
10
|
+
import { f as optional, i as withDescription$1, l as String$1, m as withDescription, o as Boolean, p as withDefault, t as make$1 } from "../Command-D3hF_i6F.mjs";
|
|
11
|
+
import { c as String$2, d as run, o as Password, t as TerminalCapabilities } from "../TerminalCapabilities-R2LPyCNs.mjs";
|
|
12
12
|
import { CliExitError } from "../terminal/cli-exit.errors.mjs";
|
|
13
13
|
import { Confirmation } from "../terminal/confirm.adapter.mjs";
|
|
14
14
|
import { Credentials } from "./credentials.service.mjs";
|
|
15
|
-
import { t as CloudClient } from "../cloud-client.adapter-
|
|
16
|
-
import { compactJson } from "../
|
|
15
|
+
import { t as CloudClient } from "../cloud-client.adapter-Dln8NW-9.mjs";
|
|
16
|
+
import { n as compactJson } from "../operation-output.pure-ChUlePFj.mjs";
|
|
17
17
|
// src/credentials/login.config.ts
|
|
18
18
|
const json = Boolean("json").pipe(withDefault(false), withDescription("Print the result as one line of JSON"));
|
|
19
19
|
const usage = (reason, message) => CliExitError.make({
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { B as flatMap, Jt as serviceOption, Lt as retry, W as fnUntraced,
|
|
2
|
-
import { t as error } from "../../Console-
|
|
1
|
+
import { B as flatMap, Jt as serviceOption, Lt as retry, W as fnUntraced, gn as void_, in as timeout, jt as provideService, o as andThen, ri as isTimeoutError, sa as Service, y as catchIf } from "../../Effect-CFIPV2Jg.mjs";
|
|
2
|
+
import { t as error } from "../../Console-DY7H086H.mjs";
|
|
3
3
|
import { x as match } from "../../Option-DkxSnBhp.mjs";
|
|
4
|
-
import { o as set, r as make, t as get } from "../../Ref-
|
|
5
|
-
import { mt as is } from "../../Schema-
|
|
4
|
+
import { o as set, r as make, t as get } from "../../Ref-CX3ghLq6.mjs";
|
|
5
|
+
import { mt as is } from "../../Schema-O3QUdX3B.mjs";
|
|
6
6
|
import { TokenRefreshError } from "./token-refresh.errors.mjs";
|
|
7
7
|
import { reconnectBackoff, refreshMessage, requestFailure } from "../request-failure.pure.mjs";
|
|
8
8
|
// src/deploy/auth/api-attempt.service.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { F as String, z as TaggedError } from "../../Schema-
|
|
1
|
+
import { F as String, z as TaggedError } from "../../Schema-O3QUdX3B.mjs";
|
|
2
2
|
// src/deploy/auth/token-refresh.errors.ts
|
|
3
3
|
var TokenRefreshError = class extends TaggedError()("TokenRefreshError", { message: String }) {};
|
|
4
4
|
export { TokenRefreshError };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { M as match, W as unfold, j as map } from "../Array-B4kuTQeW.mjs";
|
|
2
|
-
import { At as provideContext, B as flatMap, Q as fromOption, T as context, U as fn,
|
|
3
|
-
import { t as FileSystem } from "../FileSystem-
|
|
2
|
+
import { At as provideContext, B as flatMap, Q as fromOption, T as context, U as fn, Un as effect, W as fnUntraced, cn as tryPromise, dt as map$1, et as gen, sa as Service, ya as pick, z as findFirst } from "../Effect-CFIPV2Jg.mjs";
|
|
3
|
+
import { t as FileSystem } from "../FileSystem-iEC-kUB-.mjs";
|
|
4
4
|
import { b as map$2, f as getOrElse, i as filter, u as fromNullishOr, w as some } from "../Option-DkxSnBhp.mjs";
|
|
5
|
-
import { t as Path } from "../Path-
|
|
6
|
-
import { F as String, I as Struct, n as ArraySchema, pt as fromJsonString, st as encodeEffect, tt as decodeEffect, v as Int } from "../Schema-
|
|
7
|
-
import { i as sha256, t as Digest } from "../Digest-
|
|
8
|
-
import { a as ChildProcessSpawner, n as make } from "../ChildProcess-
|
|
9
|
-
import { i as hostInterfaceLine } from "../hosted-runtime.layer-
|
|
10
|
-
import { n as BuildManifest } from "../cloud-client.adapter-
|
|
5
|
+
import { t as Path } from "../Path-BRnAx8py.mjs";
|
|
6
|
+
import { F as String, I as Struct, n as ArraySchema, pt as fromJsonString, st as encodeEffect, tt as decodeEffect, v as Int } from "../Schema-O3QUdX3B.mjs";
|
|
7
|
+
import { i as sha256, t as Digest } from "../Digest-CnBYV3Oh.mjs";
|
|
8
|
+
import { a as ChildProcessSpawner, n as make } from "../ChildProcess-UWPy-kPn.mjs";
|
|
9
|
+
import { i as hostInterfaceLine } from "../hosted-runtime.layer-BDXPqzSp.mjs";
|
|
10
|
+
import { n as BuildManifest } from "../cloud-client.adapter-Ce4oyGNh.mjs";
|
|
11
11
|
import { manifestRunner } from "./build-manifest.pure.mjs";
|
|
12
12
|
import { DeployFailedError } from "./deploy-failed.errors.mjs";
|
|
13
13
|
import { build } from "esbuild";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as CloudClient } from "../cloud-client.adapter-
|
|
1
|
+
export { t as CloudClient } from "../cloud-client.adapter-Dln8NW-9.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { W as fnUntraced, ht as mapError } from "../Effect-
|
|
2
|
-
import { G as URLFromString, tt as decodeEffect } from "../Schema-
|
|
1
|
+
import { W as fnUntraced, ht as mapError } from "../Effect-CFIPV2Jg.mjs";
|
|
2
|
+
import { G as URLFromString, tt as decodeEffect } from "../Schema-O3QUdX3B.mjs";
|
|
3
3
|
import { DeployFailedError } from "./deploy-failed.errors.mjs";
|
|
4
4
|
// src/deploy/cloud-url.pure.ts
|
|
5
5
|
const defaultCloudUrl = "https://api.akter.dev";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { d as fromUndefinedOr, x as match } from "../Option-DkxSnBhp.mjs";
|
|
2
|
-
import { t as errorExitCode } from "../Runtime-
|
|
3
|
-
import { F as String, an as optionalKey, v as Int, z as TaggedError } from "../Schema-
|
|
2
|
+
import { t as errorExitCode } from "../Runtime-CyqeMpLX.mjs";
|
|
3
|
+
import { F as String, an as optionalKey, v as Int, z as TaggedError } from "../Schema-O3QUdX3B.mjs";
|
|
4
4
|
import { CliExitError } from "../terminal/cli-exit.errors.mjs";
|
|
5
5
|
// src/deploy/deploy-failed.errors.ts
|
|
6
6
|
var DeployFailedError = class extends TaggedError()("DeployFailedError", {
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { R as some } from "../Array-B4kuTQeW.mjs";
|
|
2
2
|
import { t as match } from "../Boolean-kILIvmhE.mjs";
|
|
3
|
-
import { n as log, t as error } from "../Console-
|
|
4
|
-
import { At as provideContext, B as flatMap, Et as orDie, K as forEach, Kn as
|
|
3
|
+
import { n as log, t as error } from "../Console-DY7H086H.mjs";
|
|
4
|
+
import { At as provideContext, B as flatMap, Et as orDie, Jn as provide, K as forEach, Kn as merge, Lt as retry, M as fail, R as filterOrFail, T as context, U as fn, Un as effect, Xt as succeed, Yt as sleep, d as asVoid, dt as map, et as gen, gn as void_, ht as mapError, in as timeout, jt as provideService, o as andThen, oa as Reference, sa as Service, u as asSome, y as catchIf, ya as pick } from "../Effect-CFIPV2Jg.mjs";
|
|
5
5
|
import { o as type, t as discriminatorsExhaustive } from "../Match-CGPLZYrV.mjs";
|
|
6
6
|
import { b as map$1, d as fromUndefinedOr, h as isNone, nn as isNotUndefined, x as match$1 } from "../Option-DkxSnBhp.mjs";
|
|
7
|
-
import { A as Option, G as URLFromString, I as Struct, mt as is, pt as fromJsonString, st as encodeEffect, tt as decodeEffect } from "../Schema-
|
|
8
|
-
import { C as put, h as bodyUint8Array, w as setHeaders } from "../HttpClientResponse-
|
|
9
|
-
import { a as Deploy, i as CustomerHostname, o as EnvironmentName, t as AppName, u as OrganizationName } from "../cloud-client.adapter-
|
|
7
|
+
import { A as Option, G as URLFromString, I as Struct, mt as is, pt as fromJsonString, st as encodeEffect, tt as decodeEffect } from "../Schema-O3QUdX3B.mjs";
|
|
8
|
+
import { C as put, h as bodyUint8Array, w as setHeaders } from "../HttpClientResponse-CifutXCF.mjs";
|
|
9
|
+
import { a as Deploy, i as CustomerHostname, o as EnvironmentName, t as AppName, u as OrganizationName } from "../cloud-client.adapter-Ce4oyGNh.mjs";
|
|
10
10
|
import { BuildBundle } from "./build-bundle.adapter.mjs";
|
|
11
|
-
import { t as CloudClient } from "../cloud-client.adapter-
|
|
11
|
+
import { t as CloudClient } from "../cloud-client.adapter-Dln8NW-9.mjs";
|
|
12
12
|
import { cloudUrl } from "./cloud-url.pure.mjs";
|
|
13
13
|
import { DeployFailedError } from "./deploy-failed.errors.mjs";
|
|
14
14
|
import { progressFailure, progressMessage, progressWait, reconnectBackoff, requestFailure, retryable } from "./request-failure.pure.mjs";
|