You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Background:
We are trying to automate a testcase via robot framework via FlaUI library. We have a custom made GUI to control. Before, we were using TestStackWhite and with that library we were able to scroll up/down in the list and find the "element"/"row" we wanted to interact with.
Issue:
After solving the previous issue. We ran into a new issue. The following error is thrown at random times during our scroll process:
Unhandled Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.AccessViolationException: Attempted to read or write protected memory. This is of
ten an indication that other memory is corrupt.
at Interop.UIAutomationClient.IUIAutomationTreeWalker.GetNextSiblingElement(IUIAutomationElement element)
at FlaUI.UIA3.UIA3TreeWalker.GetNextSibling(AutomationElement element)
at FlaUI.Core.AutomationElementXPathNavigator.MoveToNext()
at MS.Internal.Xml.XPath.XPathDescendantIterator.MoveNext()
at MS.Internal.Xml.XPath.DescendantQuery.Advance()
at MS.Internal.Xml.XPath.FilterQuery.Advance()
at MS.Internal.Xml.XPath.CacheChildrenQuery.GetNextInput()
at MS.Internal.Xml.XPath.CacheChildrenQuery.DecideNextNode()
at MS.Internal.Xml.XPath.CacheChildrenQuery.Advance()
at MS.Internal.Xml.XPath.FilterQuery.Advance()
at MS.Internal.Xml.XPath.CacheChildrenQuery.GetNextInput()
at MS.Internal.Xml.XPath.CacheChildrenQuery.Advance()
at MS.Internal.Xml.XPath.FilterQuery.Advance()
at MS.Internal.Xml.XPath.CacheChildrenQuery.GetNextInput()
at MS.Internal.Xml.XPath.CacheChildrenQuery.Advance()
at MS.Internal.Xml.XPath.FilterQuery.Advance()
at MS.Internal.Xml.XPath.XPathSelectionIterator.MoveNext()
at System.Xml.XPath.XPathNavigator.SelectSingleNode(XPathExpression expression)
at System.Xml.XPath.XPathNavigator.SelectSingleNode(String xpath)
at FlaUI.Core.AutomationElements.AutomationElement.FindFirstByXPath(String xPath)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Python.Runtime.MethodBinder.Invoke(BorrowedReference inst, BorrowedReference args, BorrowedReference kw, MethodBase info, MethodBase[] methodinfo)
at Python.Runtime.MethodObject.Invoke(BorrowedReference target, BorrowedReference args, BorrowedReference kw, MethodBase info)
at Python.Runtime.MethodBinding.tp_call(BorrowedReference ob, BorrowedReference args, BorrowedReference kw)
The code we are executing is the following:
${total_rows_in_list} UUT.get grid rows Count ${item_list}
log to console Checking the item list to find..
# Less attempts needed than rows in list. Each scroll is 3 list items and we scroll 5 times at once.
# Added 10 more scrolls for safe margin.
${scroll_attempts} = Evaluate ${total_rows_in_list} / 15 + 10
FOR ${i} IN RANGE ${total_rows_in_list}
${item_found} Set variable False
UUT.Scroll down ${item_list} 1
UUT.Scroll down ${item_list} 1
UUT.Scroll down ${item_list} 1
UUT.Scroll down ${item_list} 1
UUT.Scroll down ${item_list} 1
Suspend For 2 s
# Check if item is in current list view
${needed_procedure_is_present} ${msg} run keyword and ignore error UUT.Is element offscreen ${demo_procedure}
IF '${needed_item_is_present}' == 'PASS'
log to console Item NR has been found!
# Scroll down one more time because it might be not "visible"
UUT.Scroll down ${item_list} 1
Sleep 2s
log to console Clicking on the item...
UUT.Click ${demo_item}
Set variable ${item_found} True
Exit For Loop
END
END
Do you have any idea/indication on how to prevent the memory issue. Our implementation is currently unstable because of this.
The text was updated successfully, but these errors were encountered:
Background:
We are trying to automate a testcase via robot framework via FlaUI library. We have a custom made GUI to control. Before, we were using TestStackWhite and with that library we were able to scroll up/down in the list and find the "element"/"row" we wanted to interact with.
Issue:
After solving the previous issue. We ran into a new issue. The following error is thrown at random times during our scroll process:
The code we are executing is the following:
Do you have any idea/indication on how to prevent the memory issue. Our implementation is currently unstable because of this.
The text was updated successfully, but these errors were encountered: