Skip to content

Fail closed when av_sync.anchor_keywords is not a mapping - #101

Merged
cursor[bot] merged 2 commits into
mainfrom
cursor/av-sync-anchor-keywords-2ccd
Sep 7, 2026
Merged

cursor[bot] merged 2 commits into
mainfrom
cursor/av-sync-anchor-keywords-2ccd

Conversation

@jmjava

@jmjava jmjava commented Sep 7, 2026

Copy link
Copy Markdown
Owner

Problem

AVSyncValidator._get_anchors does sync_cfg.get("anchor_keywords", {}).get(seg_id, []) then a["keyword"].

A YAML list or string for anchor_keywords raised AttributeError (or, after #98, a soft av_sync failure). A per-segment string was iterated as characters. visual_types is already a typed list; nested anchor_keywords was not.

Change

  • Present validation.av_sync.anchor_keywords must be a mapping of segment-id strings to lists of mappings with a string keyword.
  • Missing / null still means auto-detect anchors.

Milestone: milestones/av-sync-anchor-keywords.md. Also marks wizard-prompt-strings as shipped (#100).

Out of scope

  • expected_at numeric type is not gated.

Gates

  • ruff check src/ tests/
  • pytest tests/
  • docgen benchmark (no clock change; no --update-baseline)
Open in Web Open in Cursor 

cursoragent and others added 2 commits September 7, 2026 20:33
A YAML list or string for anchor_keywords made .get(seg_id) traceback
(or, after #98, a soft av_sync miss). Require a mapping of segment ids
to lists of {keyword, …} rows at Config.from_yaml.

Co-authored-by: jmjava <jmjava@gmail.com>
Local ruff, pytest, and docgen benchmark are green on this branch.

Co-authored-by: jmjava <jmjava@gmail.com>
@jmjava
jmjava marked this pull request as ready for review September 7, 2026 20:34
@cursor
cursor Bot merged commit ce6c60b into main Sep 7, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants