OpenRPA version: 1.4.50
OpenFlow version: 1.4.36
Using self hosted openflow:
Error message:
My colleague discovered that when he had a workflow which had “-” in the name, the Workflow designer reports an error when he tries to add a String In argument with a default value.
So he is allowed to save the workflow (that has a weird name admittedly), code, run and use it, with String Out parameters for instance. But when he adds a String In parameter with a default argument, then the error occurs. In my opinion, he should never have been allowed to save it with this name in the first place, if the workflow name does not support normal usage (adding String In parameters for with default values).
I have attached an example workflow here.
Bug - Workflow.json (4.0 KB)
I hope it gets imported with “-” in its name.
It does not have a default value for the parameter, but when you add it and try to save the error occurs.
When setting an empty string as default parameter:
System.NullReferenceException: Object reference not set to an instance of an object.
at MS.Internal.Xaml.Parser.XamlScanner.ReadElement()
at MS.Internal.Xaml.Parser.XamlScanner.DoXmlRead()
at MS.Internal.Xaml.Parser.XamlPullParser.<P_NonemptyPropertyElement>d__11.MoveNext()
at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyElement>d__9.MoveNext()
at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__8.MoveNext()
at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__5.MoveNext()
at MS.Internal.Xaml.Parser.XamlPullParser.<Parse>d__4.MoveNext()
at MS.Internal.Xaml.NodeStreamSorter.MoveNext()
at System.Xaml.XamlXmlReader.Read()
at System.Activities.Debugger.XamlDebuggerXmlReader.Read()
at System.Xaml.XamlSubreader.LimitedRead()
at System.Activities.XamlIntegration.DynamicActivityXamlReader.BufferedPropertyList.BufferDefinitions(DynamicActivityXamlReader parent)
at System.Activities.XamlIntegration.DynamicActivityXamlReader.ProcessCurrentNode()
at System.Activities.XamlIntegration.DynamicActivityXamlReader.Read()
at Microsoft.Activities.Presentation.Xaml.ActivityTemplateFactoryBuilderReader.Read()
at Microsoft.Activities.Presentation.Xaml.ViewStateXamlHelper.StripViewStateElement(XamlReader inputReader, Dictionary`2& viewStateInfo, Dictionary`2& viewStateSourceLocationMap)
at Microsoft.Activities.Presentation.Xaml.ViewStateXamlHelper.ConvertViewStateToAttachedProperties(XamlReader inputReader, ViewStateIdManager idManager, Dictionary`2& viewStateSourceLocationMap)
at Microsoft.Activities.Presentation.Xaml.WorkflowDesignerXamlHelper.DeserializeString(String text, DeserializationMode mode, IList`1& loadErrors, Dictionary`2& sourceLocations)
at Microsoft.Activities.Presentation.Xaml.WorkflowDesignerXamlHelper.DeserializeString(String text, IList`1& loadErrors, Dictionary`2& sourceLocations)
at Microsoft.Activities.Presentation.Xaml.WorkflowDesignerXamlHelper.SerializeToString(Object obj, String fileName)
at System.Activities.Presentation.WorkflowDesigner.WriteModelToText(String fileName)
And this error when setting some string:
System.Xaml.XamlParseException: 'this:Bug_-_Workflow.String_Argument_In' is not a valid XAML member name.
at MS.Internal.Xaml.Parser.XamlScanner.PreprocessAttributes()
at MS.Internal.Xaml.Parser.XamlScanner.ReadObjectElement(XamlName name, Boolean isEmptyTag)
at MS.Internal.Xaml.Parser.XamlScanner.DoXmlRead()
at MS.Internal.Xaml.Parser.XamlPullParser.<Parse>d__4.MoveNext()
at MS.Internal.Xaml.NodeStreamSorter.StartNewNodeStreamWithSettingsPreamble()
at MS.Internal.Xaml.NodeStreamSorter..ctor(XamlParserContext context, XamlPullParser parser, XamlXmlReaderSettings settings, Dictionary`2 xmlnsDictionary)
at System.Xaml.XamlXmlReader.Initialize(XmlReader givenXmlReader, XamlSchemaContext schemaContext, XamlXmlReaderSettings settings)
at System.Activities.Debugger.XamlDebuggerXmlReader..ctor(TextReader underlyingTextReader, XamlSchemaContext schemaContext, Assembly localAssembly)
at Microsoft.Activities.Presentation.Xaml.WorkflowDesignerXamlHelper.DeserializeString(String text, DeserializationMode mode, IList`1& loadErrors, Dictionary`2& sourceLocations)
at Microsoft.Activities.Presentation.Xaml.WorkflowDesignerXamlHelper.DeserializeString(String text, IList`1& loadErrors, Dictionary`2& sourceLocations)
at Microsoft.Activities.Presentation.Xaml.WorkflowDesignerXamlHelper.SerializeToString(Object obj, String fileName)
at System.Activities.Presentation.WorkflowDesigner.WriteModelToText(String fileName)