Skip to content

Conversation

@mcavdar
Copy link
Contributor

@mcavdar mcavdar commented Oct 30, 2025

Overview

The current config produces an issue:

Traceback (most recent call last):
  File "<stdin>", line 4, in <module>
  File "/home/mc/.venv-langchain-v1/lib/python3.10/site-packages/langchain/agents/middleware/human_in_the_loop.py", line 193, in __init__
    elif tool_config.get("allowed_decisions"):
AttributeError: 'str' object has no attribute 'get'

The old example conflicts with the configuration options described in LangChain’s documentation

The description field is part of InterruptOnConfig, so the dictionary value should be an InterruptOnConfig object.

Type of change

Type: [Update existing documentation /bug/Remove outdated content]

Related issues/PRs

  • GitHub issue:
  • Feature PR:
  • Linear issue:
  • Slack thread:

Checklist

  • I have read the contributing guidelines
  • I have tested my changes locally using docs dev
  • All code examples have been tested and work correctly
  • I have used root relative paths for internal links
  • I have updated navigation in src/docs.json if needed
  • I have gotten approval from the relevant reviewers
  • (Internal team members only / optional) I have created a preview deployment using the Create Preview Branch workflow

Additional notes

@mcavdar mcavdar requested a review from lnhsingh as a code owner October 30, 2025 20:17
@github-actions github-actions bot added langchain For docs changes to LangChain python For content related to the Python version of LangChain projects oss labels Oct 30, 2025
@mdrxy mdrxy added the external User is not a member of langchain-ai label Nov 15, 2025
@lnhsingh lnhsingh merged commit d1c89f1 into langchain-ai:main Nov 18, 2025
1 check passed
lnhsingh added a commit that referenced this pull request Nov 20, 2025
…#1205)

## Overview
The current config produces an issue:

```
Traceback (most recent call last):
  File "<stdin>", line 4, in <module>
  File "/home/mc/.venv-langchain-v1/lib/python3.10/site-packages/langchain/agents/middleware/human_in_the_loop.py", line 193, in __init__
    elif tool_config.get("allowed_decisions"):
AttributeError: 'str' object has no attribute 'get'

```

The old example conflicts with the configuration options described in
[LangChain’s
documentation](https://docs.langchain.com/oss/python/langchain/middleware#human-in-the-loop)

The description field is part of InterruptOnConfig, so the dictionary
value should be an InterruptOnConfig object.

## Type of change

**Type:** [Update existing documentation /bug/Remove outdated content]

## Related issues/PRs
<!-- 
Link to related issues, feature PRs, or discussions (if applicable)

To automatically close an issue when this PR is merged, use closing
keywords:
- "closes #123" or "fixes #123" or "resolves #123"

For regular references without auto-closing, just use:
- "#123" or "See issue #123"

Examples:
- closes #456 (will auto-close issue #456 when PR is merged)
- See #789 for context (will reference but not auto-close issue #789)
-->
- GitHub issue:
- Feature PR:

<!-- For LangChain employees, if applicable: -->
- Linear issue:
- Slack thread:

## Checklist
<!-- Put an 'x' in all boxes that apply -->
- [x] I have read the [contributing guidelines](README.md)
- [x] I have tested my changes locally using `docs dev`
- [x] All code examples have been tested and work correctly
- [x] I have used **root relative** paths for internal links
- [x] I have updated navigation in `src/docs.json` if needed
- I have gotten approval from the relevant reviewers
- (Internal team members only / optional) I have created a preview
deployment using the [Create Preview Branch
workflow](https://github.com/langchain-ai/docs/actions/workflows/create-preview-branch.yml)

## Additional notes
<!-- Any other information that would be helpful for reviewers -->

---------

Co-authored-by: Lauren Hirata Singh <lauren@langchain.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

external User is not a member of langchain-ai langchain For docs changes to LangChain oss python For content related to the Python version of LangChain projects

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants