Autonomous AI sales agent powered by Claude Code or Codex. Finds prospects, writes cold emails, sends campaigns, handles replies, books meetings. No API keys needed — runs on your Claude or Codex subscriptions.
Fail loudly on Python 3.9 instead of confusingly later
Ethan7365c5c79803
diff --git a/README.md b/README.mdindex e54665c..512cb3b 100644--- a/README.md+++ b/README.md@@ -102,7 +102,7 @@ Profiling and outbox draining ride along on **every** cycle regardless, because### Prerequisites-- Python 3.11++- **Python 3.11+** — check with `python3 --version`. macOS ships 3.9; if that's what you have, `brew install [email protected]` first.- An active **Claude Pro or Max** subscription, with the CLI logged in (`claude login`)- A mailbox to send from — Gmail/Workspace recommended, on a *dedicated secondary domain*@@ -119,8 +119,9 @@ Then say: **"set up Harvey for me"**. The repo ships a `CLAUDE.md` that turns Cl### Or do it yourself```bash-# 1. Install-python3 -m venv .venv && source .venv/bin/activate && pip install -e .+# 1. Install — note python3.13, not python3. On macOS bare `python3` is the+# system 3.9, and a venv built from it can't run Harvey.+python3.13 -m venv .venv && source .venv/bin/activate && pip install -e .# 2. Configure — every variable is documented inline with where to get itcp .env.example .env && $EDITOR .env@@ -436,6 +437,8 @@ Harvey automates outreach, but **you are the sender.** Cold email is legal in mo**`externally-managed-environment`** — Use a venv, not system Python.+**`SyntaxError` or odd `ImportError`s right after install (macOS)** — Your venv is Python 3.9. `python3 -m venv` builds from `/usr/bin/python3`, which macOS keeps at 3.9. Check with `.venv/bin/python -V`, then rebuild: `rm -rf .venv && python3.13 -m venv .venv && source .venv/bin/activate && pip install -e .`+**Claude headless mode fails** — `claude login`, and confirm the subscription is active. Test with `claude -p "say hi"`. In Docker, mount `~/.claude` into the container.**Discovery finds nothing** — Confirm signals first (`harvey signals --confirm free`); nothing is collected until you do. If you're on the free OpenStreetMap source, it only covers mapped trades and is thin for service-area businesses — `harvey discover --providers` shows the alternatives.diff --git a/harvey/__init__.py b/harvey/__init__.pyindex fa191e9..6d8e20f 100644--- a/harvey/__init__.py+++ b/harvey/__init__.py@@ -1 +1,19 @@+"""Harvey — an autonomous sales agent that runs on your Claude subscription."""++import sys++# Fail with a sentence someone can act on, not a SyntaxError from deep inside+# a module. `python3 -m venv` on macOS builds from the system 3.9, so this is+# the single most likely first-run problem.+if sys.version_info < (3, 11): # pragma: no cover - version guard+ raise RuntimeError(+ f"Harvey needs Python 3.11+, but this is "+ f"{sys.version_info.major}.{sys.version_info.minor} "+ f"({sys.executable}). On macOS `python3` is the system 3.9 — rebuild "+ f"the venv from a newer Python:\n"+ f" brew install [email protected]\n"+ f" rm -rf .venv && $(brew --prefix)/bin/python3.13 -m venv .venv\n"+ f" source .venv/bin/activate && pip install -e ."+ )+"""Harvey — Autonomous Sales Agent. Always Be Closing."""diff --git a/harvey/cli.py b/harvey/cli.pyindex f124b65..02445d4 100644--- a/harvey/cli.py+++ b/harvey/cli.py@@ -7,8 +7,37 @@ import sysfrom pathlib import Path+MIN_PYTHON = (3, 11)+++def _check_python_version():+ """Refuse to install on a Python that cannot run Harvey.++ `python3 -m venv .venv` on macOS builds the venv from /usr/bin/python3,+ which is 3.9 — old enough that Harvey's `X | Y` type syntax fails at+ import. The install itself appears to succeed and the failure surfaces+ later as an unrelated-looking ImportError, so check up front and name the+ fix.+ """+ if sys.version_info >= MIN_PYTHON:+ return++ have = f"{sys.version_info.major}.{sys.version_info.minor}"+ want = f"{MIN_PYTHON[0]}.{MIN_PYTHON[1]}"+ print(f"\n Harvey needs Python {want} or newer. This is Python {have}.")+ print(f" ({sys.executable})\n")+ print(" On macOS, `python3` is usually the system 3.9, so a venv built")+ print(" with it is 3.9 too. Build the venv from a newer Python instead:\n")+ print(" brew install [email protected]")+ print(" rm -rf .venv")+ print(" $(brew --prefix)/bin/python3.13 -m venv .venv")+ print(" source .venv/bin/activate && pip install -e .\n")+ sys.exit(1)++def cmd_install(args):"""Install all dependencies including Playwright browsers."""+ _check_python_version()print("\n Installing Harvey dependencies...\n")# Install Python packages