mirror of
https://github.com/Ryder-Sun/Meldwork.git
synced 2026-11-07 06:56:03 -10:00
fix: retain agent readiness after transient auth failures
This commit is contained in:
1 parent
1c9aabbf8e
commit
d47bff5433
3 files changed
+5
-4
No files matched your search
@@ -220,7 +220,8 @@ class LocalWorkspaceAgentCatalog {
|
||||
checkedAt: this.now(),
|
||||
}
|
||||
const agent = this.detectedAgents().find(item => item.kind === kind)
|
||||
if (agent && agent.availabilitySource !== 'provider-credential-unavailable') {
|
||||
if (agent && agent.availabilitySource !== 'provider-credential-unavailable'
|
||||
&& !(credentialState === 'unknown' && agent.authenticated === true)) {
|
||||
agent.credentialState = credentialState
|
||||
agent.versionIdentified = agentVersionIdentified(agent)
|
||||
agent.compatible = agentCompatible(agent)
|
||||
|
||||
@@ -1952,7 +1952,7 @@ class LocalWorkspaceAgentInvocation {
|
||||
? agentStoppedError()
|
||||
: caughtError
|
||||
if (credentialFailure(error) && context.deferCredentialFailure !== true) {
|
||||
this.markRuntimeCredential(kind, 'missing')
|
||||
this.markRuntimeCredential(kind, 'unknown')
|
||||
}
|
||||
const status = parentTimedOut
|
||||
? 'timeout'
|
||||
|
||||
@@ -522,10 +522,10 @@ class LocalWorkspaceAutoRunner {
|
||||
}
|
||||
if (control) return { result: null, removed: false, control, error }
|
||||
if (!unauthorizedFailure(error)) {
|
||||
if (credentialFailure(error)) this.markRuntimeCredential(kind, 'missing')
|
||||
if (credentialFailure(error)) this.markRuntimeCredential(kind, 'unknown')
|
||||
throw error
|
||||
}
|
||||
this.markRuntimeCredential(kind, 'missing')
|
||||
this.markRuntimeCredential(kind, 'unknown')
|
||||
this.recordAttempt(group, controller, {
|
||||
agentKind: kind,
|
||||
phase,
|
||||
|
||||
Reference in new issue
Block a user