Skip to content

Commit 7b898c0

Browse files
Copilotpelikhan
andauthored
Fix <!-- learning:false --> annotation format and harden parser tolerance (#1751)
* Initial plan * Fix learning:false annotation format and update parser docs/tests - Fix workshop/00-welcome.md and workshop/06-install-gh-aw.md to use canonical <!-- learning:false --> (no space after colon) - Add explicit test case for <!-- learning: false --> (spaced) variant - Update curriculum_assessment.py docstring to list the spaced variant as accepted - Update guidelines.md to note the parser tolerates both formats Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
1 parent 779c82b commit 7b898c0

5 files changed

Lines changed: 7 additions & 3 deletions

File tree

.github/skills/curriculum-quantitative-assessment/curriculum_assessment.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ def is_non_learning_page(raw: str) -> bool:
7171
Accepted formats include::
7272
7373
<!-- learning:false -->
74+
<!-- learning: false -->
7475
<!-- Learning:False -->
7576
<!-- learning : false -->
7677
"""

.github/skills/curriculum-quantitative-assessment/test_curriculum_assessment.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ def test_returns_true_for_bare_tag(self) -> None:
7777
def test_returns_true_case_insensitive(self) -> None:
7878
self.assertTrue(is_non_learning_page("<!-- Learning:False -->"))
7979

80+
def test_returns_true_with_space_after_colon(self) -> None:
81+
self.assertTrue(is_non_learning_page("<!-- learning: false -->"))
82+
8083
def test_returns_true_with_extra_whitespace(self) -> None:
8184
self.assertTrue(is_non_learning_page("<!-- learning : false -->"))
8285

.github/workflows/guidelines.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ Some workshop pages are not substantive learning steps — they are **dispatcher
360360

361361
### Marking a page as a dispatcher
362362

363-
Add the comment `<!-- learning:false -->` anywhere in the file — conventionally placed immediately after the page annotation lines:
363+
Add the comment `<!-- learning:false -->` anywhere in the file — conventionally placed immediately after the page annotation lines. The parser also accepts `<!-- learning: false -->` (with a space after the colon), but the canonical form without the space is preferred:
364364

365365
```markdown
366366
<!-- page-journey: all -->

workshop/00-welcome.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<!-- page-journey: all -->
22
<!-- page-adventure: core -->
3-
<!-- learning: false -->
3+
<!-- learning:false -->
44

55
# Welcome to our Agent Factory Tour
66

workshop/06-install-gh-aw.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<!-- page-journey: all -->
22
<!-- page-adventure: core -->
3-
<!-- learning: false -->
3+
<!-- learning:false -->
44
# Install the gh-aw CLI Extension
55

66
`gh-aw` is the CLI extension that compiles your [agentic workflow](https://github.github.com/gh-aw/introduction/overview/) Markdown files and triggers runs from your terminal. If you're on the GitHub UI path, no local installation is needed: an agent compiles the workflow, and GitHub Actions executes the committed [lock file](https://github.github.com/gh-aw/reference/glossary/#workflow-lock-file-lockyml).

0 commit comments

Comments
 (0)