From 3b37421725db5bd199c743fdf0ce183ccfc31e72 Mon Sep 17 00:00:00 2001 From: lorenss-m Date: Tue, 14 Jul 2026 11:03:38 -0700 Subject: [PATCH 1/2] feat(packaging): rename the PyPI distribution from hud-python to hud The import name and CLI were always hud; now the package name matches. hud-python becomes an empty shim that depends on hud (with pass-through extras and entry points), published in lockstep by the release workflow so existing installs, lockfiles, and uv tool setups keep working. hud/__init__ warns when a pre-rename hud-python sits alongside hud, since both ship the same top-level package and overwrite each other. Co-authored-by: Cursor --- .github/workflows/release.yml | 11 +++- CONTRIBUTING.md | 2 +- README.md | 8 +-- cookbooks/a2a-chat/pyproject.toml | 6 +-- cookbooks/codex-coding/pyproject.toml | 6 +-- .../fireworks-rl-training/pyproject.toml | 4 +- cookbooks/rl-training/ppo_custom_loss.py | 2 +- cookbooks/rl-training/pyproject.toml | 6 +-- docs/skill.md | 2 +- docs/v6/advanced/robots.mdx | 4 +- docs/v6/more/contributing.mdx | 2 +- docs/v6/more/faq.mdx | 4 +- docs/v6/reference/cli.mdx | 2 +- docs/v6/reference/training.mdx | 2 +- docs/v6/start/quickstart.mdx | 4 +- hud/__init__.py | 37 ++++++++++++- hud/agents/__init__.py | 2 +- hud/agents/browser_use/__init__.py | 2 +- hud/agents/browser_use/agent.py | 2 +- hud/agents/robot/__init__.py | 2 +- hud/agents/robot/video.py | 2 +- hud/agents/tests/test_base.py | 4 +- hud/cli/templates.py | 2 +- hud/cli/utils/version_check.py | 16 +++--- hud/train/client.py | 4 +- hud/version.py | 2 +- integrations/tests/test_harbor.py | 2 +- pyproject.toml | 10 ++-- shim/README.md | 29 +++++++++++ shim/pyproject.toml | 52 +++++++++++++++++++ 30 files changed, 180 insertions(+), 53 deletions(-) create mode 100644 shim/README.md create mode 100644 shim/pyproject.toml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b3768c1a7..b91ada6d4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,9 +14,18 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v5 - - name: Build and publish to PyPi + - name: Build and publish 'hud' to PyPI env: UV_PUBLISH_TOKEN: ${{ secrets.PYPI_API_TOKEN }} run: | uv build uv publish + + # 'hud-python' is an empty shim that depends on 'hud' (the package was + # renamed). Published in lockstep so old install commands keep working. + - name: Build and publish 'hud-python' shim to PyPI + env: + UV_PUBLISH_TOKEN: ${{ secrets.PYPI_API_TOKEN }} + run: | + uv build shim + uv publish shim/dist/* diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e92f39b4d..98a179805 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -5,7 +5,7 @@ We welcome contributions to the HUD SDK! This guide covers how to get started. ## Quick Start 1. Fork the repository -2. Clone your fork: `git clone https://github.com/YOUR-USERNAME/hud-python` +2. Clone your fork: `git clone https://github.com/YOUR-USERNAME/hud-python` (the repo keeps its historical name; the PyPI package is `hud`) 3. Install [uv](https://docs.astral.sh/uv/) and set up dev dependencies: ```bash cd hud-python diff --git a/README.md b/README.md index ae9cfaeba..cd64300fb 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ HUD is a platform for building RL environments for AI agents, across coding, bro To learn more, see the [documentation](https://docs.hud.ai) and [environment reference](https://docs.hud.ai/v6/reference/environment). -[![PyPI](https://img.shields.io/pypi/v/hud-python?style=flat-square)](https://pypi.org/project/hud-python/) +[![PyPI](https://img.shields.io/pypi/v/hud?style=flat-square)](https://pypi.org/project/hud/) [![License](https://img.shields.io/badge/license-MIT-green?style=flat-square)](LICENSE) [![Add docs to Cursor](https://img.shields.io/badge/Add%20docs%20to-Cursor-black?style=flat-square)](https://cursor.com/en/install-mcp?name=docs-hud-python&config=eyJ1cmwiOiJodHRwczovL2RvY3MuaHVkLmFpL21jcCJ9) [![Discord](https://img.shields.io/discord/1327447144772407390?label=Discord&logo=discord&style=flat-square)](https://discord.gg/wkjtmHYYjm) @@ -22,12 +22,14 @@ To learn more, see the [documentation](https://docs.hud.ai) and [environment ref ```bash # Install the CLI (recommended) -uv tool install hud-python --python 3.12 +uv tool install hud --python 3.12 # …or as a library -pip install hud-python +pip install hud ``` +> Previously published as [`hud-python`](https://pypi.org/project/hud-python/), which now just installs `hud`. The import and CLI names are unchanged. + Get your API key at [hud.ai/project/api-keys](https://hud.ai/project/api-keys) and set it: ```bash diff --git a/cookbooks/a2a-chat/pyproject.toml b/cookbooks/a2a-chat/pyproject.toml index c16a43b16..c6fcc8e33 100644 --- a/cookbooks/a2a-chat/pyproject.toml +++ b/cookbooks/a2a-chat/pyproject.toml @@ -4,7 +4,7 @@ version = "0.1.0" description = "Serve a HUD chat task over the A2A protocol (cookbook)" requires-python = ">=3.11,<3.13" dependencies = [ - "hud-python", + "hud", # The scripts are written against the 0.3.x server API. "a2a-sdk==0.3.26", ] @@ -13,6 +13,6 @@ dependencies = [ package = false # Track the SDK from this repo. If you copied this folder out, delete this -# block to use the released hud-python from PyPI. +# block to use the released hud from PyPI. [tool.uv.sources] -hud-python = { path = "../..", editable = true } +hud = { path = "../..", editable = true } diff --git a/cookbooks/codex-coding/pyproject.toml b/cookbooks/codex-coding/pyproject.toml index 3789c3bf5..8be7f342d 100644 --- a/cookbooks/codex-coding/pyproject.toml +++ b/cookbooks/codex-coding/pyproject.toml @@ -4,7 +4,7 @@ version = "0.1.0" description = "Build your own Codex with the HUD SDK (cookbook)" requires-python = ">=3.11,<3.13" dependencies = [ - "hud-python", + "hud", "python-dotenv", ] @@ -12,6 +12,6 @@ dependencies = [ package = false # Track the SDK from this repo. If you copied this folder out, delete this -# block to use the released hud-python from PyPI. +# block to use the released hud from PyPI. [tool.uv.sources] -hud-python = { path = "../..", editable = true } +hud = { path = "../..", editable = true } diff --git a/cookbooks/fireworks-rl-training/pyproject.toml b/cookbooks/fireworks-rl-training/pyproject.toml index 1b2eb836a..2cc214785 100644 --- a/cookbooks/fireworks-rl-training/pyproject.toml +++ b/cookbooks/fireworks-rl-training/pyproject.toml @@ -5,7 +5,7 @@ description = "Direct Fireworks Training API RL loop over HUD-style arithmetic t requires-python = ">=3.11,<3.13" dependencies = [ "fireworks-ai[training]", - "hud-python", + "hud", "matplotlib", "python-dotenv", "torch>=2", @@ -16,4 +16,4 @@ dependencies = [ package = false [tool.uv.sources] -hud-python = { path = "../..", editable = true } +hud = { path = "../..", editable = true } diff --git a/cookbooks/rl-training/ppo_custom_loss.py b/cookbooks/rl-training/ppo_custom_loss.py index a8d568d4f..c063cacf5 100644 --- a/cookbooks/rl-training/ppo_custom_loss.py +++ b/cookbooks/rl-training/ppo_custom_loss.py @@ -16,7 +16,7 @@ uv run ppo_custom_loss.py --steps 10 # set MODEL below (pick one with `hud models`) Requires torch (declared in this cookbook's pyproject; in the SDK it is the -``hud-python[train]`` extra). +``hud[train]`` extra). """ from __future__ import annotations diff --git a/cookbooks/rl-training/pyproject.toml b/cookbooks/rl-training/pyproject.toml index 7fed6052d..57d60dfe9 100644 --- a/cookbooks/rl-training/pyproject.toml +++ b/cookbooks/rl-training/pyproject.toml @@ -4,7 +4,7 @@ version = "0.1.0" description = "On-policy RL training with the HUD SDK (cookbook)" requires-python = ">=3.11,<3.13" dependencies = [ - "hud-python", + "hud", "python-dotenv", # ppo_custom_loss.py computes its loss client-side with torch autograd. # simple_train.py (built-in loss) does not need it. @@ -15,6 +15,6 @@ dependencies = [ package = false # Track the SDK from this repo. If you copied this folder out, delete this -# block to use the released hud-python from PyPI. +# block to use the released hud from PyPI. [tool.uv.sources] -hud-python = { path = "../..", editable = true } +hud = { path = "../..", editable = true } diff --git a/docs/skill.md b/docs/skill.md index d230ff744..3fed05925 100644 --- a/docs/skill.md +++ b/docs/skill.md @@ -220,7 +220,7 @@ Get the opponent's tokens from the gateway call with `extra_body={"return_token_ await trainer.set_head(checkpoint_id) # or: hud models head --set ``` -**Custom loss / primitives.** Author the loss yourself (e.g. double-sided IS) with `forward_backward_custom` — the service returns per-token tensors, your torch function makes the gradients (needs `pip install 'hud-python[train]'`). Drop to `forward_backward` + `optim_step` directly when you want the `forward_backward` metrics or gradient accumulation (`num_substeps`) in between; `step` is just the two chained. +**Custom loss / primitives.** Author the loss yourself (e.g. double-sided IS) with `forward_backward_custom` — the service returns per-token tensors, your torch function makes the gradients (needs `pip install 'hud[train]'`). Drop to `forward_backward` + `optim_step` directly when you want the `forward_backward` metrics or gradient accumulation (`num_substeps`) in between; `step` is just the two chained. --- diff --git a/docs/v6/advanced/robots.mdx b/docs/v6/advanced/robots.mdx index 46335146c..40d78d03e 100644 --- a/docs/v6/advanced/robots.mdx +++ b/docs/v6/advanced/robots.mdx @@ -23,10 +23,10 @@ Everything below ships behind the `robot` extra (pulls in numpy + openpi-client) ```bash uv -uv add 'hud-python[robot]' +uv add 'hud[robot]' ``` ```bash pip -pip install 'hud-python[robot]' +pip install 'hud[robot]' ``` diff --git a/docs/v6/more/contributing.mdx b/docs/v6/more/contributing.mdx index 7929225cc..5b850194d 100644 --- a/docs/v6/more/contributing.mdx +++ b/docs/v6/more/contributing.mdx @@ -21,7 +21,7 @@ We welcome contributions to the HUD SDK! 3. **Install in development mode**: ```bash uv pip install -e ".[dev]" - uv tool install --force --from "." hud-python --refresh + uv tool install --force --from "." hud --refresh ``` ## Development Workflows diff --git a/docs/v6/more/faq.mdx b/docs/v6/more/faq.mdx index f23cbadc3..ce0374653 100644 --- a/docs/v6/more/faq.mdx +++ b/docs/v6/more/faq.mdx @@ -40,10 +40,10 @@ No - not to build environments, write tasks, or run evals. Inference happens thr -A globally installed CLI (`uv tool install hud-python`) runs in its **own** Python environment, so it can't see packages from your project's venv (e.g. `playwright` in your env's dependencies). Inside a project with its own deps, add `hud-python` to the project and run it from the venv: +A globally installed CLI (`uv tool install hud`) runs in its **own** Python environment, so it can't see packages from your project's venv (e.g. `playwright` in your env's dependencies). Inside a project with its own deps, add `hud` to the project and run it from the venv: ```bash -uv add hud-python +uv add hud uv run hud eval tasks.py claude ``` diff --git a/docs/v6/reference/cli.mdx b/docs/v6/reference/cli.mdx index ca853a8a7..27605ecf7 100644 --- a/docs/v6/reference/cli.mdx +++ b/docs/v6/reference/cli.mdx @@ -4,7 +4,7 @@ description: "Reference for the hud command-line interface: init, dev, run, eval icon: "terminal" --- -Install the CLI with `uv tool install hud-python --python 3.12`. Authenticate once with `hud set HUD_API_KEY=...`. +Install the CLI with `uv tool install hud --python 3.12`. Authenticate once with `hud set HUD_API_KEY=...`. ## Build & iterate diff --git a/docs/v6/reference/training.mdx b/docs/v6/reference/training.mdx index db13d7308..d9a11877f 100644 --- a/docs/v6/reference/training.mdx +++ b/docs/v6/reference/training.mdx @@ -148,7 +148,7 @@ the defaults (`None`) unless a provider documents a key. `forward_backward_custom` runs the current-policy forward pass server-side, hands you per-token tensors, runs your loss locally (torch autograd), and ships the per-token gradients back. Requires torch -(`pip install 'hud-python[train]'`). +(`pip install 'hud[train]'`). ```python import torch diff --git a/docs/v6/start/quickstart.mdx b/docs/v6/start/quickstart.mdx index d67f93a05..ae68fc409 100644 --- a/docs/v6/start/quickstart.mdx +++ b/docs/v6/start/quickstart.mdx @@ -16,10 +16,10 @@ The rest of this page walks the setup path by hand. ```bash uv -uv tool install hud-python --python 3.12 +uv tool install hud --python 3.12 ``` ```bash pip -pip install hud-python +pip install hud ``` diff --git a/hud/__init__.py b/hud/__init__.py index 76f4b5e54..6eda67c62 100644 --- a/hud/__init__.py +++ b/hud/__init__.py @@ -1,4 +1,4 @@ -"""hud-python. +"""hud. tools for building, evaluating, and training AI agents. """ @@ -64,3 +64,38 @@ from .version import __version__ except ImportError: __version__ = "unknown" + + +def _warn_legacy_hud_python() -> None: + """Warn when a pre-rename hud-python install sits alongside this package. + + The SDK was published as ``hud-python`` before the rename to ``hud``. + ``hud-python`` releases older than the rename ship their own copy of the + ``hud`` package, so installing both makes the installer silently overwrite + one with the other. Post-rename ``hud-python`` releases are empty shims + that just depend on ``hud`` and are fine to have installed. + """ + from importlib.metadata import PackageNotFoundError + from importlib.metadata import version as _dist_version + + try: + legacy = _dist_version("hud-python") + _dist_version("hud") + except PackageNotFoundError: + return + + from packaging.version import Version + + if Version(legacy) < Version("0.6.9"): + import warnings + + warnings.warn( + f"Both 'hud' and a pre-rename 'hud-python' ({legacy}) are installed; they ship " + "the same 'hud' package and overwrite each other. Run 'pip uninstall hud-python' " + "and then reinstall 'hud'.", + RuntimeWarning, + stacklevel=3, + ) + + +_warn_legacy_hud_python() diff --git a/hud/agents/__init__.py b/hud/agents/__init__.py index 97fbb5721..b816634ab 100644 --- a/hud/agents/__init__.py +++ b/hud/agents/__init__.py @@ -135,7 +135,7 @@ def __getattr__(name: str) -> object: value = getattr(import_module(module_name), symbol) except ModuleNotFoundError as exc: raise ImportError( - f"{name} requires the agents extra. Install with: pip install 'hud-python[agents]'" + f"{name} requires the agents extra. Install with: pip install 'hud[agents]'" ) from exc globals()[name] = value return value diff --git a/hud/agents/browser_use/__init__.py b/hud/agents/browser_use/__init__.py index 3a11d78ce..e175afb1c 100644 --- a/hud/agents/browser_use/__init__.py +++ b/hud/agents/browser_use/__init__.py @@ -1,4 +1,4 @@ -"""browser-use SDK integration (optional dependency ``hud-python[browseruse]``).""" +"""browser-use SDK integration (optional dependency ``hud[browseruse]``).""" from .agent import BrowserUseAgent, BrowserUseConfig diff --git a/hud/agents/browser_use/agent.py b/hud/agents/browser_use/agent.py index 959d4f758..2360ef0b4 100644 --- a/hud/agents/browser_use/agent.py +++ b/hud/agents/browser_use/agent.py @@ -10,7 +10,7 @@ The agent is stateless w.r.t. the env: it holds only config and is driven by ``await agent(run)``, receiving the run handle per call. ``browser-use`` is an optional dependency -(``hud-python[browseruse]``), imported lazily inside ``rollout``. +(``hud[browseruse]``), imported lazily inside ``rollout``. """ from __future__ import annotations diff --git a/hud/agents/robot/__init__.py b/hud/agents/robot/__init__.py index 46f9bb1e1..cba9db77b 100644 --- a/hud/agents/robot/__init__.py +++ b/hud/agents/robot/__init__.py @@ -17,7 +17,7 @@ :class:`~hud.agents.types.ObservationStep`, and each re-inference an :class:`~hud.agents.types.InferenceStep`, so runs stream live into the HUD trace viewer. -This subpackage needs the ``robot`` extra (``pip install 'hud-python[robot]'``) for +This subpackage needs the ``robot`` extra (``pip install 'hud[robot]'``) for ``numpy`` + ``msgpack``; importing :mod:`hud.agents` alone never pulls them in. """ diff --git a/hud/agents/robot/video.py b/hud/agents/robot/video.py index f557d0e2a..0435878ee 100644 --- a/hud/agents/robot/video.py +++ b/hud/agents/robot/video.py @@ -195,7 +195,7 @@ def __init__(self, *, fps: int, trace_id: str | None) -> None: importlib.import_module("av") except Exception as exc: raise RuntimeError( - "robot video streaming requires PyAV — `pip install 'hud-python[robot]'`" + "robot video streaming requires PyAV — `pip install 'hud[robot]'`" ) from exc self._fps = fps self._trace_id = trace_id diff --git a/hud/agents/tests/test_base.py b/hud/agents/tests/test_base.py index b11241657..9d3799e7d 100644 --- a/hud/agents/tests/test_base.py +++ b/hud/agents/tests/test_base.py @@ -67,10 +67,10 @@ def find_spec(self, fullname: str, path: Any = None, target: Any = None) -> None if "ClaudeAgent" in vars(hud.agents): # drop any cached lazy export monkeypatch.delitem(hud.agents.__dict__, "ClaudeAgent") - with pytest.raises(ImportError, match=r"hud-python\[agents\]"): + with pytest.raises(ImportError, match=r"hud\[agents\]"): _ = hud.agents.ClaudeAgent - with pytest.raises(ImportError, match=r"hud-python\[agents\]"): + with pytest.raises(ImportError, match=r"hud\[agents\]"): _ = AgentType.CLAUDE.cls diff --git a/hud/cli/templates.py b/hud/cli/templates.py index 5be236857..3589cc242 100644 --- a/hud/cli/templates.py +++ b/hud/cli/templates.py @@ -134,7 +134,7 @@ async def test(): name = "{name}" version = "0.1.0" requires-python = ">=3.11" -dependencies = ["hud-python"] +dependencies = ["hud"] [tool.uv] package = false diff --git a/hud/cli/utils/version_check.py b/hud/cli/utils/version_check.py index 5ae9d07df..45f69582a 100644 --- a/hud/cli/utils/version_check.py +++ b/hud/cli/utils/version_check.py @@ -1,10 +1,10 @@ """Version checking utilities for HUD CLI. -This module handles checking for updates to the hud-python package +This module handles checking for updates to the hud package and prompting users to upgrade when a new version is available. Features: -- Checks PyPI for the latest version of hud-python +- Checks PyPI for the latest version of hud - Caches results for 6 hours to avoid excessive API calls - Displays a friendly prompt when an update is available - Can be disabled with HUD_SKIP_VERSION_CHECK=1 environment variable @@ -41,7 +41,7 @@ CACHE_DURATION = 6 * 60 * 60 # PyPI API URL for package info -PYPI_URL = "https://pypi.org/pypi/hud-python/json" +PYPI_URL = "https://pypi.org/pypi/hud/json" class VersionInfo(NamedTuple): @@ -62,7 +62,7 @@ def _is_in_virtualenv() -> bool: def _get_current_version() -> str: - """Get the currently installed version of hud-python.""" + """Get the currently installed version of hud.""" try: from hud import __version__ @@ -166,7 +166,7 @@ def _compare_versions(current: str, latest: str) -> bool: def check_for_updates() -> VersionInfo | None: - """Check for updates to hud-python. + """Check for updates to hud. This function checks PyPI for the latest version and caches the result for 6 hours to avoid excessive API calls. @@ -238,12 +238,12 @@ def display_update_prompt(console: HUDConsole | None = None) -> None: info = check_for_updates() if info and info.is_outdated: if _is_in_virtualenv(): - upgrade_cmd = "uv sync --upgrade-package hud-python" + upgrade_cmd = "uv sync --upgrade-package hud" else: - upgrade_cmd = "uv tool upgrade hud-python" + upgrade_cmd = "uv tool upgrade hud" console.print( - f"[yellow]🆕 A new version of hud-python is available: " + f"[yellow]🆕 A new version of hud is available: " f"[bold cyan]{escape(info.latest)}[/bold cyan] " f"(current: [dim]{escape(info.current)}[/dim])\n" f" Run: [bold yellow]{escape(upgrade_cmd)}[/bold yellow] to update[/yellow]" diff --git a/hud/train/client.py b/hud/train/client.py index b5aa9c95b..7d6e86924 100644 --- a/hud/train/client.py +++ b/hud/train/client.py @@ -188,13 +188,13 @@ async def forward_backward_custom( ``forward`` → run ``loss_fn`` locally (torch autograd) → ship per-token gradients to ``backward``. Any differentiable loss over π_θ and the :class:`DatumTensors` scalars works (e.g. GLM double-sided IS). Requires - torch (``pip install 'hud-python[train]'``). + torch (``pip install 'hud[train]'``). """ try: import torch except ImportError as exc: raise ImportError( - "forward_backward_custom requires torch; install 'hud-python[train]'" + "forward_backward_custom requires torch; install 'hud[train]'" ) from exc forward = await self.forward(trajectories, group_size=group_size, reward_scale=reward_scale) diff --git a/hud/version.py b/hud/version.py index edb7f91d7..a00dab56a 100644 --- a/hud/version.py +++ b/hud/version.py @@ -4,4 +4,4 @@ from __future__ import annotations -__version__ = "0.6.8" +__version__ = "0.6.9" diff --git a/integrations/tests/test_harbor.py b/integrations/tests/test_harbor.py index b7343b517..e25930925 100644 --- a/integrations/tests/test_harbor.py +++ b/integrations/tests/test_harbor.py @@ -93,7 +93,7 @@ async def solve(n: int = 1): _DOCKERFILE = """\ FROM python:3.11-slim -RUN pip install hud-python +RUN pip install hud COPY env.py ./ CMD ["hud", "serve", "env:env"] """ diff --git a/pyproject.toml b/pyproject.toml index ab85b3b50..b1fd54a9c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] -name = "hud-python" -version = "0.6.8" +name = "hud" +version = "0.6.9" description = "SDK for the HUD platform." readme = "README.md" requires-python = ">=3.11, <3.13" @@ -110,7 +110,7 @@ packages = ["hud"] [project.optional-dependencies] # AI providers (openai, anthropic, google-genai) are now core dependencies; this -# extra is kept empty so `hud-python[agents]` and the `agent` alias still resolve. +# extra is kept empty so `hud[agents]` and the `agent` alias still resolve. agents = [] # AWS Bedrock support for ClaudeAgent @@ -120,7 +120,7 @@ bedrock = [ # Development dependencies - includes testing, linting, and automation tools dev = [ - "hud-python[agents]", # Include agents for dev + "hud[agents]", # Include agents for dev "dotenv>=0.9.9", # Testing and linting "ruff >=0.11.8, <0.15.0", @@ -132,7 +132,7 @@ dev = [ ] # Alias for backwards compatibility -agent = ["hud-python[agents]"] +agent = ["hud[agents]"] browseruse = [ "browser-use>=0.11.13", ] diff --git a/shim/README.md b/shim/README.md new file mode 100644 index 000000000..7d65193a2 --- /dev/null +++ b/shim/README.md @@ -0,0 +1,29 @@ +# hud-python → hud + +The HUD SDK is now published on PyPI as [`hud`](https://pypi.org/project/hud/). +The import name (`import hud`) and the CLI (`hud`) are unchanged — only the +package name on PyPI moved. + +This package is an empty shim that depends on `hud`, so existing installs and +requirements files keep working. Please migrate at your convenience: + +```bash +# instead of +pip install hud-python +uv tool install hud-python + +# use +pip install hud +uv tool install hud +``` + +And replace `hud-python` with `hud` in `pyproject.toml`, `requirements.txt`, +Dockerfiles, and CI configs. + +Note: if you have a pre-rename `hud-python` (< 0.6.9) already installed, run +`pip uninstall hud-python` before installing `hud` — both ship the same +top-level `hud` package and would overwrite each other. Upgrading in place +(`pip install -U hud-python`) is also safe: it moves you onto this shim. + +Docs: [docs.hud.ai](https://docs.hud.ai) · Source: +[github.com/hud-evals/hud-python](https://github.com/hud-evals/hud-python) diff --git a/shim/pyproject.toml b/shim/pyproject.toml new file mode 100644 index 000000000..ded8605d0 --- /dev/null +++ b/shim/pyproject.toml @@ -0,0 +1,52 @@ +[project] +name = "hud-python" +version = "0.6.9" +description = "The HUD SDK was renamed to 'hud'. This package just installs it." +readme = "README.md" +requires-python = ">=3.11, <3.13" +authors = [ +{ name = "HUD", email = "founders@hud.ai" }, +] +license = { text = "MIT" } +dependencies = [ + "hud>=0.6.9,<0.7", +] +classifiers = [ + "Development Status :: 7 - Inactive", + "Intended Audience :: Developers", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", +] + +[project.urls] +"Homepage" = "https://github.com/hud-evals/hud-python" +"Bug Tracker" = "https://github.com/hud-evals/hud-python/issues" +"Documentation" = "https://docs.hud.ai" + +# Entry points reference modules provided by the 'hud' dependency, so +# `uv tool install hud-python` / `uv tool upgrade hud-python` keep producing +# working executables after the rename. +[project.scripts] +hud = "hud.cli:main" +hud-python = "hud.cli:main" + +# Pass-through extras so `pip install 'hud-python[robot]'` etc. keep resolving. +[project.optional-dependencies] +agents = ["hud[agents]"] +agent = ["hud[agent]"] +bedrock = ["hud[bedrock]"] +browseruse = ["hud[browseruse]"] +daytona = ["hud[daytona]"] +dev = ["hud[dev]"] +modal = ["hud[modal]"] +robot = ["hud[robot]"] +train = ["hud[train]"] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +# Metapackage: no files of its own, everything comes from the 'hud' dependency. +[tool.hatch.build.targets.wheel] +bypass-selection = true From c9e82f932d492c1291bad9bfbd7e83367517dcf1 Mon Sep 17 00:00:00 2001 From: lorenss-m Date: Tue, 14 Jul 2026 11:08:46 -0700 Subject: [PATCH 2/2] test(version): expect 0.6.9 after the rename bump Co-authored-by: Cursor --- hud/tests/test_version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hud/tests/test_version.py b/hud/tests/test_version.py index 9d8ce154f..13019b107 100644 --- a/hud/tests/test_version.py +++ b/hud/tests/test_version.py @@ -5,4 +5,4 @@ def test_import(): """Test that the package can be imported.""" import hud - assert hud.__version__ == "0.6.8" + assert hud.__version__ == "0.6.9"