pln-planning-tools / Starmap

Roadmap Planning Tool
https://starmap.site
Other
20 stars 8 forks source link

Children issues fail to render if "ETA" is used instead of "eta" #352

Open BigLep opened 1 year ago

BigLep commented 1 year ago

My child issues didn't load if I had "ETA" capitalized (even though that's what is in the readme/docs). It did render when I switched to lower case. Can we have case-insensitive matches?

AlexxNica commented 1 year ago

@BigLep Can you share the link to the issue you're trying to render?

AlexxNica commented 1 year ago

I created a couple of issues to test this and it seems to be working fine for both variations (eta and ETA fields):

SgtPooki commented 1 year ago

@BigLep I recently fixed an issue where our regex would fail to match eta if there were a space prior to "eta:", e.g. " eta:"

I tested this on an issue where i had no intentional space in front of "eta:" but for some reason the data we got in our eta parsing method had a space.

If you share the issue i can dive into this further or confirm it's resolved.

SgtPooki commented 1 year ago

FYI that we have a case-insensitive regex grabbing the ETA value at https://github.com/pln-planning-tools/Starmap/blob/3dc65092d7e6ded1d9209c0a6ea86e5c116f309c/lib/helpers.ts#L21

However, we don't currently have any tests confirming an uppercase ETA: https://github.com/pln-planning-tools/Starmap/blob/3dc65092d7e6ded1d9209c0a6ea86e5c116f309c/tests/unit/parser.test.ts#L6

Action items: