@letta-ai/letta-code 0.24.11 → 0.24.12

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 (2) hide show
  1. package/letta.js +9 -4
  2. package/package.json +1 -1
package/letta.js CHANGED
@@ -7600,7 +7600,7 @@ var package_default;
7600
7600
  var init_package = __esm(() => {
7601
7601
  package_default = {
7602
7602
  name: "@letta-ai/letta-code",
7603
- version: "0.24.11",
7603
+ version: "0.24.12",
7604
7604
  description: "Letta Code is a CLI tool for interacting with stateful Letta agents from the terminal.",
7605
7605
  type: "module",
7606
7606
  bin: {
@@ -44253,6 +44253,9 @@ function readTrimmedString(value) {
44253
44253
  const trimmed = value.trim();
44254
44254
  return trimmed.length > 0 ? trimmed : null;
44255
44255
  }
44256
+ function escapeDiscordInlineCode(value) {
44257
+ return value.replace(/`/g, "\\`").replace(/\r?\n/g, " ");
44258
+ }
44256
44259
  function extractErrorDetail(error) {
44257
44260
  const e = error;
44258
44261
  return readTrimmedString(e?.error?.error?.detail) || readTrimmedString(e?.error?.error?.message) || readTrimmedString(e?.error?.detail) || readTrimmedString(e?.error?.message) || readTrimmedString(e?.message) || String(error);
@@ -44268,7 +44271,8 @@ function formatDiscordDeliveryError(error) {
44268
44271
  }
44269
44272
  const MAX_DETAIL = 200;
44270
44273
  const truncated = detail.length > MAX_DETAIL ? `${detail.slice(0, MAX_DETAIL)}…` : detail;
44271
- return `Sorry, something went wrong while forwarding your message: \`${truncated}\``;
44274
+ const safeDetail = escapeDiscordInlineCode(truncated);
44275
+ return `Sorry, something went wrong while forwarding your message: \`${safeDetail}\``;
44272
44276
  }
44273
44277
 
44274
44278
  // src/channels/discord/media.ts
@@ -44491,6 +44495,7 @@ async function notifyDiscordDeliveryError(message, error) {
44491
44495
  return;
44492
44496
  const reply = buildDiscordReplyOptions(message.id, message.channelId);
44493
44497
  await message.channel.send({
44498
+ allowedMentions: { parse: [] },
44494
44499
  content: formatDiscordDeliveryError(error),
44495
44500
  ...reply ?? {}
44496
44501
  });
@@ -165993,7 +165998,7 @@ async function runListenSubcommand(argv) {
165993
165998
  try {
165994
165999
  const deviceId = settingsManager.getOrCreateDeviceId();
165995
166000
  const startupMode = await resolveListenerStartupMode(channelNames);
165996
- if (startupMode.kind === "unsupported-self-hosted") {
166001
+ if (startupMode.kind === "unsupported-self-hosted" && process.env.IGNORE_SELF_HOSTED_LISTENER_ERROR !== "1") {
165997
166002
  console.error(`Self-hosted listener registration is not available for ${startupMode.serverUrl}.`);
165998
166003
  console.error("Start with --channels to run local channel adapters, or unset LETTA_BASE_URL to use Letta API remote environments.");
165999
166004
  await flushListenerTelemetryEnd("listener_self_hosted_no_channels");
@@ -170442,4 +170447,4 @@ Error during initialization: ${message}`);
170442
170447
  }
170443
170448
  main();
170444
170449
 
170445
- //# debugId=CAC8BC0810B48AAB64756E2164756E21
170450
+ //# debugId=EFD77CA58FDB877B64756E2164756E21
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@letta-ai/letta-code",
3
- "version": "0.24.11",
3
+ "version": "0.24.12",
4
4
  "description": "Letta Code is a CLI tool for interacting with stateful Letta agents from the terminal.",
5
5
  "type": "module",
6
6
  "bin": {