Fetch SKILL.md from veralang.dev instead of caching locally#22
Conversation
The cached context/SKILL.md drifted when vera updated to v0.0.105 (typed holes). Instead of maintaining a stale copy: - load_skill_md() now fetches from https://veralang.dev/SKILL.md by default, or reads a local file when --skill-md is provided - Deleted context/SKILL.md (the cached copy) - CLI prints which SKILL.md source is being used - --skill-md flag still works for local overrides (e.g. testing unreleased language features) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #22 +/- ##
==========================================
- Coverage 66.95% 66.29% -0.66%
==========================================
Files 10 10
Lines 1053 1068 +15
==========================================
+ Hits 705 708 +3
- Misses 348 360 +12
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe default SKILL.md source was changed from a local snapshot to fetching Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Suggested labels
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@vera_bench/cli.py`:
- Around line 131-138: When language == "vera" and SKILL.md is selected/fetched,
record the SKILL.md source and/or a content hash in the run results metadata so
benchmarks are reproducible; locate the code around the language check
(variables: language, skill_md, SKILL_MD_URL, skill_content) and after calling
load_skill_md(skill_md) add the chosen source string (source = str(skill_md) if
skill_md else SKILL_MD_URL) and a content checksum (compute hash of
skill_content) into the JSONL results metadata writer so each result entry
includes SKILL.md_source and/or SKILL.md_hash fields; keep console.print for
human visibility but ensure the metadata fields are written programmatically
where results are assembled/saved.
In `@vera_bench/prompts.py`:
- Around line 30-33: The network fetch using urllib.request.urlopen on variable
source_str must include a timeout and robust error handling: update the code in
prompts.py where source_str.startswith("http") and the urllib.request.urlopen
call to pass a reasonable timeout (e.g., 5–10 seconds) and wrap the open/read in
a try/except that catches urllib.error.URLError and urllib.error.HTTPError (and
optionally socket.timeout), then log or raise a clear, user-friendly error
message including the URL and the original exception; ensure the
resp.read().decode(...) only runs on successful responses and that resources are
properly closed (keep the with-block pattern).
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 1841b5a9-8f7b-4113-b978-e144dbb17122
⛔ Files ignored due to path filters (1)
context/SKILL.mdis excluded by!context/**
📒 Files selected for processing (4)
CLAUDE.mdREADME.mdvera_bench/cli.pyvera_bench/prompts.py
- urlopen now has 10s timeout and catches URLError/OSError with actionable error message suggesting --skill-md - CLI prints SHA-256 hash (first 12 chars) of SKILL.md content for reproducibility tracking Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@vera_bench/prompts.py`:
- Line 5: Add an explicit import for urllib.error so the exception reference to
urllib.error.URLError resolves at runtime: update the imports that currently
include only urllib.request to also import urllib.error (so the except clause
referencing urllib.error.URLError can catch real network errors instead of
causing AttributeError); locate the import line where urllib.request is imported
and add the urllib.error import alongside it.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 918cdfc6-fab3-4b73-b149-bfa556f9acbf
📒 Files selected for processing (2)
vera_bench/cli.pyvera_bench/prompts.py
Relying on urllib.request to transitively import urllib.error is a CPython implementation detail, not a language guarantee. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Summary
The cached
context/SKILL.mddrifted when vera updated to v0.0.105 (typed holes). Instead of maintaining a stale copy, fetch from the canonical source at runtime.Behaviour
https://veralang.dev/SKILL.mdautomatically--skill-md /path/to/local/SKILL.mdfor testing local changesChanges
prompts.py:load_skill_md()now accepts URL or local path, defaults to veralang.devcli.py: removed hardcodedcontext/SKILL.mdfallback, prints source being usedcontext/SKILL.md(1,773 lines of cached content that drifted)--skill-mdoverrideTest plan
vera-bench run --model X --problem VB-T1-001fetches from URLvera-bench run --model X --skill-md ./local.mduses local fileGenerated with Claude Code
Summary by CodeRabbit
New Features
Documentation