Skip to content

duplicate-view-id

A Saved View id repeats in a Project, across files too.

Severity: error · Since: v1.0.0

For the failing example below, archidocs check prints:

shop/services.yaml:15:5 error duplicate-view-id View id "front" is already used in Project "shop" at shop/more.yaml:3

A Saved View is opened, exported and linked from ADRs by its Qualified id, such as shop:front. Only the first View with an id goes into the Workspace Bundle, so the second could never be opened.

shop/more.yaml:

views:
structural:
front:
title: Front again
level: c2

shop/services.yaml:

services:
web:
name: Web
relationships:
- to: cart
cart:
name: Cart
components:
cart-api:
name: Cart API
search:
name: Search
views:
structural:
front:
title: Front
level: c2

Give one of the Views a different id.

shop/more.yaml:

views:
structural:
front-v2:
title: Front again
level: c2
  • duplicate-id: An Element or Deployment Target id is declared twice in a Project, across files too, whatever its kind or nesting.

Documents the beta branch at cd98671, ahead of the latest release, v1.4.0.