@t2000/cli 10.24.0 → 10.25.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.
package/dist/index.js CHANGED
@@ -30810,6 +30810,20 @@ function cancelOpenJob(base, signer, openingId) {
30810
30810
  openingId: openingId.trim()
30811
30811
  });
30812
30812
  }
30813
+ async function resolveCreatedObjectId(client, digest, marker, opts = {}) {
30814
+ try {
30815
+ const result = await client.core.waitForTransaction({
30816
+ digest,
30817
+ include: { objectTypes: true },
30818
+ timeout: opts.timeoutMs ?? 15e3
30819
+ });
30820
+ const txn = result.$kind === "Transaction" ? result.Transaction : result.FailedTransaction;
30821
+ const types = txn.objectTypes ?? {};
30822
+ return Object.keys(types).find((id) => types[id]?.includes(marker));
30823
+ } catch {
30824
+ return void 0;
30825
+ }
30826
+ }
30813
30827
  init_coinSelection();
30814
30828
  init_cetus_swap();
30815
30829
  init_coinSelection();
@@ -35590,20 +35604,8 @@ function fmtLeft(ms) {
35590
35604
  if (hours >= 1) return `${hours}h`;
35591
35605
  return `${Math.max(1, Math.floor(left / 6e4))}m`;
35592
35606
  }
35593
- async function resolveCreated(digest, marker) {
35594
- try {
35595
- const client = getSuiClient();
35596
- const result = await client.core.waitForTransaction({
35597
- digest,
35598
- include: { objectTypes: true },
35599
- timeout: 15e3
35600
- });
35601
- const txn = result.$kind === "Transaction" ? result.Transaction : result.FailedTransaction;
35602
- const types = txn.objectTypes ?? {};
35603
- return Object.keys(types).find((id) => types[id]?.includes(marker));
35604
- } catch {
35605
- return void 0;
35606
- }
35607
+ function resolveCreated(digest, marker) {
35608
+ return resolveCreatedObjectId(getSuiClient(), digest, marker);
35607
35609
  }
35608
35610
  function registerOpenVerbs(group) {
35609
35611
  group.command("open").description("Open \u2014 post the job to the public board with no ASP picked (buyer); ESCROWS the budget on-chain now, first claim starts work").requiredOption("--title <text>", "The job's public name (up to 80 chars)").requiredOption("--brief <file-or-text>", "What you want delivered \u2014 PUBLIC, every ASP on the board reads it").requiredOption("--max <usdc>", `Budget escrowed AT POST (max ${MAX_JOB_USDC})`).option("--sla <duration>", "Delivery window once claimed (e.g. 30m, 24h, 7d)", "24h").option("--open-for <duration>", "How long the posting stays claimable before it refunds", "24h").option("--key <path>", "Custom wallet path (default ~/.t2000/wallet.key)").option("--api <url>", `API base URL (default ${DEFAULT_API_BASE6})`).action(