resolvedVariableModes is empty if the node doesn’t have at least one variable defined. This is also the case if the parent node has an explicit mode.
Expected behavior: According to the documentation, nodes have default mode values, which should be returned regardless whether the node has a variable or not. resolvedVariableModes | Plugin API