Skip to content

Commit

Permalink
bug: fix workspace sdk use outside of otto
Browse files Browse the repository at this point in the history
  • Loading branch information
ibuildthecloud committed Oct 29, 2024
1 parent 9d30b26 commit 8180c26
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pkg/gptscript/gptscript.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import (
context2 "github.com/gptscript-ai/gptscript/pkg/context"
"github.com/gptscript-ai/gptscript/pkg/credentials"
"github.com/gptscript-ai/gptscript/pkg/engine"
"github.com/gptscript-ai/gptscript/pkg/hash"
"github.com/gptscript-ai/gptscript/pkg/llm"
"github.com/gptscript-ai/gptscript/pkg/monitor"
"github.com/gptscript-ai/gptscript/pkg/mvl"
Expand Down Expand Up @@ -201,7 +200,7 @@ func (g *GPTScript) getEnv(env []string) ([]string, error) {
return nil, err
}
if id == "" {
id = hash.ID(g.WorkspacePath)
id = "directory://" + g.WorkspacePath
}
return slices.Concat(g.ExtraEnv, env, []string{
fmt.Sprintf("GPTSCRIPT_WORKSPACE_DIR=%s", g.WorkspacePath),
Expand Down

0 comments on commit 8180c26

Please sign in to comment.