{
  "id": "go/proto-field-mask-path-invalid",
  "signature": "proto: (field mask): invalid path \"user..name\"",
  "signature_zh": "proto：（field mask）：无效路径 \"user..name\"",
  "regex": "proto:\\ \\(field\\ mask\\):\\ invalid\\ path\\ \"user\\.\\.name\"",
  "domain": "go",
  "category": "data_error",
  "subcategory": null,
  "root_cause": "fieldmaskpb validation rejected a path with empty segments or names not present in the message descriptor.",
  "root_cause_type": "generic",
  "root_cause_zh": "fieldmaskpb 验证拒绝了包含空段或消息描述符中不存在的字段名的路径。",
  "versions": [
    {
      "version": "google.golang.org/protobuf v1.31+",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Silently changes semantics; the Update RPC will apply the wrong field mask.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Loses protobuf descriptor validation and interop with other gRPC clients.",
      "fail_rate": 0.75,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "",
      "success_rate": 0.92,
      "how": "fm := &fieldmaskpb.FieldMask{Paths: []string{\"user.name\", \"user.email\"}}\nfm.Normalize()\nif !fm.IsValid(msg) {\n    return nil, status.Error(codes.InvalidArgument, \"invalid field mask\")\n}",
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "success_rate": 0.85,
      "how": "md := msg.ProtoReflect().Descriptor()\nfor _, p := range fm.Paths {\n    if !fieldMaskPathExists(md, p) {\n        return nil, fmt.Errorf(\"unknown field: %s\", p)\n    }\n}",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": null,
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.85,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2024-10-04",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}