Use writeMetric() for Zenoss 5 compatibility.

PythonCollector was marginally compatible with Zenoss 5 without this
change, but would fail if any datasources or datapoints had underscores
in their name.