Skip to content

Commit

Permalink
tesy
Browse files Browse the repository at this point in the history
  • Loading branch information
hirenko-v committed Sep 28, 2024
1 parent 1743bce commit 4861971
Showing 1 changed file with 8 additions and 13 deletions.
21 changes: 8 additions & 13 deletions cmd/job/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,24 +116,19 @@ func (e *MsgExecutor) Execute(ctx context.Context, in executor.ExecuteInput) (ex

// Parse the action and value from the command
action, value := parseCommand(in.Command)

sessionID, ok := ctx.Value("sessionID").(string)
sessionID := "default_session" // Replace with an actual identifier if available
var ok bool
sessionID, ok = ctx.Value("sessionID").(string)
if ok {
return executor.ExecuteOutput{
Message: api.NewCodeBlockMessage(fmt.Sprintf("Session ID is %s", sessionID), true),
Message: api.NewCodeBlockMessage(msg, true),

Check failure on line 124 in cmd/job/main.go

View workflow job for this annotation

GitHub Actions / Release

undefined: msg
}, nil
// Initialize session state if not already present
// if _, ok := e.state[sessionID]; !ok {
// e.state[sessionID] = make(map[string]string)
// }
}

// sessionID := "default_session" // Replace with an actual identifier if available

// Initialize session state if not already present
// if _, ok := e.state[sessionID]; !ok {
// e.state[sessionID] = make(map[string]string)
// }
// Initialize session state if not already present
if _, ok = e.state[sessionID]; !ok {
e.state[sessionID] = make(map[string]string)
}
switch action {
case "select_first":
if e.state[sessionID]["first"] != value {
Expand Down

0 comments on commit 4861971

Please sign in to comment.