{"record":{"id":"6989c364b509bde4","repo":"mem0ai/mem0","slug":"both-pod-config-and-serverless-config-cannot-b","errorCode":null,"errorMessage":"Both 'pod_config' and 'serverless_config' cannot be specified. Choose one deployment option.","messagePattern":"Both 'pod_config' and 'serverless_config' cannot be specified\\. Choose one deployment option\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"mem0/configs/vector_stores/pinecone.py","lineNumber":38,"sourceCode":"    extra_params: Optional[Dict[str, Any]] = Field(None, description=\"Additional parameters for Pinecone client\")\n    namespace: Optional[str] = Field(None, description=\"Namespace for the collection\")\n\n    @model_validator(mode=\"before\")\n    @classmethod\n    def check_api_key_or_client(cls, values: Dict[str, Any]) -> Dict[str, Any]:\n        api_key, client = values.get(\"api_key\"), values.get(\"client\")\n        if not api_key and not client and \"PINECONE_API_KEY\" not in os.environ:\n            raise ValueError(\n                \"Either 'api_key' or 'client' must be provided, or PINECONE_API_KEY environment variable must be set.\"\n            )\n        return values\n\n    @model_validator(mode=\"before\")\n    @classmethod\n    def check_pod_or_serverless(cls, values: Dict[str, Any]) -> Dict[str, Any]:\n        pod_config, serverless_config = values.get(\"pod_config\"), values.get(\"serverless_config\")\n        if pod_config and serverless_config:\n            raise ValueError(\n                \"Both 'pod_config' and 'serverless_config' cannot be specified. Choose one deployment option.\"\n            )\n        return values\n\n    @model_validator(mode=\"before\")\n    @classmethod\n    def validate_extra_fields(cls, values: Dict[str, Any]) -> Dict[str, Any]:\n        allowed_fields = set(cls.model_fields.keys())\n        input_fields = set(values.keys())\n        extra_fields = input_fields - allowed_fields\n        if extra_fields:\n            raise ValueError(\n                f\"Extra fields not allowed: {', '.join(extra_fields)}. Please input only the following fields: {', '.join(allowed_fields)}\"\n            )\n        return values\n\n    model_config = ConfigDict(arbitrary_types_allowed=True)\n","sourceCodeStart":20,"sourceCodeEnd":56,"githubUrl":"https://github.com/mem0ai/mem0/blob/001c235229be8795e3834520467bd0d661ed8f34/mem0/configs/vector_stores/pinecone.py#L20-L56","documentation":"Error \"Both 'pod_config' and 'serverless_config' cannot be specified. Choose one deployment option.\" thrown in mem0ai/mem0.","triggerScenarios":"Thrown at mem0/configs/vector_stores/pinecone.py:38 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Specify only one of pod_config or serverless_config in the Pinecone config."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"001c235229be8795e3834520467bd0d661ed8f34","analyzedAt":"2026-08-15T01:55:42.685Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}