Back to skills
SKILL.md
2683 2026 02 24 Fix Hn Ordering And Emoji Plan 155af117
ASecurityHN source appears before YouTube in several places (stats block, sort priority, source status) but should be last among the main sources (after YouTube, before Web). The test skill SKILL.md also has plain ASCII instead of box-drawing characters and colored circle emojis.
- 9 stars
- 0 votes
- 0 copies
- 0 views
- Added October 11, 2026
Security analysis
100/100npx -y skills add tools-only/X-Skills --skill 2683-2026-02-24-fix-hn-ordering-and-emoji-plan_155af117 --agent claude-codeAre you the author of 2683 2026 02 24 Fix Hn Ordering And Emoji Plan 155af117?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/tools-only-2683-2026-02-24-fix-hn-ordering-and-emoji-plan-155)---
title: "fix: HN ordering and stats block emoji formatting"
type: fix
status: completed
date: 2026-02-24
---
# fix: HN Ordering and Stats Block Emoji Formatting
## Overview
HN source appears before YouTube in several places (stats block, sort priority, source status) but should be last among the main sources (after YouTube, before Web). The test skill SKILL.md also has plain ASCII instead of box-drawing characters and colored circle emojis.
Desired order everywhere: Reddit > X > YouTube > HN > Web
## Problem Statement / Motivation
When testing `/last30daysHN`, the stats block output shows:
- No β
emoji, no π π΅ π‘ π΄ π π£οΈ colored circles
- Plain `|-` instead of `ββ` and `|` instead of `β`
- HN appears before YouTube in the stats
The canonical format (established in commit `7c36866`) is:
```
---
β
All agents reported back!
ββ π Reddit: {N} threads β {N} upvotes β {N} comments
ββ π΅ X: {N} posts β {N} likes β {N} reposts
ββ π΄ YouTube: {N} videos β {N} views β {N} with transcripts
ββ π‘ HN: {N} stories β {N} points β {N} comments
ββ π Web: {N} pages (supplementary)
ββ π£οΈ Top voices: @{handle1} ({N} likes), @{handle2} β r/{sub1}, r/{sub2}
---
```
## Technical Approach
### Files to Modify
#### `scripts/lib/score.py` - sort_items()
- [x] Swap HN and YouTube priority in `sort_items()`:
- YouTube: priority 2 (was 3)
- HN: priority 3 (was 2)
#### `scripts/lib/render.py` - render_source_status()
- [x] Move HN section (lines ~318-324) to AFTER YouTube section (lines ~326-334)
- [x] Verify render_compact() already has correct order (YouTube before HN) - no change expected
#### `SKILL.md` (private repo root)
- [x] Move the π‘ HN stats line AFTER the π΄ YouTube stats line in the template
- [x] Move HN line after YouTube in the footer summary template too
#### `~/.claude/skills/last30daysHN/SKILL.md` (test skill)
- [x] Restore full emoji + box-drawing stats template with correct ordering
- [x] Use canonical format: β
ββ π π΅ π΄ π‘ π π£οΈ ββ β
#### `scripts/lib/ui.py` - show_complete()
- [x] Move HN output after YouTube in both TTY and non-TTY code paths
### Files that are already correct (no change needed)
- `render_compact()` in render.py - already YouTube before HN
- `render_context_snippet()` - score-based ordering, no fixed order
- `last30days.py` pipeline - processing order doesn't affect display
## Acceptance Criteria
- [x] Stats block shows: Reddit > X > YouTube > HN > Web (in that order)
- [x] Stats block has all emojis: β
π π΅ π΄ π‘ π π£οΈ
- [x] Stats block uses box-drawing chars: ββ ββ β
- [x] sort_items() tiebreaker: YouTube before HN
- [x] render_source_status() shows YouTube before HN
- [x] ui.py show_complete() shows YouTube before HN
- [x] All existing tests still pass
- [x] Run sync.sh to deploy after fixes
## Sources & References
- Canonical emoji format established in commit `7c36866` ("Fix v2 output quality")
- YouTube emoji added in commit `c66ca7f` ("feat: Add YouTube as 4th research source")
- HN added in commit `38a7ea2` ("feat(hackernews): add Hacker News as 5th research source")
Attribution
Comments
Loading commentsβ¦