-
Notifications
You must be signed in to change notification settings - Fork 49
Description
Last generated: 2026-01-22T18:36:00.310Z
Provider: openai
Model: gpt-5.2
Summary
Modernize CI and release automation around this small Python package by: (1) making GitHub Actions the source of truth (drop Travis), (2) adding a minimal, deterministic test matrix, and (3) adding packaging/release guardrails (build checks, metadata validation). Keep changes small and low-risk while improving reliability and reducing maintainer toil.
Direction (what and why)
-
Converge on GitHub Actions for CI
The repo still has.travis.ymland a growing set of “auto-*” workflows. Centralizing core CI in one clear workflow reduces ambiguity, ensures PRs are validated consistently, and makes failures easier to triage. -
Stabilize test & packaging signals
This project is a library; most issues will be import/runtime compatibility, protobuf generation drift, and packaging metadata problems. Add a tight CI loop: lint-free packaging build, install test, andpytestacross a small Python matrix. -
Remove or quarantine heavyweight / accidental artifacts
bfg-1.15.0.jar(14MB) is not part of the package runtime and increases clone/CI time. Track it as a tooling artifact or move it out of the main branch history going forward (don’t rewrite history unless explicitly desired).
Plan (next 1–3 steps)
-
Add a single, clear CI workflow for tests + package build
- Create:
.github/workflows/ci.yml - Jobs:
test: runpytestvia tox (or direct) onpython-version: [3.9, 3.10, 3.11, 3.12]build:python -m buildandtwine check dist/*
- Cache pip to reduce runtime.
- Example implementation details:
- Install:
pip install -U pip - Dev deps:
pip install -r requirements_dev.txt(or use tox) - Run:
pytest -q - Build:
pip install build twinethenpython -m buildandtwine check --strict dist/*
- Install:
- Create:
-
Make tox the single entry point for local + CI test execution
- Update
tox.inito:- Define envs for
py39,py310,py311,py312 - Ensure
depsincludespytestand anything inrequirements_dev.txtthat tests need - Commands:
pytest -q
- Define envs for
- Then CI calls
tox -p auto(parallel) to keep it consistent with local runs.
- Update
-
Deprecate Travis and remove CI ambiguity
- Add a note in
README.rstthat CI is GitHub Actions. - Either:
- Remove
.travis.yml(preferred), or - Keep it but mark it clearly deprecated at the top and stop maintaining it.
- Remove
- If you remove it, also remove
travis_pypi_setup.pyif it’s no longer used by anything.
- Add a note in
Risks/unknowns
- Python version support policy is unclear:
setup.cfg/setup.pymay not declare supported versions accurately. CI may reveal failures on newer Python (especially around protobuf/pillow). If failures appear, adjust the matrix to the actually-supported versions and document it inREADME.rst+ packaging classifiers. - Generated protobuf files (
tensorboard_logger/tf_protobuf/*_pb2.py) may be tied to an older protobuf runtime. Upgrading test matrix could expose incompatibilities. Prefer pinning protobuf runtime in test deps if needed. - Large binary in repo (
bfg-1.15.0.jar): removing it without rewriting history is safe (future clones still fetch history unless shallow), but rewriting history requires coordination. Decide explicitly before doing a BFG pass.
Suggested tests
- CI (required)
toxmatrix:py39, py310, py311, py312python -m build+twine check --strict dist/*
- Local quick checks
pip install -e . && pytest -q- Minimal import test:
python -c "import tensorboard_logger; print(tensorboard_logger.__version__)"(or equivalent)
- Regression/behavior
- Run existing
tests/test_tensorboard_logger.pyacross matrix to catch filesystem/protobuf differences. - Add a small smoke test (if missing) that writes an event file to a temp dir and verifies it exists and is non-empty.
- Run existing
Verification checklist
- GitHub Actions “ci” workflow runs on PRs and
masterpushes - All supported Python versions pass
pytest -
python -m buildsucceeds andtwine check --strictpasses -
.travis.ymlis removed or clearly deprecated - README references the correct CI system and supported Python versions