langchain-common-errors
Diagnose and fix common LangChain errors and exceptions. Use when encountering LangChain errors, debugging failures, or troubleshooting integration issues. Trigger with phrases like "langchain error", "langchain exception", "debug langchain", "langchain not working", "langchain troubleshoot".
npx skills add majiayu000/claude-skill-registry --skill langchain-common-errors --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# LangChain Common Errors ## Overview Quick reference for diagnosing and resolving the most common LangChain errors. ## Prerequisites - LangChain installed and configured - Access to application logs - Understanding of your LangChain implementation ## Error Reference ### Authentication Errors #### `openai.AuthenticationError: Incorrect API key provided` ```python # Cause: Invalid or missing API key # Solution: import os os.environ["OPENAI_API_KEY"] = "sk-..." # Set correct key # Verify key is loaded from langchain_openai import ChatOpenAI llm = ChatOpenAI() # Will raise error if key invalid ``` #### `anthropic.AuthenticationError: Invalid x-api-key` ```python # Cause: Anthropic API key not set or invalid # Solution: os.environ["ANTHROPIC_API_KEY"] = "sk-ant-..." # Or pass directly from langchain_anthropic import ChatAnthropic llm = ChatAnthropic(api_key="sk-ant-...") ``` ### Import Errors #### `ModuleNotFoundError: No module named 'langchain_openai'` ```bash # Cause: Provider package not installed # Solution: pip install langchain-openai # For other providers: pip install langchain-anthropic pip install langchain-google-genai pip install langchain-community ``` #### `ImportError: c
- Overview
- Prerequisites
- Error Reference
- Authentication Errors
- Import Errors
- Rate Limiting
- Output Parsing Errors
- Chain Errors
- Agent Errors
- Memory Errors
- Debugging Tips
- Enable Verbose Mode
- Trace with LangSmith
- Check Version Compatibility
pip install langchain-openai For other providers: pip install langchain-anthropic pip install langchain-google-genai pip install langchain-community pip show langchain langchain-core langchain-openai Ensure versions are compatible: langchain >= 0.3.0 langchain-core >= 0.3.0 langchain-openai >= 0.2.0
What does the langchain-common-errors skill do?
Diagnose and fix common LangChain errors and exceptions. Use when encountering LangChain errors, debugging failures, or troubleshooting integration issues. Trigger with phrases like "langchain error", "langchain exception", "debug langchain", "langchain not working", "langchain troubleshoot".
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill langchain-common-errors --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
