@lucid-agents/taskmarket 1.50.0 → 1.52.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/dist/agent-compatibility.json +1 -1
  2. package/dist/{api-SXHSD3WO.js → api-Z62WOOLX.js} +2 -2
  3. package/dist/{channels-4YOMV7R7.js → channels-GBQLRNED.js} +4 -4
  4. package/dist/{chunk-V5S4LCIE.js → chunk-523X35HE.js} +4 -4
  5. package/dist/{chunk-6VZBAHQC.js → chunk-6UDGOZHP.js} +3 -3
  6. package/dist/{chunk-C7557KRB.js → chunk-G4MAYAZW.js} +13 -25
  7. package/dist/{chunk-EJ7KUYME.js → chunk-JAFX6DHV.js} +3725 -2926
  8. package/dist/{chunk-EYHXTVYK.js → chunk-K3Y73YWH.js} +2 -2
  9. package/dist/{chunk-M5WTLXDY.js → chunk-KU66VTU6.js} +1 -1
  10. package/dist/{chunk-PZI3QQO4.js → chunk-LZ2P3FIL.js} +5 -5
  11. package/dist/{chunk-CGUFHUIV.js → chunk-N5L4URHF.js} +1 -1
  12. package/dist/{chunk-FGW2NNPQ.js → chunk-PXQP62WF.js} +3 -3
  13. package/dist/{chunk-MY5CD4PT.js → chunk-QSOEZINA.js} +8 -8
  14. package/dist/{chunk-YBSZTSJE.js → chunk-RMK5EAPR.js} +1 -1
  15. package/dist/{chunk-EVCG557X.js → chunk-XREEFYEQ.js} +6 -2
  16. package/dist/{doctor-FACAMASV.js → doctor-3LW4N6KW.js} +9 -9
  17. package/dist/index.js +1964 -300
  18. package/dist/{launch-K5666QYB.js → launch-2YOUARKA.js} +11 -11
  19. package/dist/pi-extensions/xgate.cjs +19 -10
  20. package/dist/{read-auth-EFE6NQFG.js → read-auth-IBCYKPKD.js} +3 -3
  21. package/dist/{reconcile-Q4MJXXR3.js → reconcile-7DVTUPJ6.js} +4 -4
  22. package/dist/{status-YKFKGTMQ.js → status-3GNXUWOL.js} +9 -9
  23. package/dist/{sync-pull-AN2M344W.js → sync-pull-MIEB5XAF.js} +4 -4
  24. package/dist/{task-access-grants-MN5WXHHQ.js → task-access-grants-5B3CSCP4.js} +2 -2
  25. package/package.json +3 -2
@@ -1,5 +1,5 @@
1
1
  {
2
- "taskmarket": "1.50.0",
2
+ "taskmarket": "1.52.0",
3
3
  "manifestVersion": 1,
4
4
  "pi": {
5
5
  "package": "@earendil-works/pi-coding-agent",
@@ -14,8 +14,8 @@ import {
14
14
  parseFailureBody,
15
15
  readFailureBody,
16
16
  withErrorContext
17
- } from "./chunk-EVCG557X.js";
18
- import "./chunk-EJ7KUYME.js";
17
+ } from "./chunk-XREEFYEQ.js";
18
+ import "./chunk-JAFX6DHV.js";
19
19
  import "./chunk-S7SJMJ2I.js";
20
20
  export {
21
21
  ApiError,
@@ -10,10 +10,10 @@ import {
10
10
  selectRail,
11
11
  uncertainPurchases,
12
12
  withdrawalHatch
13
- } from "./chunk-FGW2NNPQ.js";
14
- import "./chunk-C7557KRB.js";
15
- import "./chunk-EVCG557X.js";
16
- import "./chunk-EJ7KUYME.js";
13
+ } from "./chunk-PXQP62WF.js";
14
+ import "./chunk-G4MAYAZW.js";
15
+ import "./chunk-XREEFYEQ.js";
16
+ import "./chunk-JAFX6DHV.js";
17
17
  import "./chunk-YM4S6IE4.js";
18
18
  import "./chunk-XJOB4NMV.js";
19
19
  import "./chunk-S7SJMJ2I.js";
@@ -1,7 +1,7 @@
1
1
  import { createRequire as __tmCreateRequire } from 'node:module'; import { fileURLToPath as __tmFileURLToPath } from 'node:url'; import { dirname as __tmDirname } from 'node:path'; const require = __tmCreateRequire(import.meta.url); const __tmFilename = __tmFileURLToPath(import.meta.url); const __tmDirnameValue = __tmDirname(__tmFilename);
2
2
  import {
3
3
  signReadAuth
4
- } from "./chunk-EYHXTVYK.js";
4
+ } from "./chunk-K3Y73YWH.js";
5
5
  import {
6
6
  MPP_TEMPO_CHARGE_SCHEME,
7
7
  X402PayError,
@@ -20,7 +20,7 @@ import {
20
20
  readMppTempoChallenge,
21
21
  reconcileX402Payment,
22
22
  withX402FileLock
23
- } from "./chunk-C7557KRB.js";
23
+ } from "./chunk-G4MAYAZW.js";
24
24
  import {
25
25
  ApiError,
26
26
  apiGet,
@@ -41,7 +41,7 @@ import {
41
41
  withChainId,
42
42
  withIdempotentWrite,
43
43
  withTapSignature
44
- } from "./chunk-EVCG557X.js";
44
+ } from "./chunk-XREEFYEQ.js";
45
45
  import {
46
46
  ComputeCreditBuyOutputSchema,
47
47
  ComputeCreditPricingSchema,
@@ -49,7 +49,7 @@ import {
49
49
  IntentStatusResponseSchema,
50
50
  apiErrorEnvelopeOf,
51
51
  getTaskmarketHome
52
- } from "./chunk-EJ7KUYME.js";
52
+ } from "./chunk-JAFX6DHV.js";
53
53
 
