Skip to content

Z303: DUPLICATE_DEF

  • Severity: Error


    Penalty: 0.0 points | Category: general

  • Remediation & Opt-In


    Auto-Fixable: No | Opt-In: No


Rationale

This rule is triggered when the same reference link label [ref-id]: ... is defined multiple times within a single Markdown source file with conflicting target URLs, creating ambiguous link resolution.


How to Fix

Inspect the flagged location in the Markdown file and update the content or configuration:

  • Failing Pattern (Triggers Z303)


    docs/example.md
    <!-- BAD: Multiple definitions for the same ref-id -->
    [doc-ref]: https://example.com/v1
    [doc-ref]: https://example.com/v2
    
  • Passing Pattern (Resolves Z303)


    docs/example.md
    <!-- GOOD: Declare each reference identifier uniquely once per file -->
    [doc-ref-v1]: https://example.com/v1
    [doc-ref-v2]: https://example.com/v2
    

Configuration

.zenzic.toml
# Evaluated during reference definition parsing

Reference

See the Finding Codes Index for finding code details.