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

Use getLogger instead of basicConfig in multi_query.py #6891

Merged
merged 1 commit into from
Jun 29, 2023

Conversation

zhichenggeng
Copy link
Contributor

Remove logging.basicConfig, which turns on logging. Use getLogger instead.

cc @rlancemartin

@dosubot dosubot bot added the 03 enhancement Enhancement of existing functionality label Jun 28, 2023
@vercel
Copy link

vercel bot commented Jun 28, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
langchain ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 28, 2023 10:28pm

@zhichenggeng zhichenggeng marked this pull request as draft June 28, 2023 22:24
@zhichenggeng zhichenggeng marked this pull request as ready for review June 28, 2023 22:25
@zhichenggeng zhichenggeng changed the title Use getLogger instead of basicConfig in multi_query.py Use getLogger instead of basicConfig in multi_query.py Jun 28, 2023
@vercel vercel bot temporarily deployed to Preview June 28, 2023 22:28 Inactive
@dev2049 dev2049 added lgtm PR looks good. Use to confirm that a PR is ready for merging. and removed 03 enhancement Enhancement of existing functionality labels Jun 29, 2023
@dev2049 dev2049 merged commit 16b11bd into langchain-ai:master Jun 29, 2023
@rlancemartin
Copy link
Collaborator

@zhichenggeng i no longer see logging in notebook as expected w/ this change.

did you test this?

@rlancemartin
Copy link
Collaborator

Needed to add:

import logging
# Set up basic configuration
logging.basicConfig()
# Set logging level for the specific logger
logging.getLogger('langchain.retrievers.multi_query').setLevel(logging.INFO)

To the notebook. Putting up a PR to fix this now.

@zhichenggeng
Copy link
Contributor Author

@rlancemartin I have tested and no longer see the logging when I import langchain.retrievers. But I forgot to modify the notebook. Sorry for that.

@rlancemartin
Copy link
Collaborator

@rlancemartin I have tested and no longer see the logging when I import langchain.retrievers. But I forgot to modify the notebook. Sorry for that.

np, thanks.

@rlancemartin
Copy link
Collaborator

Resolved! #7102

rlancemartin added a commit that referenced this pull request Jul 4, 2023
* Add an easier-to-run example.
* Add logging per #6891.
* Updated params per #5962.

---------

Co-authored-by: R. Lance Martin <rlm@Rs-MacBook-Pro.local>
Co-authored-by: Lance Martin <lance@langchain.dev>
vowelparrot pushed a commit that referenced this pull request Jul 4, 2023
Remove `logging.basicConfig`, which turns on logging. Use `getLogger`
instead
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm PR looks good. Use to confirm that a PR is ready for merging.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants