fix: nil Preamble on restored paused sessions
The persist path created agents with &Runtime{} (nil Preamble).
If a prompt arrived before resume rebuilt the runtime, Preamble.Set
panicked. Initialize with an empty Preamble.
This commit is contained in:
parent
6d0a080e65
commit
a8fd7a658f
|
|
@ -204,7 +204,7 @@ func restoreMultiAgentSession(ps *PersistedSession) (*RestoredSession, error) {
|
|||
history := agent.RestoreHistoryFromMessages(pa.Messages)
|
||||
ag := agent.NewAgent(agent.AgentParams{
|
||||
History: history,
|
||||
Runtime: &agent.Runtime{},
|
||||
Runtime: &agent.Runtime{Preamble: &agent.Preamble{}},
|
||||
Profile: pa.Profile,
|
||||
AgentsDir: pkgAgentsDir,
|
||||
ID: pa.ID,
|
||||
|
|
|
|||
Loading…
Reference in New Issue