replicas-engine 0.1.340 → 0.1.341
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/src/index.js +14 -3
- package/package.json +1 -1
package/dist/src/index.js
CHANGED
|
@@ -295,7 +295,7 @@ var WORKSPACE_SIZES = ["small", "large"];
|
|
|
295
295
|
var INVALID_WORKSPACE_SIZE_ERROR = `Invalid size: must be one of ${WORKSPACE_SIZES.join(", ")}`;
|
|
296
296
|
|
|
297
297
|
// ../shared/src/e2b.ts
|
|
298
|
-
var E2B_TEMPLATE_NAME = "replicas-sandbox-2026-06-23-
|
|
298
|
+
var E2B_TEMPLATE_NAME = "replicas-sandbox-2026-06-23-v3";
|
|
299
299
|
|
|
300
300
|
// ../shared/src/runtime-env.ts
|
|
301
301
|
function parsePosixEnvFile(content) {
|
|
@@ -7005,6 +7005,7 @@ var ClaudeManager = class _ClaudeManager extends CodingAgentManager {
|
|
|
7005
7005
|
const linearSessionId = ENGINE_ENV.LINEAR_SESSION_ID;
|
|
7006
7006
|
const iterator = response[Symbol.asyncIterator]();
|
|
7007
7007
|
let loopError = null;
|
|
7008
|
+
let suppressLinearResponseFlush = false;
|
|
7008
7009
|
try {
|
|
7009
7010
|
while (true) {
|
|
7010
7011
|
const next = await iterator.next();
|
|
@@ -7013,6 +7014,7 @@ var ClaudeManager = class _ClaudeManager extends CodingAgentManager {
|
|
|
7013
7014
|
if (!msg) break;
|
|
7014
7015
|
const authErrorMessage = _ClaudeManager.detectAuthErrorInMessage(msg);
|
|
7015
7016
|
if (authErrorMessage) {
|
|
7017
|
+
suppressLinearResponseFlush = true;
|
|
7016
7018
|
this.failPendingTurn(new ClaudeAuthError(authErrorMessage));
|
|
7017
7019
|
try {
|
|
7018
7020
|
response.close();
|
|
@@ -7023,6 +7025,7 @@ var ClaudeManager = class _ClaudeManager extends CodingAgentManager {
|
|
|
7023
7025
|
}
|
|
7024
7026
|
const transientErrorMessage = _ClaudeManager.detectTransientTurnErrorInMessage(msg);
|
|
7025
7027
|
if (transientErrorMessage) {
|
|
7028
|
+
suppressLinearResponseFlush = true;
|
|
7026
7029
|
const sawActivity = this.pendingTurn?.sawActivity ?? false;
|
|
7027
7030
|
this.failPendingTurn(new ClaudeTransientTurnError(transientErrorMessage, sawActivity));
|
|
7028
7031
|
try {
|
|
@@ -7050,13 +7053,21 @@ var ClaudeManager = class _ClaudeManager extends CodingAgentManager {
|
|
|
7050
7053
|
}
|
|
7051
7054
|
} catch (error) {
|
|
7052
7055
|
loopError = error;
|
|
7056
|
+
if (_ClaudeManager.isTransientTurnError(error) || _ClaudeManager.isAuthError(error)) {
|
|
7057
|
+
suppressLinearResponseFlush = true;
|
|
7058
|
+
}
|
|
7053
7059
|
if (!_ClaudeManager.isTransientTurnError(error)) {
|
|
7054
7060
|
console.error("[ClaudeManager] Session loop crashed:", error);
|
|
7055
7061
|
}
|
|
7056
7062
|
} finally {
|
|
7057
|
-
this.sessionLinearForwarder?.flushThoughtAsResponse();
|
|
7058
7063
|
const pending = this.pendingTurn;
|
|
7059
7064
|
const pendingError = loopError ? pending?.sawActivity && _ClaudeManager.isTransientTurnError(loopError) ? new ClaudeTransientTurnError("Claude session ended unexpectedly mid-response", true) : loopError : pending && !pending.sawActivity ? new ClaudeTransientTurnError("Claude session ended unexpectedly before producing a response") : new Error("Claude session ended unexpectedly");
|
|
7065
|
+
if (_ClaudeManager.isTransientTurnError(pendingError) || _ClaudeManager.isAuthError(pendingError)) {
|
|
7066
|
+
suppressLinearResponseFlush = true;
|
|
7067
|
+
}
|
|
7068
|
+
if (!suppressLinearResponseFlush) {
|
|
7069
|
+
this.sessionLinearForwarder?.flushThoughtAsResponse();
|
|
7070
|
+
}
|
|
7060
7071
|
this.failPendingTurn(pendingError);
|
|
7061
7072
|
if (this.activeQuery === response) {
|
|
7062
7073
|
this.clearSessionState();
|
|
@@ -7537,7 +7548,7 @@ var AspClient = class {
|
|
|
7537
7548
|
// src/managers/codex-asp/app-server-process.ts
|
|
7538
7549
|
var DEFAULT_CODEX_BINARY = "codex";
|
|
7539
7550
|
var DEFAULT_CODEX_ARGS = ["app-server", "--listen", "stdio://"];
|
|
7540
|
-
var ENGINE_PACKAGE_VERSION = "0.1.
|
|
7551
|
+
var ENGINE_PACKAGE_VERSION = "0.1.341";
|
|
7541
7552
|
var INITIALIZE_METHOD = "initialize";
|
|
7542
7553
|
var INITIALIZED_NOTIFICATION = "initialized";
|
|
7543
7554
|
var ACCOUNT_LOGIN_START_METHOD = "account/login/start";
|