{"record":{"id":"4cdfef63f9bce14a","repo":"pathwaycom/pathway","slug":"schema-registry-settings-is-only-meaningful-for","errorCode":null,"errorMessage":"'schema_registry_settings' is only meaningful for the 'json' format, but {format!r} was specified. The Confluent Schema Registry currently encodes JSON payloads only; remove 'schema_registry_settings' or use format='json'.","messagePattern":"'schema_registry_settings' is only meaningful for the 'json' format, but (.+?) was specified\\. The Confluent Schema Registry currently encodes JSON payloads only; remove 'schema_registry_settings' or use format='json'\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"python/pathway/io/_utils.py","lineNumber":478,"sourceCode":"                \"'subject' was provided without 'schema_registry_settings'. \"\n                \"The 'subject' parameter only has an effect when a schema \"\n                \"registry is configured; either pass 'schema_registry_settings' \"\n                \"or remove 'subject'.\"\n            )\n        if schema_registry_settings is not None and subject is None:\n            raise ValueError(\n                \"'schema_registry_settings' was provided without 'subject'. \"\n                \"When a schema registry is configured, 'subject' must also be \"\n                \"set so the formatter knows which subject to encode under.\"\n            )\n        if subject is not None and not subject:\n            raise ValueError(\n                \"'subject' must be a non-empty string; got an empty string. \"\n                \"Schema Registry subjects identify a named schema version, \"\n                \"and an empty subject is never a valid registry entry.\"\n            )\n        if schema_registry_settings is not None and format != \"json\":\n            raise ValueError(\n                f\"'schema_registry_settings' is only meaningful for the 'json' \"\n                f\"format, but {format!r} was specified. The Confluent Schema \"\n                \"Registry currently encodes JSON payloads only; remove \"\n                \"'schema_registry_settings' or use format='json'.\"\n            )\n\n        key_field_index = None\n        header_fields: dict[str, int] = {}\n        extracted_field_indices: dict[str, int] = {}\n        columns_to_extract: list[ColumnReference] = []\n\n        if topic_name is not None:\n            topic_name_index = cls.add_column_reference_to_extract(\n                topic_name, columns_to_extract, extracted_field_indices\n            )\n            if topic_name._column.dtype not in (dt.STR, dt.ANY):\n                raise ValueError(\n                    \"The topic name column must have a string type, however \"","sourceCodeStart":460,"sourceCodeEnd":496,"githubUrl":"https://github.com/pathwaycom/pathway/blob/fa2f74a4649b7c5908690cf60137263d8d80de5f/python/pathway/io/_utils.py#L460-L496","documentation":"Raised by MessageQueueOutputFormat.build when schema_registry_settings is combined with a format other than 'json'. The Confluent Schema Registry integration in this connector only encodes JSON payloads (JSON Schema), so registry settings with 'dsv', 'raw', or 'plaintext' would be silently unused; Pathway raises instead.","triggerScenarios":"pw.io.kafka.write(table, ..., format='dsv', schema_registry_settings=settings, subject=...); switching an output format from json to raw while keeping registry settings; assuming Avro registry support (format='avro' style usage) that this writer does not have.","commonSituations":"Teams expecting Avro-style schema-registry encoding; refactoring output format while leaving registry options in the call.","solutions":["Use format='json' if you need Schema Registry encoding.","Or remove schema_registry_settings (and subject) when writing dsv/raw/plaintext."],"exampleFix":"# before\npw.io.kafka.write(t, ..., format='raw',\n    schema_registry_settings=settings, subject='s')\n\n# after\npw.io.kafka.write(t, ..., format='json',\n    schema_registry_settings=settings, subject='s')","handlingStrategy":"validation","validationCode":"if schema_registry_settings is not None:\n    assert format == 'json', \"Schema Registry output encoding requires format='json'\"","typeGuard":null,"tryCatchPattern":"try:\n    pw.io.kafka.write(t, ..., format=format, schema_registry_settings=settings, subject=s)\nexcept ValueError as e:\n    if \"only meaningful for the 'json' format\" in str(e):\n        pw.io.kafka.write(t, ..., format=format)  # registry not applicable; drop it\n    else:\n        raise","preventionTips":["Gate schema-registry options behind format=='json' in your sink factory.","Do not assume Avro output; this writer's registry support is JSON-only."],"tags":["pathway","kafka","schema-registry","format","validation"],"backgroundTag":null,"analyzedSha":"fa2f74a4649b7c5908690cf60137263d8d80de5f","analyzedAt":"2026-08-15T01:48:17.006Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}