python: Extract chromium_get_rev_hash and unify the usage