Since ferrum tracks node ids in frontend but does not listen to DOM.documentUpdated it's possible that the following sequence of events happens:
Ferrum::Node has node_id in memory
DOM.documentUpdated happens
calling methods on the node returns information for a new node that has matching id
this would happen because they seem to start again from zero so they are not unique during single session
Fix
Make all Node objects listen to DOM.documentUpdated after which the objects should become stale so that all new commands issued with the node raise an exception.
https://chromedevtools.github.io/devtools-protocol/tot/DOM/#event-documentUpdated
Problem
Since ferrum tracks node ids in frontend but does not listen to DOM.documentUpdated it's possible that the following sequence of events happens:
Fix
Make all Node objects listen to DOM.documentUpdated after which the objects should become stale so that all new commands issued with the node raise an exception.