Skip to content
TheChatArchiveThe Chat Archive
composer-2.5· unknownHugging Face ibragim-bad/swe_rebench_07_2026_trajectories

Vize suppression comments do not suppress template-phase diagnostics @vize:ignore-start…

  1. User

    Vize suppression comments do not suppress template-phase diagnostics

    @vize:ignore-start / @vize:ignore-end regions and @vize:forget must suppress matching diagnostics even when the affected rule runs during the template phase. Suppression boundaries, unmatched directives, and later unrelated diagnostics must retain their normal behavior.

    Interface

    No new interfaces are introduced.

  2. Assistant

    I'll investigate how Vize suppression comments interact with template-phase diagnostics in the codebase.

  3. Assistant

    Implementing prescan for ignore-start/ignore-end and forget so they apply before the template phase, matching @vize:expected.

  4. Assistant

    Removing dead forget_next_element traversal logic now that prescan handles it.

  5. Assistant

    Adding regression tests and running the patina test suite.

  6. Assistant

    The bug is that comment.loc.start.line is wrong for some comments — offset_to_line gives the correct line. Updating ignore-region handling to use it.

  7. Assistant

    All tests pass. Updating the prescan comment and verifying the final code.

  8. Assistant

    Fixed suppression for template-phase diagnostics.

    Root cause: @vize:ignore-start / @vize:ignore-end and @vize:forget were only applied during AST traversal, which runs after run_on_template. Template-phase rules like vue/no-dupe-v-else-if emitted diagnostics before suppression was registered.

    Fix: Extended the pre-scan pass (already used for @vize:expected / @vize:level) to also register:

    • @vize:ignore-start / @vize:ignore-end regions
    • @vize:forget element ranges

    For ignore boundaries, line numbers now come from offset_to_line() instead of comment.loc.start.line, which was wrong for comments after the first line (e.g. ignore-end on line 3 was reported as line 1).

    Regression tests added in directives.rs for:

    • ignore regions suppressing run_on_template diagnostics
    • boundary preservation (errors outside the region still reported)
    • @vize:forget suppressing only the next element’s template-phase diagnostics

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.