[2026 errata] sync_sprint2.py scans 2026/ instead of 2026/working/ and rewrites issues.json with an empty Track B
Assessment
- Difficulty
- 3/5
- Estimated time
- Half a day
- Newbie friendliness
- 25/100
Research direction
Start in 2026/working/polling/scripts/sync_sprint2.py, where EXISTING_DIR_PATH points at 2026 instead of 2026/working, and read load_existing_from_remote() and build_updated_config(). Run the reproduction snippet in the issue: it should report 10 existing entries and keep 10 Track B entries rather than 0. Done means the Track B lookup finds all ten LLM files and the script refuses to write an empty Track B list. A linked pull request (#165) already exists, so check it before starting.
Written by the indexing model from the issue text.
Description
Affected section
Other (Sprint 2 polling tooling under 2026/working/polling/scripts/)
Where does the issue appear?
GitHub source
What is incorrect?
sync_sprint2.py looks for the existing LLM01 to LLM10 entries in the wrong directory. EXISTING_DIR_PATH is "2026", but since the working/ / final/ split (#83, with path fixes in #84) the entries live in 2026/working/. The module docstring itself says the source is 2026/working/ (existing entries: LLM01_*.md ... LLM10_*.md).
load_existing_from_remote() lists 2026/ through the Contents API and keeps only files that match ^(LLM(?:0[1-9]|10))_.*\.md$. 2026/ now contains README.md, _template.md, final/ and working/, so nothing matches and the function returns an empty list without any warning.
The empty list then flows through the rest of the pipeline:
reconcile()reports all 10 Track B entries as removed.print_diff()prints "removals are NOT auto-applied. Verify manually."build_updated_config()does apply them: it setsnew_config["track_b"] = local_b, i.e. the empty list.main()Phase 4 callswrite_config(), so a normal run (no--dry-run, no--no-write) overwritesissues.jsonwith"track_b": [].- Phase 5 then has no Track B entries to compare against the existing
sprint-2issues, and the NEXT STEPS block tells the operator to commit and push that file so the Apps Script form can fetch it andrebuildSprintTwoFormDynamic()can rebuild the ballot from it.
So the documented workflow silently empties the Track B half of the registry that the voting form is built from.
Proposed correction
- Set
EXISTING_DIR_PATH = "2026/working"(the directory the docstring already names). - Fail loudly instead of rewriting the registry when discovery returns nothing: if
load_existing_from_remote()finds zero entries while the registry has Track B entries, print an error and return a non-zero exit code before Phase 4. - Make the code match the printed promise that removals are not auto-applied, or stop printing it: keep the registry's existing entry when its file is not found remotely, unless an explicit flag is passed.
Supporting evidence
Reproduced on origin/main @ 9253e38, Python 3.11, no network access. The Contents API and raw-file fetches are replaced with reads from a local checkout, so the "remote" is exactly the tree on main. Run from 2026/working/polling/scripts/:
python -c "
import json, pathlib
import sync_sprint2 as ss
root = pathlib.Path('../../../..').resolve()
ss.list_directory = lambda path, branch, token: [
{'type': 'dir' if p.is_dir() else 'file', 'name': p.name} for p in (root / path).iterdir()]
ss.fetch_markdown = lambda path, branch, token: (root / path).read_text(encoding='utf-8')
config = json.loads((root / ss.REGISTRY_REPO_PATH).read_text(encoding='utf-8'))
local_b = ss.load_existing_from_remote('main', None)
known = {e['file']: e['id'] for e in config['track_a']}
local_a, _ = ss.load_candidates_from_remote('main', None, known)
print('existing entries found:', len(local_b))
diff = ss.reconcile(local_b, local_a, config)
print('removed from Track B:', len(diff['removed_b']))
new = ss.build_updated_config(local_b, local_a, config)
print('track_b in rewritten registry:', len(new['track_b']), '(registry had', len(config['track_b']), ')')
"
Output:
existing entries found: 0
removed from Track B: 10
track_b in rewritten registry: 0 (registry had 10 )
For comparison, pointing the same function at 2026/working finds all ten entries (LLM01_PromptInjection.md through LLM10_UnboundedConsumption.md), because parse_first_heading() and humanize_existing_title() already handle those files.
This is independent of #162 (exit codes when API calls fail): here every API call succeeds and the script still produces a wrong registry.
Acknowledgments
- I checked the published release and the canonical GitHub source for an existing correction.
- I agree to follow the OWASP Code of Conduct.
- Dominant language
- JavaScript
- Stars
- 177
- Forks
- 57
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from GenAI-Security-Project/GenAI-LLM-Top10
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
GenAI-Security-Project/GenAI-LLM-Top10#176 · 1 comment · 1 reaction ·
-
Difficulty 1/5 Under an hour Newbie friendliness 66/100
GenAI-Security-Project/GenAI-LLM-Top10#131 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 28/100
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
-
[Release feedback] Make Zenodo source bundles reproducible across checkoutsPossibly taken @drk-ram claimed this 20 days ago. Open
Difficulty 3/5 1-2 days Newbie friendliness 32/100
All issues in GenAI-Security-Project/GenAI-LLM-Top10
Similar issues
-
Document lexicon.default.userconfig and lexicon.default.userconfig.enforced in config.sample.phpOpenenhancement feature: settings good first issue
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
grafana/viz-contract#151 ·
Maintainers usually reply within 1 day
-
status: needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
mastra-ai/mastra#32336 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
nextcloud-libraries/nextcloud-vue#9280 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
jellyfin/jellyfin-web#8910 ·
Maintainers usually reply within 1 day