Skip to content

Commit

Permalink
Merge pull request #118 from StrongMonkey/use-milliseconds
Browse files Browse the repository at this point in the history
Fix: use milliseconds to record state file
  • Loading branch information
StrongMonkey authored Mar 6, 2024
2 parents e6912cf + 02d0a3b commit 1fb78c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/runner/runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,6 @@ func recordStateMessage(state *engine.State) error {
return err
}

filename := filepath.Join(tmpdir, fmt.Sprintf("gptscript-state-%v-%v", hostname, time.Now().Unix()))
filename := filepath.Join(tmpdir, fmt.Sprintf("gptscript-state-%v-%v", hostname, time.Now().UnixMilli()))
return os.WriteFile(filename, data, 0444)
}

0 comments on commit 1fb78c2

Please sign in to comment.