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

Gantt Chart aliases require after (dependencies) or break list order defaults #4307

Open
combinatorist opened this issue Apr 17, 2023 · 0 comments
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect

Comments

@combinatorist
Copy link

Description

Gantt charts docs and testing appear to allow a shorthand syntax where each task just starts after the previous task (in that section). It also allows you to explicitly list all the dependencies for an task with the after keyword. The after keyword requires setting aliases on the dependencies so you can refer to them later (which makes sense). It also allows you to list tasks out of order or that run in parallel.

However, the syntax arbitrarily breaks if you try to set an alias without an after. This seems backwards. It should be a problem if I can't find an alias as referenced elsewhere, but setting an alias for the current item, shouldn't require specify it's dependencies.

Steps to reproduce

In the snippet below, d should work just like c does, but setting the alias D for it, creates an error: Invalid date:D). If you remove the task d or just the alias (and comma: D,), then it works.

gantt
section A
a : a, 2023-01-01, 1d
b : b, after a, 1d
c : 1d
d : D, 1d

Screenshots

Screen Shot 2023-04-17 at 11 07 48

Code Sample

No response

Setup

  • Mermaid version:
  • Browser and Version: [Chrome, Edge, Firefox]

Additional Context

FWIW, this might relate to another, possibly unintended feature:

  • setting an after keyword with an alias that hasn't been populated will place the task starting on the current date

In case the best way to solve this issue is more explicit syntax, it might be nice to be able to indicate, that a task simply starts after the previous, and/or that it should start after today and to do those explicitly, not implicitly.

@combinatorist combinatorist added Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect labels Apr 17, 2023
@nirname nirname changed the title Gannt Chart aliases require after (dependencies) or break list order defaults Gantt Chart aliases require after (dependencies) or break list order defaults Aug 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect
Projects
None yet
Development

No branches or pull requests

1 participant