You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "lidavidm (via GitHub)" <gi...@apache.org> on 2025/03/07 00:44:26 UTC

Re: [PR] GH-655: Failure in UnionReader.read after DecimalVector promotion to UnionVector [arrow-java]

lidavidm commented on code in PR #656:
URL: https://github.com/apache/arrow-java/pull/656#discussion_r1984241340


##########
vector/src/main/codegen/templates/UnionVector.java:
##########
@@ -306,6 +307,9 @@ public StructVector getStruct() {
 
   public ${name}Vector get${name}Vector(String name) {
     if (${uncappedName}Vector == null) {
+      ${uncappedName}Vector = internalStruct.getChild(fieldName(MinorType.${name?upper_case}), ${name}Vector.class);
+      if (${uncappedName}Vector == null) {
+        throw new IllegalArgumentException("No ${uncappedName} present. Provide ArrowType argument to create a new vector");

Review Comment:
   Is it just me or is there no closing brace here?
   
   Shouldn't we only add this new check for parameterized/nested types?



-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org