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

all[minor]: Add ability to disable console logs in tests #6009

Merged
merged 1 commit into from
Jul 9, 2024

Conversation

bracesproul
Copy link
Member

@bracesproul bracesproul commented Jul 9, 2024

there's far too many console logs in our tests... this makes it difficult to diagnose failures in ci and similar. This PR allows for setting an env var (DISABLE_CONSOLE_LOGS) which will prevent console.log calls from actually logging anything.

Copy link

vercel bot commented Jul 9, 2024

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

Name Status Preview Comments Updated (UTC)
langchainjs-api-refs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 9, 2024 0:47am
langchainjs-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 9, 2024 0:47am

@bracesproul bracesproul marked this pull request as ready for review July 9, 2024 00:38
@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. auto:improvement Medium size change to existing code to handle new use-cases labels Jul 9, 2024
@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the DISABLE_CONSOLE_LOGS environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! 👋 I noticed that the recent change in jest-setup-after-env.js adds code to access an environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage guidelines. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds code to access an environment variable using process.env. This is flagged for your review. Let me know if you need further assistance with this.

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the DISABLE_CONSOLE_LOGS environment variable. This is flagged for your review to ensure it aligns with our environment variable usage guidelines. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey team, just wanted to flag the recent change in jest-setup-after-env.js that accesses the environment variable DISABLE_CONSOLE_LOGS using process.env. This is flagged for your review to ensure it aligns with our environment variable usage guidelines. Great work overall!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I've reviewed the code and noticed that the recent change in jest-setup-after-env.js adds logic to access an environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage guidelines. Let me know if you need further assistance with this.

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the environment variable DISABLE_CONSOLE_LOGS using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent code change in jest-setup-after-env.js is accessing and reading the value of the environment variable DISABLE_CONSOLE_LOGS. I've flagged this for your review to ensure it aligns with the project's standards. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the DISABLE_CONSOLE_LOGS environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage guidelines. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds code to access an environment variable using process.env. This comment is just to flag this change for the maintainers to review. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I've reviewed the PR and noticed that the added code explicitly accesses an environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage guidelines. Let me know if you need further assistance with this.

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the DISABLE_CONSOLE_LOGS environment variable. This comment is to flag the change for your review. Let me know if you need further assistance with this.

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds code to conditionally disable console.log based on the value of the environment variable DISABLE_CONSOLE_LOGS. I've flagged this for your review to ensure it aligns with our environment variable usage guidelines. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds code to access an environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage guidelines. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the DISABLE_CONSOLE_LOGS environment variable using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent PR includes a change that accesses an environment variable using process.env. This comment is just to flag this change for the maintainers to review. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the environment variable DISABLE_CONSOLE_LOGS. I've flagged this for your review, just to ensure it aligns with our environment variable usage. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! 👋 I noticed that the recent change in jest-setup-after-env.js is flagging the access of the environment variable DISABLE_CONSOLE_LOGS for review. This is to ensure that the handling of environment variables aligns with best practices. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey team, I've reviewed the PR and noticed that the added code explicitly accesses an environment variable using process.env. This comment is to flag the change for maintainers to review the use of the environment variable. Great work overall!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the environment variable DISABLE_CONSOLE_LOGS using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage. Keep up the great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds logic to access the environment variable DISABLE_CONSOLE_LOGS. This comment is to flag the change for maintainers to review the use of environment variables in the code. Great work!

@@ -1,3 +1,9 @@
import { awaitAllCallbacks } from "@langchain/core/callbacks/promises";
Copy link

Choose a reason for hiding this comment

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

Hey there! I noticed that the recent change in jest-setup-after-env.js adds a check for the environment variable DISABLE_CONSOLE_LOGS using process.env. I've flagged this for your review to ensure it aligns with our environment variable usage. Keep up the great work!

@bracesproul bracesproul deleted the brace/disable-console-log-test-option branch July 9, 2024 00:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto:improvement Medium size change to existing code to handle new use-cases size:L This PR changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant