Copilot commented on code in PR #472:
URL: https://github.com/apache/arrow-dotnet/pull/472#discussion_r4308946531


##########
src/Apache.Arrow/C/CArrowSchemaImporter.cs:
##########
@@ -372,7 +381,7 @@ public Field GetAsField(ExtensionTypeRegistry 
extensionRegistry)
 
                 bool nullable = 
_cSchema->GetFlag(CArrowSchema.ArrowFlagNullable);
 
-                IArrowType type = GetAsType();
+                IArrowType type = GetAsType(extensionRegistry);

Review Comment:
   Direct extension-valued dictionaries still lose their extension type with 
the new registry overloads. `CArrowSchemaExporter.ExportField` places the 
extension metadata on the outer dictionary field, but `TryCreateType` receives 
the entire `DictionaryType`; `GuidExtensionDefinition` rejects it because it 
expects fixed-size binary storage. Resolve the extension against 
`DictionaryType.ValueType`, then rebuild the dictionary with its original index 
type and ordering. Add a direct `dictionary<int32, uuid>` round-trip test: the 
existing `dictionary<int32, list<uuid>>` test only exercises metadata on a 
nested list child.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to