Skip to content

Clash of UUIDs between different elements #32

@strogonoff

Description

@strogonoff

I’m working on rendering this as a collection with a Firelight GUI. Rendering a collection implies a global identifier scope (making possible a reference to a particular document part from anywhere in the collection).

However, after building the collection using bundle exec metanorma site generate --agree-to-terms, I see this (from two different files):

Image Image
  • It appears that Metanorma presentation XML treats identifier scope as per-document in case of this collection. I did not expect this, because it was discussed in context of 10303 that references across the collection are possible.

    However, I can understand that this may be a different case from 10303. Perhaps unlike 10303 this collection is not a “true” Metanorma collection but some other kind of collection (I forgot the precise term): https://github.com/CalConnect/cc-admin-documents/blob/main/metanorma.yml. If so, maybe it’s not Metanorma’s problem. I’ll check whether there is a clash with a “true” collection if I can find one to easily try.

  • It appears that Metanorma generates the same UUID for an element with different contents. In the above screenshot, the elements have identical children, but they have 1) different attributes and 2) different tag names. Those qualify as semantically different contents (a clause#foobar is a very different thing from note#foobar). If UUID is meant to vary on content, then it’s not doing its job.

    (There is a larger problem here, which is that two elements even with identical children, attributes, and tag names, would mean different things if they appear in different place of the document, because unlike a normalized resource graph any part of a document implicitly derives its meaning from its relationships with parents and siblings. This can be debated depending on what was the purpose of content-derived UUIDs, which I do not know.)

This should probably be filed somewhere in some project under metanorma, but I don’t know where. Feel free to transfer appropriately.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions