PY3: record is a kwarg argument for warnings.catch_warnings