Suppress echoing of line in deprecation warnings

This is done by replacing warnings.formatwarning with a replacement
function that ignores the "line" parameter.

This is an ugly hack, and I'm open to better suggestions.