LivingDoc CLI error on text after markdown list items
CompletedHello
I'm trying to compile this simple file with command
~/.dotnet/tools/livingdoc feature-folder .
Feature: US1 Test feature
Scenario: Test scenario
First string
* List item 1
* List item 2
Last string
When something
Then anything
But it shows an error
Framework: .NET 5.0.7
Unhandled exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> Gherkin.CompositeParserException: Parser errors:
(7:1): expected: #EOF, #TableRow, #DocStringSeparator, #StepLine, #TagLine, #ExamplesLine, #ScenarioLine, #RuleLine, #Comment, #Empty, got 'Last string'
at Gherkin.Parser`1.Parse(ITokenScanner tokenScanner, ITokenMatcher tokenMatcher)
at LivingDoc.CLI.Parser.Parser.ParseFeatureFileContent(String featureFileContent, String defaultLanguage) in D:\a\1\s\src\SpecFlow.Integration\LivingDoc.CLI\Parser\Parser.cs:line 287
at LivingDoc.CLI.Parser.Parser.Parse(String rootNodeTitle, String projectLanguage, String workItemPrefix, String workItemUrlTemplate) in D:\a\1\s\src\SpecFlow.Integration\LivingDoc.CLI\Parser\Parser.cs:line 58
at LivingDoc.CLI.ReportGenerator.Generate(GeneratorSource source, Parameters parameters) in D:\a\1\s\src\SpecFlow.Integration\LivingDoc.CLI\ReportGenerator.cs:line 53
at LivingDoc.CLI.ArgumentResolver.Handle(String workingFolder, GeneratorSource source, Parameters parameters) in D:\a\1\s\src\SpecFlow.Integration\LivingDoc.CLI\ArgumentResolver.cs:line 234
at LivingDoc.CLI.ArgumentResolver.<>c__DisplayClass5_0.<Resolve>b__1(Parameters p) in D:\a\1\s\src\SpecFlow.Integration\LivingDoc.CLI\ArgumentResolver.cs:line 179
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Delegate.DynamicInvokeImpl(Object[] args)
at System.Delegate.DynamicInvoke(Object[] args)
at System.CommandLine.Invocation.ModelBindingCommandHandler.InvokeAsync(InvocationContext context)
at System.CommandLine.Invocation.InvocationPipeline.<>c__DisplayClass4_0.<<BuildInvocationChain>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<UseParseErrorReporting>b__21_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass16_0.<<UseHelp>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass25_0.<<UseVersionOption>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass23_0.<<UseTypoCorrections>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<UseSuggestDirective>b__22_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<UseParseDirective>b__20_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<UseDebugDirective>b__11_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<RegisterWithDotnetSuggest>b__10_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass14_0.<<UseExceptionHandler>b__0>d.MoveNext()
-
Hi Eugene Vasetsky,
Thanks for getting in touch.
You can exchange your asterisk for a hyphen and this should resolve your compilation issues.
The problem is the asterisk as this is treated as a gherkin keyword. See here.
As far as I am aware, this is the only shared symbol between markdown and gherkin syntax.
Please let me know if anything further is required.
Many thanks, Jordan.
1
Please sign in to leave a comment.
Comments
1 comment