54
54
  // src/lib/x402-fee.ts
55
55
  import { randomUUID as randomUUID4 } from "crypto";
@@ -8,7 +8,7 @@ import {
8
8
  unsafeHostPath,
9
9
  withFileLock,
10
10
  writeAtomic
11
- } from "./chunk-YBSZTSJE.js";
11
+ } from "./chunk-RMK5EAPR.js";
12
12
  import {
13
13
  buyComputeCredit,
14
14
  fetchComputePricing,
@@ -16,10 +16,10 @@ import {
16
16
  loadComputeCreditConfig,
17
17
  onComputeBalanceObserved,
18
18
  readComputeCreditStatus
19
- } from "./chunk-V5S4LCIE.js";
19
+ } from "./chunk-523X35HE.js";
20
20
  import {
21
21
  getTaskmarketHome
22
- } from "./chunk-EJ7KUYME.js";
22
+ } from "./chunk-JAFX6DHV.js";
23
23
  import {
24
24
  AgentLaunchError
25
25
  } from "./chunk-YM4S6IE4.js";
@@ -11,7 +11,7 @@ import {
11
11
  getTaskmarketHome,
12
12
  mppAttributionMemo,
13
13
  parseMppChallenge
14
- } from "./chunk-EJ7KUYME.js";
14
+ } from "./chunk-JAFX6DHV.js";
15
15
 
16
16
  // ../../packages/x402-payer/dist/api.js
17
17
  var X402_PAYER_API_VERSION = 1;
@@ -4284,6 +4284,16 @@ function x402FailureReason(headers) {
4284
4284
  }
4285
4285
  return void 0;
4286
4286
  }
4287
+ function sendPrepared(fetchImpl, prepared, headers, signal) {
4288
+ const init = {
4289
+ method: prepared.method,
4290
+ headers,
4291
+ body: prepared.body,
4292
+ redirect: "error",
4293
+ signal
4294
+ };
4295
+ return fetchImpl(new Request(prepared.url, init), init);
4296
+ }
4287
4297
  function x402ChallengeBodyError(body) {
4288
4298
  try {
4289
4299
  const value = JSON.parse(Buffer.from(body).toString("utf8"));
@@ -4453,17 +4463,7 @@ async function runX402Exchange(runtime, input, options, context) {
4453
4463
  throw aborted();
4454
4464
  let response;
4455
4465
  try {
4456
- response = await fetchImpl(
4457
- new Request(prepared.url, {
4458
- method: prepared.method,
4459
- headers: unpaidHeaders,
4460
- body: prepared.body,
4461
- redirect: "error",
4462
- signal
4463
- }),
4464
- // See the paid request below: without it, a garbage collection can cut off the abort.
4465
- { signal }
4466
- );
4466
+ response = await sendPrepared(fetchImpl, prepared, unpaidHeaders, signal);
4467
4467
  } catch (error) {
4468
4468
  if (signal.aborted)
4469
4469
  throw aborted();
@@ -4817,19 +4817,7 @@ async function runX402Exchange(runtime, input, options, context) {
4817
4817
  await transition({ state: "dispatched" });
4818
4818
  let paid;
4819
4819
  try {
4820
- paid = await fetchImpl(
4821
- new Request(prepared.url, {
4822
- method: prepared.method,
4823
- headers: paidHeaders,
4824
- body: prepared.body,
4825
- redirect: "error",
4826
- signal
4827
- }),
4828
- // The signal again, so fetch follows it directly. A Request follows its signal through an
4829
- // AbortController that only the Request holds strongly: once fetch has copied it, a garbage
4830
- // collection drops that controller, and aborting `signal` no longer cancels the request.
4831
- { signal }
4832
- );
4820
+ paid = await sendPrepared(fetchImpl, prepared, paidHeaders, signal);
4833
4821
  } catch (error) {
4834
4822
  await transition({ state: "unknown", error: errorMessage(error) });
4835
4823
  throw fail("outcome_uncertain", X402_OUTCOME_UNKNOWN_MESSAGE, { cause: error, pending: true });