Inconsistent behaviour between `adk web` vs `adk run`
- Dominant language
- TypeScript
- Stars
- 1k
- Forks
- 267
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 9
Description
**the behaviour is different when running agent via `run` command and `web` command**
i have following dir structure.
```
agent_flow
├── __init__.py
├── agent.py
```
__init__.py looks like
```
from . import agent
```
agent.py looks like
```python
from google.adk.agents import LlmAgent
from google.adk.tools import agent_tool
root_agent = LlmAgent(
name="RefineRequest",
model="gemini-2.0-flash",
description="You are a agent that refines user requests",
instruction=(
" Your task is to refine the user request to make it more specific and actionable."
" You can split the request into smaller tasks if needed."
" You can ask clarifying questions or provide suggestions to improve the request."
),
tools=[]
)
```
when running a agent from a module via `adk run agent_flow` the agent is able to start conversation with `root_agent` by default but when i run `adk web agent_flow` the ui can not detect any agent.
**To Reproduce**
Steps to reproduce the behaviour:
1. create above project structure
2. Run `adk run agent_flow`
3. Now run `adk web agent_flow`
4. notice the difference
**Expected behaviour**
the web should run with `root_agent` agent.
**Desktop (please complete the following information):**
- OS: ProductName: macOS 13.7.5
- Python version(python -V): Python 3.11.11
- ADK version(pip show google-adk): google-adk 0.3.0
Contributor guide
Assessment
This issue has not been assessed yet.