google-deepmind / google-deepmind/dialog
PyPI release v1.0.0 is missing dialog.Format, dialog.Tags — blocks gemma library
- Dominant language
- Jupyter Notebook
- Stars
- 7
- Forks
- 8
- Avg merge
- 17h 5m
- Merged PRs (30d)
- 1
Description
## Description
The PyPI release `dialog==1.0.0` is missing `dialog.Format` and `dialog.Tags`, which were added to the GitHub main branch after the release. Since the version in `dialog/__init__.py` was not bumped, `pip install dialog` always resolves to the stale PyPI package.
This is the **root cause** of google-deepmind/gemma#559 and google-deepmind/gemma#606 — making it impossible to use the gemma library from source with a standard `pip install`.
## What's missing from PyPI v1.0.0
1. **`dialog/_src/string/str_compat.py`** — contains the `Format` enum (added in commit "Add conversion methods", PiperOrigin-RevId: 868643343)
2. **`dialog/__init__.py`** — PyPI version doesn't export `Format` or `Tags`
GitHub main has both:
```python
from dialog._src.string.str_compat import Format # present on main, missing on PyPI
from dialog._src.tags import Tags # present on main, missing on PyPI
```
## Reproduction
```bash
pip install dialog==1.0.0
python -c "import dialog; print(dialog.Format)"
# AttributeError: module 'dialog' has no attribute 'Format'
```
vs.
```bash
pip install "dialog @ git+https://github.com/google-deepmind/dialog.git"
python -c "import dialog; print(dialog.Format)"
# ✓
```
## Impact
The `gemma` PyPI package (google-deepmind/gemma) imports `dialog.Format` in `gemma/gm/text/_tokenizer.py:196` and `dialog.Tags` in `gemma/gm/tools/_manager.py:64`. With PyPI dialog, any import of gemma's tokenizer or tool system crashes immediately.
## Fix
Bump `__version__` in `dialog/__init__.py` (e.g. to `1.1.0`) and publish a new PyPI release. This will make `pip install dialog` pick up the version that includes `Format` and `Tags`.
Contributor guide
Assessment
This issue has not been assessed yet.