Closed tpurschke closed 2 years ago
Workaround only in roles/lib/files/FWO.Report.Filter/Ast/AstNodeFilter.cs lines 477ff:
throw new SyntaxException($"Error: wrong time range format.", new System.Range(23, 26)); // Unexpected token
// we have some hard coded string positions here which we should get rid off
// how can we access the tokens[position].Position information here?
@NilsPur can you advice please?
fixed by shift of time selection to LSB
Filter Error - Error: wrong time range format at FWO.Report.Filter.Ast.AstNodeFilter.resolveTimeRange(String timeRange) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/lib/files/FWO.Report.Filter/Ast/AstNodeFilter.cs:line 407 at FWO.Report.Filter.Ast.AstNodeFilter.ExtractTimeQuery(DynGraphqlQuery query) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/lib/files/FWO.Report.Filter/Ast/AstNodeFilter.cs:line 54 at FWO.Report.Filter.Ast.AstNodeFilter.Extract(DynGraphqlQuery& query) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/lib/files/FWO.Report.Filter/Ast/AstNodeFilter.cs:line 36 at FWO.Report.Filter.Ast.AstNodeConnector.Extract(DynGraphqlQuery& query) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/lib/files/FWO.Report.Filter/Ast/AstNodeConnector.cs:line 31 at FWO.Report.Filter.DynGraphqlQuery.Generate(AstNode ast) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/lib/files/FWO.Report.Filter/DynGraphqlQuery.cs:line 45 at FWO.Report.Filter.Compiler.Compile(String input) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/lib/files/FWO.Report.Filter/Compiler.cs:line 17 at FWO.Ui.Pages.Report.TryFilter(ChangeEventArgs changeArgs) in /home/tim/dev/tpur-fwo/firewall-orchestrator/roles/ui/files/FWO_UI/Pages/Report.razor:line 415 See logs for details!
[x] idea for time format (can also be transformed into an issue for future implementation in phase 2/3):
type=changes and time>"2021-07-01" and time<"2021-10-01" and (gateway="fortigate_demo")
-> obsolete/done with shift to LSB[x] time works only as first parameter if "time" is used after other criteria an error is thrown. (done by @abarz722) -> obsolete with shift to LSB
@NilsPur - can we handle this by adjusting the grammar to only allow time as top-level-element?
[x] start and stop operator dont seem to work timefilter issue (variable name is stop_time/start_time not stop/start):