Better fix for older python compat
Make the _evaluate method more general and dedupliacate its usages