Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Ambiguous Alternatives Detected" from a sample in Mermaid doc #844

Open
NonStatic2014 opened this issue Jan 22, 2025 · 0 comments
Open

Comments

@NonStatic2014
Copy link

NonStatic2014 commented Jan 22, 2025

Describe the bug
"Ambiguous Alternatives Detected" from a sample in Mermaid doc

To Reproduce
Steps to reproduce the behavior:

  1. Go to Mermaid doc for "gitgraph"
  2. Copy the sample and save it as a.mmd
    gitGraph
        commit id: "ZERO"
        branch develop
        branch release
        commit id:"A"
        checkout main
        commit id:"ONE"
        checkout develop
        commit id:"B"
        checkout main
        merge develop id:"MERGE"
        commit id:"TWO"
        checkout release
        cherry-pick id:"MERGE" parent:"B"
        commit id:"THREE"
        checkout develop
        commit id:"C"
  1. Run mmdc -i a.mmd
  2. Get an error:
❯ mmdc -i a.mmd
Generating single mermaid chart
Ambiguous Alternatives Detected: <0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1> in <MANY2> inside <GitGraph​> Rule,
<NEWLINE, commit, id:> may appears as a prefix path in all these alternatives.
See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES
For Further details.

Expected behavior
Generate an image for this graph.

Screenshots
N/A

Desktop (please complete the following information):

  • OS: Windows 11 WSL Ubuntu 24.04
  • Browser N/A
  • Version 11.4.2

Smartphone (please complete the following information):

N/A

Additional context
None

@NonStatic2014 NonStatic2014 changed the title "Ambiguous Alternatives Detected" from a sample from Mermaid doc "Ambiguous Alternatives Detected" from a sample in Mermaid doc Jan 22, 2025
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

No branches or pull requests

1 participant