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

ci: mark unreliable langchain_community tests #9490

Merged
merged 5 commits into from
Jun 10, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions tests/contrib/langchain/test_langchain_community.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ def test_openai_chat_model_sync_generate(langchain, langchain_openai, request_vc
)


@flaky(1735812000)
@pytest.mark.snapshot
def test_openai_chat_model_vision_generate(langchain_openai, request_vcr):
"""
Expand Down Expand Up @@ -473,6 +474,7 @@ def test_embedding_logs(langchain_openai, ddtrace_config_langchain, request_vcr,
mock_metrics.count.assert_not_called()


@flaky(1735812000)
@pytest.mark.snapshot
def test_openai_math_chain_sync(langchain, langchain_openai, request_vcr):
"""
Expand All @@ -484,6 +486,7 @@ def test_openai_math_chain_sync(langchain, langchain_openai, request_vcr):
chain.invoke("what is two raised to the fifty-fourth power?")


@flaky(1735812000)
@pytest.mark.snapshot(token="tests.contrib.langchain.test_langchain_community.test_chain_invoke")
def test_chain_invoke_dict_input(langchain, langchain_openai, request_vcr):
prompt_template = "what is {base} raised to the fifty-fourth power?"
Expand Down Expand Up @@ -580,6 +583,7 @@ def _transform_func(inputs):
sequential_chain.invoke({"text": input_text, "style": "a 90s rapper"})


@flaky(1735812000)
@pytest.mark.snapshot
def test_openai_sequential_chain_with_multiple_llm_sync(langchain, langchain_openai, request_vcr):
template = """Paraphrase this text:
Expand Down Expand Up @@ -659,6 +663,7 @@ async def test_openai_sequential_chain_with_multiple_llm_async(langchain, langch
await sequential_chain.ainvoke({"input_text": input_text})


@flaky(1735812000)
@pytest.mark.parametrize(
"ddtrace_config_langchain",
[dict(metrics_enabled=False, logs_enabled=True, log_prompt_completion_sample_rate=1.0)],
Expand Down Expand Up @@ -1112,6 +1117,7 @@ def test_lcel_chain_simple(langchain_core, langchain_openai, request_vcr):
chain.invoke({"input": "how can langsmith help with testing?"})


@flaky(1735812000)
@pytest.mark.snapshot
def test_lcel_chain_complicated(langchain_core, langchain_openai, request_vcr):
prompt = langchain_core.prompts.ChatPromptTemplate.from_template(
Expand Down
Loading