fix(app): viewers open server sequences with proxies, the editor follows the sign-in
An account without Edit is offered Open with proxies on a server that keeps projects and checks nothing out, since it could never push. The editor of a server's workspace project connects with the sign-in in use at each call, so a project opened signed out renders once signed in; SyncHost tells every session start and stop so workspace projects read their state again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
cdd29f8e84
commit
48d8158fd7
8 files changed
+165
-24
No files matched your search
@@ -726,12 +726,15 @@ public sealed class SequenceViewModel : SectionViewModel
|
||||
{
|
||||
TakeRequest(remoteId);
|
||||
workspace.Remember(remoteId, entry.ProjectId);
|
||||
// Its analyses and renders travel on a connection of the signed-in session, when that is the project's server.
|
||||
var api = string.Equals(sync.Server, entry.Home.Server, StringComparison.OrdinalIgnoreCase) ? sync.ConnectEditor() : null;
|
||||
return new ServerOpen((new WorkspaceSequenceSource(workspace.Sync, entry.ProjectId, db, decoder, services.Engine, new WorkspaceServerHome(api)),
|
||||
entry.SequenceTitle));
|
||||
// Its analyses and renders travel on a connection of the signed-in session, when that is the project's server:
|
||||
// made again whenever the sign-in changes, so a project opened signed out renders once signed in.
|
||||
var server = entry.Home.Server;
|
||||
var editorHome = new WorkspaceServerHome(() => string.Equals(sync.Server, server, StringComparison.OrdinalIgnoreCase) ? sync.ConnectEditor() : null,
|
||||
() => sync.Session);
|
||||
return new ServerOpen((new WorkspaceSequenceSource(workspace.Sync, entry.ProjectId, db, decoder, services.Engine, editorHome), entry.SequenceTitle));
|
||||
}
|
||||
if (sync.ServerHome(remoteId) is not { } home) return null;
|
||||
// An account that may not edit checks nothing out: it is shown with proxies, read-only, as on an older server.
|
||||
if (!sync.Policy.CanEdit || sync.ServerHome(remoteId) is not { } home) return null;
|
||||
TakeRequest(remoteId);
|
||||
try
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user