Skip to content

Commit 01b5dbe

Browse files
committed
fix: log meta error instead of failing tab create
When the auxiliary meta update fails after a successful tab creation, log the error with context but return the tabId. This avoids orphan tabs from retry loops that would otherwise see a failed creation despite the tab being persisted. Users can re-apply meta with wsh setmeta if needed.
1 parent a6b9005 commit 01b5dbe

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

pkg/wshrpc/wshserver/wshserver.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,8 @@ func (ws *WshServer) CreateTabCommand(ctx context.Context, data wshrpc.CommandCr
222222
metaAny[k] = v
223223
}
224224
if metaErr := wstore.UpdateObjectMeta(ctx, tabORef, metaAny, false); metaErr != nil {
225-
return "", fmt.Errorf("error setting tab meta: %w", metaErr)
225+
log.Printf("CreateTabCommand: tab %s created but meta update failed: %v", tabId, metaErr)
226+
// Tab creation succeeded; meta is auxiliary and can be re-applied via wsh setmeta.
226227
}
227228
}
228229
updates := waveobj.ContextGetUpdatesRtn(ctx)

0 commit comments

Comments
 (0)