【发布时间】:2019-10-15 05:33:40
【问题描述】:
我正在尝试使用 GCP DLP API 客户端库(Python 3)创建 DE 识别模板。我已经使用 POST 方法成功创建了去标识化模板。 DE-identification 模板的作用是使用 Google KMS 封装的 Key 加密一些 PII 字段。
client.create_deidentify_template(
parent=parent,
deidentify_template=deidentify_template,
template_id=templateId,
retry=google.api_core.gapic_v1.method.DEFAULT,
timeout=google.api_co
re.gapic_v1.method.DEFAULT,
metadata=None)
错误:
ValueError:协议消息 DeidentifyTemplate 没有“deidentifyTemplate”字段。
【问题讨论】:
-
异常ValueError:当内置操作或函数接收到具有正确类型但值不适当的参数时引发,并且该情况没有通过更精确的异常(例如IndexError)来描述。跨度>
标签: python-3.x google-cloud-platform google-cloud-dlp