From 43728320bf150126372ba8b08a19b1c2c9741dfb Mon Sep 17 00:00:00 2001 From: Justin Paul Date: Fri, 22 May 2026 09:37:07 -0400 Subject: [PATCH] ci: default PRODUCT_NAME to repo name (caught by template dispatch test) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit First dispatch on the empty template failed at Chroma collection creation because PRODUCT_NAME was the literal string "" (YAML doesn't expand placeholders), and Chroma rejects collection names containing characters outside [a-zA-Z0-9._-]: chromadb.errors.InvalidArgumentError: Validation error: name: Expected a name containing 3-512 characters from [a-zA-Z0-9._-], starting and ending with a character in [a-zA-Z0-9]. Got: _docs Same fix as the IMAGE env: derive from the repo name dynamically via ${{ github.event.repository.name }}. Cloners can still override explicitly, but a fresh clone now runs the index-rebuild step cleanly out of the box. Verified by re-dispatch — should fail next at docker login (placeholder REGISTRY_PUSH hostname), which is the next-expected fail point and a real per-deployment config the cloner has to fill in. Co-Authored-By: Claude Opus 4.7 (1M context) --- .gitea/workflows/image-only.yml | 7 ++++++- .gitea/workflows/refresh.yml | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/image-only.yml b/.gitea/workflows/image-only.yml index 2085c7d..abe60b2 100644 --- a/.gitea/workflows/image-only.yml +++ b/.gitea/workflows/image-only.yml @@ -23,7 +23,12 @@ env: IMAGE: ${{ github.repository_owner }}/${{ github.event.repository.name }} OLLAMA_URL: http://:11434 EMBED_MODEL: nomic-embed-text - PRODUCT_NAME: + # PRODUCT_NAME defaults to the repo name so a clone works without + # editing. Override here if you want a different identifier (e.g. + # repo "my-product-docs" → PRODUCT_NAME "myproduct"). Used as the + # Chroma collection name, BM25 db filename, and MCP server name — + # see docs_mcp/server.py. + PRODUCT_NAME: ${{ github.event.repository.name }} jobs: build: diff --git a/.gitea/workflows/refresh.yml b/.gitea/workflows/refresh.yml index ee24d97..ef7f504 100644 --- a/.gitea/workflows/refresh.yml +++ b/.gitea/workflows/refresh.yml @@ -34,7 +34,12 @@ env: OLLAMA_URL: http://:11434 EMBED_MODEL: nomic-embed-text - PRODUCT_NAME: + # PRODUCT_NAME defaults to the repo name so a clone works without + # editing. Override here if you want a different identifier (e.g. + # repo "my-product-docs" → PRODUCT_NAME "myproduct"). Used as the + # Chroma collection name, BM25 db filename, and MCP server name — + # see docs_mcp/server.py. + PRODUCT_NAME: ${{ github.event.repository.name }} jobs: refresh: