Mason Daugherty
a751a23c4e
fix: remove unused type ignore from three_values fixture in TestAsyncInMemoryStore ( #31895 )
2025-07-07 13:22:53 -04:00
Michael Li
8ef01f8444
fix: complete exception handling for UpstashRedisEntityStore ( #31893 )
...
Thank you for contributing to LangChain!
- [x] **PR title**: "package: description"
- Where "package" is whichever of langchain, core, etc. is being
modified. Use "docs: ..." for purely docs changes, "infra: ..." for CI
changes.
- Example: "core: add foobar LLM"
- [x] **PR message**: ***Delete this entire checklist*** and replace
with
- **Description:** a description of the change
- **Issue:** the issue # it fixes, if applicable
- **Dependencies:** any dependencies required for this change
- **Twitter handle:** if your PR gets announced, and you'd like a
mention, we'll gladly shout you out!
- [x] **Add tests and docs**: If you're adding a new integration, please
include
1. a test for the integration, preferably unit tests that do not rely on
network access,
2. an example notebook showing its use. It lives in
`docs/docs/integrations` directory.
- [x] **Lint and test**: Run `make format`, `make lint` and `make test`
from the root of the package(s) you've modified. See contribution
guidelines for more: https://python.langchain.com/docs/contributing/
Additional guidelines:
- Make sure optional dependencies are imported within a function.
- Please do not add dependencies to pyproject.toml files (even optional
ones) unless they are required for unit tests.
- Most PRs should not touch more than one package.
- Changes should be backwards compatible.
If no one reviews your PR within a few days, please @-mention one of
baskaryan, eyurtsev, ccurme, vbarda, hwchase17.
2025-07-07 13:13:38 -04:00
Mason Daugherty
6c23c711fb
fix: lint/format ( #31894 )
2025-07-07 13:11:06 -04:00
Christophe Bornet
03e8327e01
core: Ruff preview fixes ( #31877 )
...
Auto-fixes from `uv run ruff check --fix --unsafe-fixes --preview`
---------
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 13:02:40 -04:00
Christophe Bornet
ba144c9d7f
langchain: Add ruff rule RUF ( #31874 )
...
All auto-fixes
See https://docs.astral.sh/ruff/rules/#ruff-specific-rules-ruf
---------
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 12:49:38 -04:00
Christophe Bornet
ed35372580
langchain: Add ruff rules FBT ( #31885 )
...
* Fixed for private functions and in tests
* Added noqa escapes for public functions
See https://docs.astral.sh/ruff/rules/#flake8-boolean-trap-fbt
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 12:35:55 -04:00
Christophe Bornet
56bbfd9723
langchain: Add ruff rule RET ( #31875 )
...
All auto-fixes
See https://docs.astral.sh/ruff/rules/#flake8-return-ret
---------
Co-authored-by: Mason Daugherty <github@mdrxy.com>
2025-07-07 15:33:18 +00:00
Christophe Bornet
fceebbb387
langchain: Add ruff rules C4 ( #31879 )
...
All auto-fixes
See https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4
---------
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 10:55:52 -04:00
Christophe Bornet
4134b36db8
core: make ruff rule PLW1510 unfixable ( #31868 )
...
See
https://github.com/astral-sh/ruff/discussions/17087#discussioncomment-12675815
Tha autofix is misleading: it chooses to add `check=False` to keep the
runtime behavior but in reality it hides the fact that most probably the
user would prefer `check=True`.
2025-07-07 10:28:30 -04:00
Christophe Bornet
9368b92b2c
standard-tests: Ruff autofixes ( #31862 )
...
Auto-fixes from ruff with rule ALL
2025-07-07 10:27:39 -04:00
Christophe Bornet
2df3fdf40d
langchain: Add ruff rules SIM ( #31881 )
...
See https://docs.astral.sh/ruff/rules/#flake8-simplify-sim
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 10:27:04 -04:00
Christophe Bornet
f06380516f
langchain: Add ruff rules A ( #31888 )
...
See https://docs.astral.sh/ruff/rules/#flake8-builtins-a
---------
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 10:20:27 -04:00
Christophe Bornet
49c316667d
langchain: Add ruff rules EM ( #31873 )
...
All auto-fixes.
See https://docs.astral.sh/ruff/rules/#flake8-errmsg-em
---------
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2025-07-07 10:13:56 -04:00
Christophe Bornet
1276bf3e1d
standard-tests: Add ruff rules PGH ( #31869 )
...
See https://docs.astral.sh/ruff/rules/#pygrep-hooks-pgh
2025-07-07 10:07:39 -04:00
Christophe Bornet
53c75abba2
langchain: Add ruff rules PIE ( #31880 )
...
All auto-fixes
See https://docs.astral.sh/ruff/rules/#flake8-pie-pie
2025-07-07 10:07:12 -04:00
Christophe Bornet
a46a2b8bda
cli: Ruff autofixes ( #31863 )
...
Auto-fixes from ruff with rule ALL
2025-07-07 10:06:34 -04:00
Christophe Bornet
451c90fefa
text-splitters: Ruff autofixes ( #31858 )
...
Auto-fixes from ruff with rule `ALL`
2025-07-07 10:06:08 -04:00
Christophe Bornet
8aed3b61a9
core: Bump ruff version to 0.12 ( #31846 )
2025-07-07 10:02:51 -04:00
Michael Li
73552883c3
cli: fix dockerfile incorrect copy ( #31883 )
2025-07-06 21:20:57 -04:00
m27315
013ce2c47f
huggingface: fix HuggingFaceEndpoint._astream() got multiple values for argument 'stop' ( #31385 )
2025-07-06 15:18:53 +00:00
CuberMessenegr
e934788ca2
docs: Fix uppercase typo in the Similarity search section ( #31886 )
2025-07-06 10:24:13 -04:00
Christophe Bornet
bf05229029
langchain: Add ruff rule W ( #31876 )
...
All auto-fixes
See https://docs.astral.sh/ruff/rules/#warning-w
Co-authored-by: Chester Curme <chester.curme@gmail.com>
2025-07-05 21:57:30 +00:00
ccurme
3f4b355eef
anthropic[patch]: pass back in citations in multi-turn conversations ( #31882 )
...
Also adds VCR cassettes for some heavy tests.
2025-07-05 17:33:22 -04:00
Christophe Bornet
46fe09f013
cli: Bump ruff version to 0.12 ( #31864 )
2025-07-05 17:15:24 -04:00
Christophe Bornet
df5cc024fd
langchain: Bump ruff version to 0.12 ( #31867 )
2025-07-05 17:13:55 -04:00
Christophe Bornet
a15c3e0856
text-splitters: Bump ruff version to 0.12 ( #31866 )
2025-07-05 17:13:08 -04:00
Christophe Bornet
e1eb3f8d6f
standard-tests: Bump ruff version to 0.12 ( #31865 )
2025-07-05 17:12:00 -04:00
NeatGuyCoding
64815445e4
langchain[patch]: fix a bug where now.replace(day=now.day - 1)
would raise a ValueError
when now.day
is equal to 1 ( #31878 )
2025-07-05 14:54:26 -04:00
Viet Hoang
15dc684d34
docs: Integration with GreenNode Serverless AI ( #31836 )
2025-07-05 13:48:35 -04:00
Nithish Raghunandanan
8bdb1de006
[docs] Update couchbase provider, vector store & features list ( #31719 )
2025-07-05 13:34:48 -04:00
Mohammad Mohtashim
b26d2250ba
core[patch]: Int Combine when Merging Dicts ( #31572 )
...
- **Description:** Combining the Int Types by adding them which makes
the most sense.
- **Issue:** #31565
2025-07-04 14:44:16 -04:00
Mason Daugherty
6a5073b227
langchain[patch]: Add bandit rules ( #31818 )
...
Integrate Bandit for security analysis, suppress warnings for specific issues, and address potential vulnerabilities such as hardcoded passwords and SQL injection risks. Adjust documentation and formatting for clarity.
2025-07-03 14:20:33 -04:00
ccurme
df06041eb2
docs: Anthropic search_result nits ( #31855 )
2025-07-03 14:12:10 -04:00
ccurme
ade642b7c5
Revert "infra: temporarily skip tests" ( #31854 )
...
Reverts langchain-ai/langchain#31853
2025-07-03 13:55:29 -04:00
ccurme
c9f45dc323
infra: temporarily skip tests ( #31853 )
...
Tests failed twice with different timeout errors.
2025-07-03 13:39:14 -04:00
ccurme
f88fff0b8a
anthropic: release 0.3.17 ( #31852 )
2025-07-03 13:18:43 -04:00
ccurme
7cb9388c33
Revert "infra: drop anthropic from core test matrix" ( #31851 )
...
Reverts langchain-ai/langchain#31850
2025-07-03 17:14:26 +00:00
ccurme
21664985c7
infra: drop anthropic from core test matrix ( #31850 )
...
Overloaded errors blocking release. Will revert after.
2025-07-03 12:52:25 -04:00
ccurme
b140d16696
docs: update ChatAnthropic guide ( #31849 )
2025-07-03 12:51:11 -04:00
ccurme
2090f85789
core: release 0.3.68 ( #31848 )
...
Also add `search_result` to recognized tool message block types.
2025-07-03 12:36:25 -04:00
Mason Daugherty
572020c4d8
ollama: add validate_model_on_init
, catch more errors ( #31784 )
...
* Ensure access to local model during `ChatOllama` instantiation
(#27720 ). This adds a new param `validate_model_on_init` (default:
`true`)
* Catch a few more errors from the Ollama client to assist users
2025-07-03 11:07:11 -04:00
Mason Daugherty
1a3a8db3c9
docs: anthropic formatting cleanup ( #31847 )
...
inline URLs, capitalization, code blocks
2025-07-03 14:50:23 +00:00
Christophe Bornet
ee3709535d
text-splitters: bump spacy version to 3.8.7 ( #31834 )
...
This allows to use spacy with Python 3.13
2025-07-03 10:13:25 -04:00
Christophe Bornet
b8e9b4adfc
cli: Add ruff rule UP (pyupgrade) ( #31843 )
...
See https://docs.astral.sh/ruff/rules/#pyupgrade-up
All auto-fixed
Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com>
2025-07-03 14:12:46 +00:00
Christophe Bornet
cd7dce687a
standard-tests: Add ruff rule UP (pyupgrade) ( #31842 )
...
See https://docs.astral.sh/ruff/rules/#pyupgrade-up
All auto-fixed
2025-07-03 10:12:31 -04:00
Christophe Bornet
802d2bf249
text-splitters: Add ruff rule UP (pyupgrade) ( #31841 )
...
See https://docs.astral.sh/ruff/rules/#pyupgrade-up
All auto-fixed except `typing.AbstractSet` -> `collections.abc.Set`
2025-07-03 10:11:35 -04:00
Mason Daugherty
911b0b69ea
groq: Add service tier option to ChatGroq ( #31801 )
...
- Allows users to select a [flex
processing](https://console.groq.com/docs/flex-processing ) service tier
2025-07-03 10:11:18 -04:00
Eugene Yurtsev
10ec5c8f02
text-splitters: 0.3.9 ( #31844 )
...
Release langchain-text-splitters 0.3.9
2025-07-03 10:02:35 -04:00
Eugene Yurtsev
6dca787a9d
ci: set explicit workflow permissions ( #31830 )
...
* Set explicit workflow permissions
* Should be a no-op since we're using restricted GITHUB_TOKENs by
default
2025-07-03 10:02:18 -04:00
Christophe Bornet
46745f91b5
core: Use parametric tests in test_openai_tools ( #31839 )
2025-07-03 08:43:46 -04:00