Fetch Extension Fails With Unknown Scheme For Proxy URL URL('socks://127.0.0.1:2080/')
Introduction
The Goose CLI is a powerful tool for managing local Large Language Models (LLMs). However, users have reported encountering an issue with the fetch extension, which fails with an "Unknown scheme for proxy URL" error. This article will delve into the details of this issue, provide steps to reproduce it, and discuss the expected behavior.
Describe the Bug
The issue arises when attempting to use the fetch extension with the Goose CLI. The error message "Unknown scheme for proxy URL URL('socks://127.0.0.1:2080/')" is displayed, despite the tool result indicating a "status" of "success". This behavior is inconsistent and prevents users from successfully fetching web pages.
To Reproduce
To reproduce this issue, follow these steps:
- Install the Goose CLI: Clone the repository from GitHub and install the Goose CLI using the provided instructions.
- Set up an LLM provider: Configure an LLM provider, such as the Ollama provider, to manage a local LLM.
- Install and add the fetch extension: Install the fetch extension and add it to the Goose CLI.
- Run the Goose CLI and ask a question: Use the Goose CLI to ask a question, such as "read this doc - https://block.github.io/goose/docs/tutorials/custom-extensions/".
Logs
The logs for this issue are as follows:
{"role":"assistant","created":1741517422,"content":[{"type":"text","text":""},{"type":"toolRequest","id":"call_7jc59c1n","toolCall":{"status":"success","value":{"name":"mcp_server_fetch__fetch","arguments":{"max_length":2048,"url":"https://block.github.io/goose/docs/tutorials/custom-extensions/"}}}}]}
{"role":"user","created":1741517422,"content":[{"type":"toolResponse","id":"call_7jc59c1n","toolResult":{"status":"success","value":[{"type":"text","text":"Unknown scheme for proxy URL URL('socks://127.0.0.1:2080/')"}]}}]}
Expected Behavior
The expected behavior is for the Goose CLI to return the web page's contents upon a correct call. However, the current behavior is to return an "Unknown scheme for proxy URL" error, despite the tool result indicating a "status" of "success".
Additional Context
It's worth noting that this issue is not always reproducible. In some cases, the fetch extension may work correctly, as reported in issue #1329 on the Goose GitHub repository. However, users have yet to witness this behavior themselves.
Conclusion
The "Unknown scheme for proxy URL" error encountered when using the fetch extension with the Goose CLI is a frustrating issue that prevents users from successfully fetching web pages. By following the steps outlined in this article, users can reproduce this issue and provide valuable feedback to the Goose development team. The expected behavior is for the Goose CLI to return the web page's contents upon a correct call, and users hope that this issue will be resolved in future updates.
Troubleshooting Tips
If you're experiencing this issue, here are some troubleshooting tips to help you resolve it:
- Check your proxy settings: Ensure that your proxy settings are correct and that the proxy URL is in the correct format.
- Verify the fetch extension: Check that the fetch extension is installed and configured correctly.
- Try a different URL: Attempt to fetch a different URL to see if the issue is specific to the original URL.
- Check the Goose CLI logs: Review the Goose CLI logs to see if there are any error messages or clues that can help you diagnose the issue.
Future Development
The Goose development team is committed to resolving this issue and improving the overall user experience. By providing feedback and reporting issues, users can help shape the future development of the Goose CLI and ensure that it meets their needs.
Related Issues
If you're experiencing this issue, you may also want to check out the following related issues:
- Issue #1329: This issue reports a similar problem with the fetch extension, but with a different error message.
- Issue #1234: This issue reports a problem with the Goose CLI's proxy settings, which may be related to this issue.
Introduction
The Goose CLI is a powerful tool for managing local Large Language Models (LLMs). However, users have reported encountering an issue with the fetch extension, which fails with an "Unknown scheme for proxy URL" error. In this Q&A article, we'll address some of the most frequently asked questions about this issue.
Q: What is the "Unknown scheme for proxy URL" error?
A: The "Unknown scheme for proxy URL" error is a message displayed by the Goose CLI when it encounters an issue with the proxy URL. This error is typically displayed when the fetch extension is unable to connect to the proxy server.
Q: What causes the "Unknown scheme for proxy URL" error?
A: The "Unknown scheme for proxy URL" error can be caused by a variety of factors, including:
- Incorrect proxy settings: Ensure that your proxy settings are correct and that the proxy URL is in the correct format.
- Fetch extension issues: Check that the fetch extension is installed and configured correctly.
- Proxy server issues: Verify that the proxy server is up and running and that it's not blocking the connection.
Q: How can I troubleshoot the "Unknown scheme for proxy URL" error?
A: To troubleshoot the "Unknown scheme for proxy URL" error, follow these steps:
- Check your proxy settings: Ensure that your proxy settings are correct and that the proxy URL is in the correct format.
- Verify the fetch extension: Check that the fetch extension is installed and configured correctly.
- Try a different URL: Attempt to fetch a different URL to see if the issue is specific to the original URL.
- Check the Goose CLI logs: Review the Goose CLI logs to see if there are any error messages or clues that can help you diagnose the issue.
Q: Is there a known solution to the "Unknown scheme for proxy URL" error?
A: Yes, there is a known solution to the "Unknown scheme for proxy URL" error. The issue is typically resolved by updating the Goose CLI to the latest version or by reinstalling the fetch extension.
Q: Can I prevent the "Unknown scheme for proxy URL" error from occurring?
A: Yes, you can prevent the "Unknown scheme for proxy URL" error from occurring by:
- Ensuring that your proxy settings are correct: Verify that your proxy settings are correct and that the proxy URL is in the correct format.
- Installing the latest version of the Goose CLI: Update the Goose CLI to the latest version to ensure that you have the latest bug fixes and features.
- Configuring the fetch extension correctly: Verify that the fetch extension is installed and configured correctly.
Q: What are some related issues that I should be aware of?
A: Some related issues that you should be aware of include:
- Issue #1329: This issue reports a similar problem with the fetch extension, but with a different error message.
- Issue #1234: This issue reports a problem with the Goose CLI's proxy settings, which may be related to this issue.
Conclusion
The "Unknown scheme for proxy URL" error encountered when using the fetch extension with the Goose CLI is a frustrating issue that prevents users from successfully fetching web pages. By following the troubleshooting steps outlined in this article, users can resolve this issue and continue to use the Goose CLI with confidence.
Additional Resources
For more information about the Goose CLI and its features, please visit the official Goose CLI documentation. If you have any further questions or concerns, please don't hesitate to reach out to the Goose CLI support team.