Skip to content
This repository was archived by the owner on Jan 2, 2021. It is now read-only.

Exceptions with multiple : in messeage causes internal error in Spectre.Cli #117

Closed
devlead opened this issue Oct 21, 2020 · 1 comment
Closed

Comments

@devlead
Copy link
Contributor

devlead commented Oct 21, 2020

I.e. C:/temp/priv/boom.cake(2,8): somewhere in exception message will cause this exception

Unhandled Exception: System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.
   at System.ThrowHelper.ThrowKeyNotFoundException()
   at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
   at System.Text.RegularExpressions.RegexReplacement.Replace(MatchEvaluator evaluator, Regex regex, String input, Int32 count, Int32 startat)
   at System.Text.RegularExpressions.Regex.Replace(String input, MatchEvaluator evaluator)
   at Spectre.Console.Internal.MarkupParser.Parse(String text, Style style)
   at Spectre.Cli.Internal.Composer.Render(RenderContext context, Int32 maxWidth)
   at Spectre.Console.AnsiConsoleExtensions.Render(IAnsiConsole console, IRenderable renderable)
   at Spectre.Cli.CommandApp.<RunAsync>d__7.MoveNext()

Error lies in Spectre.Console but noticed it had already been fixed upstream so I'll send an PR to address this issue.

devlead added a commit to devlead/spectre.cli that referenced this issue Oct 21, 2020
patriksvensson pushed a commit that referenced this issue Oct 21, 2020
@devlead
Copy link
Contributor Author

devlead commented Oct 21, 2020

Fixed by #118

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant