Skip to content

fix(agent): install main module and gradio for CLI and Web UI#24

Open
YurunChen wants to merge 1 commit into
ZJU-REAL:masterfrom
YurunChen:fix/agent-packaging
Open

fix(agent): install main module and gradio for CLI and Web UI#24
YurunChen wants to merge 1 commit into
ZJU-REAL:masterfrom
YurunChen:fix/agent-packaging

Conversation

@YurunChen

Copy link
Copy Markdown

Description

Fixes two packaging issues in clawgui-agent/setup.py that break the default README install path (uv pip install -e .):

  1. phone-agent CLI fails with ModuleNotFoundError: No module named 'main' because main.py was not installed as a module while the console entry point references main:main.
  2. python webui.py fails with ModuleNotFoundError: No module named 'gradio' because gradio is listed in requirements.txt but not in setup.py install_requires, and the README install steps only run pip install -e ..

Changes:

  • Add py_modules=["main"] so the phone-agent console script works after install.
  • Add gradio>=4.0.0 to install_requires so Web UI works without a separate requirements.txt install step.
  • Update the package URL to point at the ClawGUI repository.

Fixes #

Type of Change

  • Bug fix
  • New feature
  • New model support (ClawGUI-Eval)
  • New environment support (ClawGUI-RL)
  • Documentation update
  • Refactor / code quality
  • Other:

Module(s) Affected

  • clawgui-agent
  • clawgui-eval
  • clawgui-rl
  • Root / docs

Checklist

  • I have read the Contributing Guide
  • My code follows the existing style of the module I'm modifying
  • I have tested my changes locally
  • I have updated documentation / README where relevant
  • For ClawGUI-Eval: I have added the model to the supported model table and provided reproduction results (or noted they are pending)
  • For ClawGUI-RL: I have verified training runs to completion without error on at least one environment

Testing

Verified in a clean virtual environment using only the README install path:

cd clawgui-agent
uv venv .venv --python 3.12
source .venv/bin/activate
uv pip install -e .
phone-agent --help      # previously: ModuleNotFoundError: No module named 'main'
python webui.py --help  # previously: ModuleNotFoundError: No module named 'gradio'
python main.py --help   # still works

Also confirmed the bugs reproduce on the current upstream commit (d990d3e) before this patch.

Additional Notes

  • python main.py remains the documented primary CLI path in README; this patch makes the registered phone-agent console script work as intended.
  • No new top-level dependencies beyond what requirements.txt already declared for Web UI usage.

Register main.py via py_modules so the phone-agent console entry point
works after pip install -e ., and declare gradio in install_requires so
webui.py runs without a separate requirements.txt install step.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant