rust-python3: compatibility fix for integer conversion
On python3, `to_py_object()` on the usize gives us a PyLong,
whereas it is the generic `PyObject` already on python2, which fits
the `py.None()` default value.
Upcasting to `PyObject` explicitely in all cases solves the issue.
Differential Revision: https://phab.mercurial-scm.org/D6396
{
"version": 1,
"project": "mercurial",
"project_url": "https://mercurial-scm.org/",
"repo": "..",
"branches": ["default", "stable"],
"environment_type": "virtualenv",
"show_commit_url": "https://www.mercurial-scm.org/repo/hg/rev/",
"benchmark_dir": "benchmarks",
"env_dir": "../.asv/env",
"results_dir": "../.asv/results",
"html_dir": "../.asv/html"
}