From abcde7ddf215fb4d586201fc85bf81674181936e Mon Sep 17 00:00:00 2001 From: s1gr1d <32902192+s1gr1d@users.noreply.github.com> Date: Thu, 16 Jul 2026 14:53:28 +0200 Subject: [PATCH] fix(skills): Make sure digest file is written/read correctly --- .../skills/track-framework-updates/SKILL.md | 18 +++++++++++++----- .../scripts/write_job_summary.py | 17 +++++++++++++++-- 2 files changed, 28 insertions(+), 7 deletions(-) diff --git a/.agents/skills/track-framework-updates/SKILL.md b/.agents/skills/track-framework-updates/SKILL.md index 7ebd148d6c85..a3a14417619c 100644 --- a/.agents/skills/track-framework-updates/SKILL.md +++ b/.agents/skills/track-framework-updates/SKILL.md @@ -107,12 +107,20 @@ For each release or RFC that plausibly needs SDK work, draft one concrete, actio ### Step 6: Write output artifacts -Produce **three files** in the skill's `output/` directory: +The `collect_updates.py` script in Step 1 prints its output path, e.g.: -1. **`output/framework-updates-raw.json`** — already written by Step 1. -2. **`output/framework-updates-digest.json`** — structured, machine-readable digest. Follow the schema in `assets/digest-schema.json`. -3. **`output/framework-updates-digest.md`** — human-readable digest. Follow the structure in `assets/digest-template.md`: - - Group by Client-Side / Server-Side / Meta-Framework. +``` +Wrote /abs/path/to/.agents/skills/track-framework-updates/output/framework-updates-raw.json: ... +``` + +Use that printed path to derive the output directory. All three files must be written to the **same directory** as `framework-updates-raw.json` — never relative paths like `output/` from the workspace root. + +Produce **three files**: + +1. The raw JSON was already written by Step 1 — no action needed. +2. **`/framework-updates-digest.json`** — structured, machine-readable digest. Follow the schema in `assets/digest-schema.json`. +3. **`/framework-updates-digest.md`** — human-readable digest. Follow the structure in `assets/digest-template.md`: + - Group by Client-Side / Server-Side / Meta-Framework / Platform / Libraries. - Omit frameworks with no activity. - Include a "Run notes" section only if a fetcher reported errors. diff --git a/.agents/skills/track-framework-updates/scripts/write_job_summary.py b/.agents/skills/track-framework-updates/scripts/write_job_summary.py index 6ba3c406c524..595c9ec7b2ac 100644 --- a/.agents/skills/track-framework-updates/scripts/write_job_summary.py +++ b/.agents/skills/track-framework-updates/scripts/write_job_summary.py @@ -11,6 +11,7 @@ from __future__ import annotations import json +import os import sys @@ -85,8 +86,20 @@ def main() -> int: digest = f.read().strip() if digest: lines.append(digest) - except OSError: - lines.append("_Digest file not found._") + except OSError as e: + lines.append(f"_Digest file not found: `{digest_path}` ({e})_") + lines.append("") + # List what is actually in the output dir to help diagnose path mismatches + output_dir = os.path.dirname(os.path.abspath(digest_path)) + try: + found = os.listdir(output_dir) + if found: + lines.append(f"Files present in `{output_dir}`:") + lines.extend(f"- `{name}`" for name in sorted(found)) + else: + lines.append(f"`{output_dir}` exists but is empty.") + except OSError: + lines.append(f"Output directory not found: `{output_dir}`") # Run metrics at the bottom cost_str = (