{"record":{"id":"7cd344de5c242577","repo":"apache/iceberg","slug":"unsupported-manifest-content-type-content","errorCode":null,"errorMessage":"Unsupported manifest content type:${content}","messagePattern":"Unsupported manifest content type:(.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"spark/v4.0/spark/src/main/java/org/apache/iceberg/spark/actions/BaseSparkAction.java","lineNumber":436,"sourceCode":"    }\n\n    public CloseableIterator<FileInfo> entries(ManifestFileBean manifest) {\n      ManifestContent content = manifest.content();\n      FileIO io = table.getValue().io();\n      Map<Integer, PartitionSpec> specs = table.getValue().specs();\n      List<String> proj = ImmutableList.of(DataFile.FILE_PATH.name(), DataFile.CONTENT.name());\n\n      switch (content) {\n        case DATA:\n          return CloseableIterator.transform(\n              ManifestFiles.read(manifest, io, specs).select(proj).iterator(),\n              ReadManifest::toFileInfo);\n        case DELETES:\n          return CloseableIterator.transform(\n              ManifestFiles.readDeleteManifest(manifest, io, specs).select(proj).iterator(),\n              ReadManifest::toFileInfo);\n        default:\n          throw new IllegalArgumentException(\"Unsupported manifest content type:\" + content);\n      }\n    }\n\n    static FileInfo toFileInfo(ContentFile<?> file) {\n      return new FileInfo(file.location(), file.content().toString());\n    }\n  }\n}\n","sourceCodeStart":418,"sourceCodeEnd":445,"githubUrl":"https://github.com/apache/iceberg/blob/86d9c8fc543e7c56c9f624eb725f76c9baff9570/spark/v4.0/spark/src/main/java/org/apache/iceberg/spark/actions/BaseSparkAction.java#L418-L445","documentation":"When enumerating manifest entries, BaseSparkAction switches over the ManifestContent type (DATA vs DELETES). Any other ManifestContent value reaches default and throws IllegalArgumentException 'Unsupported manifest content type:'. This protects against manifests of unknown content kind.","triggerScenarios":"Spark actions reading manifests whose ManifestContent is not DATA or DELETES — e.g. manifests written by a newer Iceberg version introducing a new content type, then processed by an older iceberg-spark.","commonSituations":"Version skew between the engine that wrote the manifests and the cluster running Spark actions; corrupted manifest lists.","solutions":["Upgrade iceberg-spark to a version supporting the manifest content type in the message","Verify manifest list files are valid and were produced by your Iceberg version","Align writer and reader Iceberg versions"],"exampleFix":"// before\ndefault:\n  throw new IllegalArgumentException(\"Unsupported manifest content type:\" + content);\n// after\ndefault:\n  throw new IllegalArgumentException(\"Unsupported manifest content type: \" + content + \"; upgrade iceberg-spark to a version that supports it\");","handlingStrategy":"try-catch","validationCode":"for (ManifestFile m : snapshot.allManifests(io)) { Preconditions.checkArgument(m.content() == ManifestContent.DATA || m.content() == ManifestContent.DELETES, \"Unknown manifest content %s\", m.content()); }","typeGuard":null,"tryCatchPattern":"try { action.execute(); } catch (IllegalArgumentException e) { if (e.getMessage().startsWith(\"Unsupported manifest content type\")) { LOG.error(\"Manifests from newer Iceberg version detected\", e); } throw e; }","preventionTips":["Upgrade iceberg-spark before reading tables written by newer versions","Avoid mixing Iceberg client versions against the same table"],"tags":["spark","manifest","version-skew","illegal-argument"],"backgroundTag":"invalid-enum-value","analyzedSha":"86d9c8fc543e7c56c9f624eb725f76c9baff9570","analyzedAt":"2026-09-12T00:46:39.097Z","contentChangedAt":"2026-09-12T00:46:39.097Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}