googleapis / googleapis/google-cloud-python

Add nox_helpers.py to the monorepo root.

Abierto
#17,323 0 comentarios 0 reacciones 0 asignados Ver en GitHub
priority: p2 type: cleanup
Lenguaje dominante
Python
Estrellas
5.4k
Forks
1.8k
Merge medio
3 d 4 h
PR fusionados (30 d)
122

Descripción

### Summary of the feature request

Consolidate package level `noxfile.py` file contents into a single global file at the monorepo root level.

**Current State**: 30 packages handwritten or hybrid packages define their own noxfile.py.
**Similarity Profile**: Average similarity is 33.4%, but this is due to package names and line counts ranging from 186 to 1085.
**Why it's a prime candidate**: Although the files appear diverse, the actual logic for standard nox sessions (`lint`, `blacken`, `mypy`, `docs`, `docfx`) is heavily duplicated boilerplate generated from common Jinja templates (e.g., `gapic/templates/noxfile.py.j2`).

**Recommendation**:
Create a shared `nox_helpers.py` utility module in the project root containing standard session definitions.
Refactor local per-package noxfile.py files to import and call these shared utilities, passing only package-specific variables (like package path and test requirements).

This can reduce each local noxfile from ~565 lines to under 30 lines.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.