Increase of WebUI: The runtime operation is missing parameters warnings

0
Since upgrading to 10.25.15 we've had a massive spike of WARNING - WebUI: The runtime operation '' is missing parameters: [CurrentObject]. This might lead to an unresolvable XPath: These were never an issue before and seems to be degrading the performance of our app. The CurrentObject being referenced is one on the list of available Variables as per the image.How would I fix this? Or is this a bug for Mendix to resolve?
asked
2 answers
1

This is actually a problem that has existed in earlier Mendix versions as well, and in many cases it has been somewhat unstable or intermittent. It usually appears when the runtime tries to evaluate an XPath that depends on CurrentObject, but at certain moments in the page lifecycle that object is not available yet.


Even if Studio Pro shows $CurrentObject in the list of available variables, that only means the expression is valid in the design context. At runtime there can still be moments where the widget is rendered or refreshed before that object is fully available. That is when you start seeing warnings like:


The runtime operation is missing parameters: [CurrentObject]


So this is often less about the XPath syntax being wrong, and more about the page or widget context not being stable at runtime.


From your screenshot, it looks like the XPath is being used inside a nested context, probably within a Data View or another widget where the current context object can temporarily disappear during refreshes, conditional visibility changes, or rerendering after the upgrade.


A common cause is using $CurrentObject in a widget that is not guaranteed to always have that context. For example, if a list or parent container refreshes, Mendix may briefly try to evaluate the constraint before the inner context becomes available again.


One possible improvement is to avoid relying on $CurrentObject in the XPath if possible. In many cases it is more stable to reference a page parameter or parent object directly instead of the local context.


Another approach is to move the retrieve logic into a data source microflow, which gives you more control and avoids runtime XPath evaluation in unstable UI contexts.


If this resolves your issue, please mark the answer as accepted so it can help others facing the same problem.



answered
0

I figured out the problem, we in the process of converting our grids to Grid2, if you have a Grid2 with a listener on it, a dataview listening to the widget inside the dataview another Grid2 with a retrieve from database, when loading the page for the first time you’ll get the warning, I assume as no row has been selected yet there is no $currentObject for the Dataview or Grid2 to reference, hence the warning.


As Ahmet Kudu suggested, changing the retrieve logic into a data source microflow or by Association fixes the issue.


My next question is would excessive amount of warnings slow down the App?

answered