Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: add credentialContexts to GlobalOptions #53

Merged
merged 2 commits into from
Sep 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions gptscript/opts.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ def __init__(self,
confirm: bool = False,
prompt: bool = False,
credentialOverrides: list[str] = None,
credentialContexts: list[str] = None,
location: str = "",
env: list[str] = None,
forceSequential: bool = False,
Expand All @@ -76,6 +77,7 @@ def __init__(self,
self.confirm = confirm
self.prompt = prompt
self.credentialOverrides = credentialOverrides
self.credentialContexts = credentialContexts
self.location = location
self.env = env
self.forceSequential = forceSequential
Expand All @@ -92,6 +94,7 @@ def merge_global_opts(self, other: GlobalOptions) -> Self:
cp.confirm = self.confirm
cp.prompt = self.prompt
cp.credentialOverrides = self.credentialOverrides
cp.credentialContexts = self.credentialContexts
cp.location = self.location
cp.env = self.env
cp.forceSequential = self.forceSequential
Expand Down
2 changes: 1 addition & 1 deletion tests/fixtures/global-tools.gpt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Runbook 3

---
Name: tool_1
Global Tools: github.com/gptscript-ai/knowledge, github.com/drpebcak/duckdb, github.com/gptscript-ai/browser, github.com/gptscript-ai/browser-search/google, github.com/gptscript-ai/browser-search/google-question-answerer
Global Tools: github.com/drpebcak/duckdb, github.com/gptscript-ai/browser, github.com/gptscript-ai/browser-search/google, github.com/gptscript-ai/browser-search/google-question-answerer
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It bothers me that so many of these tools have been moved and/or archived haha.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lol I didn't even look at the rest of the list after I removed knowledge


Say Hello!

Expand Down