diff --git a/.claude/commands/reset.md b/.claude/commands/reset.md index 37646fdb..61a90a2e 100644 --- a/.claude/commands/reset.md +++ b/.claude/commands/reset.md @@ -149,6 +149,11 @@ Every skill file under `.claude/skills/job-application-assistant/` opens with a ## Identity +### Languages + +| Language | Level | Notes | +|----------|-------|-------| + ## Education ## Professional Experience diff --git a/CHANGELOG.md b/CHANGELOG.md index 0768e140..a8b9d8ff 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -68,6 +68,15 @@ per-file diff commands. ### Fixed +- **`/reset profile` keeps the `### Languages` table header under Identity** + (`.claude/commands/reset.md` Step 3, `tests/test_reset_command.py`) - `04-job-evaluation.md`'s + Language Gate and `job-scraper/search-queries.md`'s query-language generation both read "your + Languages table" from `01-candidate-profile.md`, but the skeleton `/reset` wrote left + `## Identity` empty, so after a reset `/rank` and `/scrape` looked for a table the file no + longer had. The skeleton now carries `### Languages` and the table's header and separator + rows, derived from the shipped file in the test; the placeholder data row is deliberately + not reintroduced. Follow-up noted on #532. + - **`05-cv-templates.md` snippets write the `\cventry` date argument with an ASCII hyphen, as the same file's own rule requires** (`.claude/skills/job-application-assistant/05-cv-templates.md`, `framework_version: 1.4.6 -> 1.4.7`) - the in-progress-qualification snippet under "In-progress diff --git a/tests/test_reset_command.py b/tests/test_reset_command.py index 78815cba..acea544c 100644 --- a/tests/test_reset_command.py +++ b/tests/test_reset_command.py @@ -252,6 +252,28 @@ class TestResetTargetsTheHeadingsTheShippedFilesHave(unittest.TestCase): f"a reset must leave {filename}'s framework_version readable and unchanged", ) + def test_candidate_skeleton_keeps_the_languages_table_under_identity(self): + # 04-job-evaluation.md's Language Gate and job-scraper/search-queries.md + # both read "your Languages table" from 01-candidate-profile.md. The + # skeleton had `## Identity` with nothing under it, so after a reset the + # gate and the scraper looked for a table the file no longer had. Both + # the `### Languages` heading and the table header row are derived from + # the shipped file; the placeholder data row is deliberately not kept. + shipped = (SKILL_DIR / "01-candidate-profile.md").read_text(encoding="utf-8") + start = shipped.index("### Languages") + header_rows = [ + line for line in shipped[start:].splitlines()[1:] + if line.startswith("|") + ][:2] + self.assertEqual(len(header_rows), 2, "the shipped Languages table must have a header and a separator row") + block = skeleton_block(self.reset, "01-candidate-profile.md") + identity = block[block.index("## Identity"): block.index("## Education")] + self.assertIn("### Languages", identity, "the Languages table must sit under Identity, as shipped") + for row in header_rows: + with self.subTest(row=row): + self.assertIn(row, identity) + self.assertNotIn("[LANGUAGE]", block, "a reset must not reintroduce a placeholder data row") + def test_partial_anchors_exist_in_the_files_they_target(self): # (reset.md anchor phrase, file, heading the replacement must re-emit) cases = (