Skip to content

Commit 8a137ef

Browse files
authored
Deactivate LangSmith (#604)
1 parent a30af47 commit 8a137ef

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

libs/e2e-tests/e2e_tests/test_utils/tracing.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,20 @@
11
import logging
2+
import os
23
import time
34
from typing import Callable
45

56
from langsmith import Client
67

7-
LANGSMITH_CLIENT = Client()
8+
LANGSMITH_CLIENT = Client() if os.getenv("LANGCHAIN_TRACING_V2", "") == "true" else None
89

910

1011
def record_langsmith_sharelink(
1112
run_id: str, record_property: Callable, tries: int = 6
1213
) -> None:
1314
try:
14-
sharelink = LANGSMITH_CLIENT.share_run(run_id)
15+
sharelink = (
16+
LANGSMITH_CLIENT.share_run(run_id) if LANGSMITH_CLIENT else "deactivated"
17+
)
1518
record_property("langsmith_url", sharelink)
1619
logging.info("recorded langsmith link: %s", sharelink)
1720
except Exception:

scripts/ci-common-env.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/bash
22

3-
export LANGCHAIN_TRACING_V2=true
3+
#export LANGCHAIN_TRACING_V2=true
44
export LANGCHAIN_ENDPOINT="https://api.smith.langchain.com"
55
export LANGCHAIN_PROJECT="ragstack-ci"

0 commit comments

Comments
 (0)