Do not use has_key in snippets, as this is no longer available in python3.