-
Notifications
You must be signed in to change notification settings - Fork 16.6k
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
community[minor]: add proxy support to RecursiveUrlLoader #27364
Conversation
…introducing the proxies parameter to allow the use of specified proxy servers in requests.
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -313,6 +314,16 @@ def simple_metadata_extractor( | |||
encoding, unless the `encoding` argument has already been explicitly set. | |||
encoding: The encoding of the response. If manually set, the encoding will be | |||
set to given value, regardless of the `autoset_encoding` argument. | |||
proxies: A dictionary mapping protocol names to the proxy URLs to be used for requests. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, any chance you'd be willing to add a sentence to the security note so that folks know they can specify proxies?
hi @eyurtsev , I just fixed a lint check error in my commit and added a note in the security document. Please check this commit. |
@ccq1 you can auto format like this: cd langchain/libs/community
make format you'll need to set up the environment with ruff ( |
Description
This PR introduces the proxies parameter to the RecursiveUrlLoader class, allowing the user to specify proxy servers for requests. This update enables crawling through proxy servers, providing enhanced flexibility for network configurations.
The key changes include:
1.Added an optional proxies parameter to the constructor (init).
2.Updated the documentation to explain the proxies parameter usage with an example.
3.Modified the _get_child_links_recursive method to pass the proxies parameter to the requests.get function.
Sample Usage