谷歌云DLP常规自定义词典错误"Dictionary has no "云存储路径" field"



在DLP中,我正在创建一个常规的自定义字典检测器,它指向存储在云存储中的字典文本文件。下面是我为定义custominfotype所做的工作。我相信它遵循https://cloud.google.com/dlp/docs/creating-custom-infotypes-dictionary#examples上的说明。然而,它错误地提示"协议消息"字典没有"cloudstoragepath"。场!"文本文件肯定存在于我的云存储桶中,并且我有适当的凭据。你能告诉我我的语法是不是错了吗?谢谢你。

custom_info_types = [
{
"info_type": {"name": "TAXES"},
"likelihood": google.cloud.dlp_v2.Likelihood.POSSIBLE,
"dictionary": {
"cloudStoragePath": {
"path": "gs://mybucket/myfile.txt"
},
},
}
]

Python不使用驼形大小写,而是使用蛇形大小写。

https://cloud.google.com/dlp/docs/samples/dlp-deidentify-masking dlp_deidentify_masking-python

应该是cloud_storage_path

相关内容

最新更新