Skip to content

standard-tests: refactoring and fixes #31703

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

Merged
merged 20 commits into from
Jun 23, 2025
Merged

Conversation

mdrxy
Copy link
Contributor

@mdrxy mdrxy commented Jun 23, 2025

  • libs/core/langchain_core/messages/base.py: add model name to examples per docs ("0.3.17: Additionally check for the presence of model_name in the response metadata, which is needed for usage tracking in callback handlers")
  • libs/core/langchain_core/utils/function_calling.py: correct typo
  • libs/standard-tests/langchain_tests/integration_tests/chat_models.py:
    • magic_function(input) -> magic_function(_input) to prevent warning about redefining built in input
    • relocate a few tests for better grouping and narrative flow
    • suppress some type hint warnings following suit from similar tests
    • fix a few more typos
    • validate not only that model_name is defined, but that it is not empty (test_usage_metadata)

mdrxy added 17 commits June 18, 2025 15:51
@mdrxy mdrxy requested a review from ccurme June 23, 2025 14:54
Copy link

vercel bot commented Jun 23, 2025

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 23, 2025 11:22pm

@dosubot dosubot bot added size:XXL This PR changes 1000+ lines, ignoring generated files. 🤖:nit Small modifications/deletions, fixes, deps or improvements to existing code or docs labels Jun 23, 2025
Copy link

codspeed-hq bot commented Jun 23, 2025

CodSpeed WallTime Performance Report

Merging #31703 will not alter performance

Comparing mdrxy/chat_models-updates (d0ac6b8) with master (b6f74bf)

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

Summary

✅ 13 untouched benchmarks

Copy link

codspeed-hq bot commented Jun 23, 2025

CodSpeed Instrumentation Performance Report

Merging #31703 will not alter performance

Comparing mdrxy/chat_models-updates (d0ac6b8) with master (b6f74bf)

Summary

✅ 13 untouched benchmarks

@sydney-runkle
Copy link
Collaborator

magic_function(input) -> magic_function(_input) to prevent warning about redefining built in input

Eventually we should enforce more linting / type checking rules, good to fix these now though!

Copy link
Collaborator

@sydney-runkle sydney-runkle left a comment

Choose a reason for hiding this comment

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

Seems like a reasonable cleanup, let's confirm with @ccurme who owns integration test stuff :)

@dosubot dosubot bot added the lgtm PR looks good. Use to confirm that a PR is ready for merging. label Jun 23, 2025
@mdrxy
Copy link
Contributor Author

mdrxy commented Jun 23, 2025

closing some ties here, @ccurme will you merge after a final review?

Copy link
Collaborator

@sydney-runkle sydney-runkle left a comment

Choose a reason for hiding this comment

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

Changes looking good, but a few nit picks to make this a bit more pythonic / less redundant!

…ol call validations plus additional clean ups
Copy link
Collaborator

@sydney-runkle sydney-runkle left a comment

Choose a reason for hiding this comment

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

Great!

@sydney-runkle sydney-runkle enabled auto-merge (squash) June 23, 2025 23:18
@sydney-runkle sydney-runkle merged commit 6d71b6b into master Jun 23, 2025
155 checks passed
@sydney-runkle sydney-runkle deleted the mdrxy/chat_models-updates branch June 23, 2025 23:22
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. 🤖:nit Small modifications/deletions, fixes, deps or improvements to existing code or docs size:XXL This PR changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants