Author: daijy
Date: Wed Nov  4 07:18:15 2015
New Revision: 1712485

URL: http://svn.apache.org/viewvc?rev=1712485&view=rev
Log:
PIG-4725: Typo in FrontendException messages "Incompatable"

Modified:
    pig/trunk/CHANGES.txt
    pig/trunk/src/org/apache/pig/newplan/logical/relational/LogicalSchema.java
    pig/trunk/test/org/apache/pig/test/TestEvalPipeline2.java
    pig/trunk/test/org/apache/pig/test/TestLogicalPlanBuilder.java

Modified: pig/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1712485&r1=1712484&r2=1712485&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Wed Nov  4 07:18:15 2015
@@ -69,6 +69,8 @@ PIG-4639: Add better parser for Apache H
 
 BUG FIXES
 
+PIG-4725: Typo in FrontendException messages "Incompatable" (nsmith via daijy)
+
 PIG-4721: IsEmpty documentation error (nsmith via daijy)
 
 PIG-4712: [Pig on Tez] NPE in Bloom UDF after Union (rohini)

Modified: 
pig/trunk/src/org/apache/pig/newplan/logical/relational/LogicalSchema.java
URL: 
http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/newplan/logical/relational/LogicalSchema.java?rev=1712485&r1=1712484&r2=1712485&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/newplan/logical/relational/LogicalSchema.java 
(original)
+++ pig/trunk/src/org/apache/pig/newplan/logical/relational/LogicalSchema.java 
Wed Nov  4 07:18:15 2015
@@ -363,7 +363,7 @@ public class LogicalSchema {
             if (mode==MergeMode.UnionInner) {
                 if (fs1.type!=fs2.type)
                     // We don't merge inner schema of different type for 
union, throw exception
-                    throw new FrontendException("Incompatable field schema: 
left is \"" + fs1.toString(false) + "\", right is \"" + fs2.toString(false) + 
"\"", 1031);
+                    throw new FrontendException("Incompatible field schema: 
left is \"" + fs1.toString(false) + "\", right is \"" + fs2.toString(false) + 
"\"", 1031);
                 else
                     mergedType = fs1.type;
             }
@@ -371,7 +371,7 @@ public class LogicalSchema {
                 if (fs1.type==DataType.NULL||fs1.type==DataType.BYTEARRAY)  // 
If declared schema does not have type part
                     mergedType = fs2.type;
                 else if (!DataType.castable(fs1.type, fs2.type))
-                    throw new FrontendException("Incompatable field schema: 
declared is \"" + fs1.toString(false) + "\", infered is \"" + 
fs2.toString(false) + "\"", 1031);
+                    throw new FrontendException("Incompatible field schema: 
declared is \"" + fs1.toString(false) + "\", infered is \"" + 
fs2.toString(false) + "\"", 1031);
                 else mergedType = fs1.type; // If compatible type, we take the 
declared type
             }
             else {
@@ -438,7 +438,7 @@ public class LogicalSchema {
                                 // Only check compatibility
                                 mergedSubSchema = 
LogicalSchema.merge(fs1.schema, fs2.schema, MergeMode.LoadForEachInner);
                             } catch (FrontendException e) {
-                                throw new FrontendException("Incompatable 
field schema: left is \"" + fs1.toString(false) + "\", right is \"" + 
fs2.toString(false) + "\"", 1031);
+                                throw new FrontendException("Incompatible 
field schema: left is \"" + fs1.toString(false) + "\", right is \"" + 
fs2.toString(false) + "\"", 1031);
                             }
                         }
                     }
@@ -757,7 +757,7 @@ public class LogicalSchema {
             if (mode==MergeMode.Union) // In union, incompatible type result a 
null schema
                 return null;
             else
-                throw new FrontendException("Incompatable schema: left is \"" 
+ s1.toString(false) + "\", right is \"" + s2.toString(false) + "\"", 1031);    
+                throw new FrontendException("Incompatible schema: left is \"" 
+ s1.toString(false) + "\", right is \"" + s2.toString(false) + "\"", 1031);    
         }
             
         LogicalSchema mergedSchema = new LogicalSchema();

Modified: pig/trunk/test/org/apache/pig/test/TestEvalPipeline2.java
URL: 
http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/test/TestEvalPipeline2.java?rev=1712485&r1=1712484&r2=1712485&view=diff
==============================================================================
--- pig/trunk/test/org/apache/pig/test/TestEvalPipeline2.java (original)
+++ pig/trunk/test/org/apache/pig/test/TestEvalPipeline2.java Wed Nov  4 
07:18:15 2015
@@ -810,7 +810,7 @@ public class TestEvalPipeline2 {
             pigServer.openIterator("c");
         } catch (Exception e) {
             PigException pe = LogUtils.getPigException(e);
-            Util.checkStrContainsSubStr(pe.getMessage(), "Incompatable 
schema");
+            Util.checkStrContainsSubStr(pe.getMessage(), "Incompatible 
schema");
             return;
         }
         Assert.fail();

Modified: pig/trunk/test/org/apache/pig/test/TestLogicalPlanBuilder.java
URL: 
http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/test/TestLogicalPlanBuilder.java?rev=1712485&r1=1712484&r2=1712485&view=diff
==============================================================================
--- pig/trunk/test/org/apache/pig/test/TestLogicalPlanBuilder.java (original)
+++ pig/trunk/test/org/apache/pig/test/TestLogicalPlanBuilder.java Wed Nov  4 
07:18:15 2015
@@ -1204,13 +1204,13 @@ public class TestLogicalPlanBuilder {
         try {
             buildPlan( query + "c = foreach b generate group as mygroup:{t: 
(myname, myage)}, COUNT(a) as mycount;");
         } catch (AssertionFailedError e) {
-            Assert.assertTrue(e.getMessage().contains("Incompatable field 
schema"));
+            Assert.assertTrue(e.getMessage().contains("Incompatible field 
schema"));
         }
 
         try {
             buildPlan( query + "c = foreach b generate flatten(group) as 
(myname, myage, mygpa), COUNT(a) as mycount;");
         } catch (AssertionFailedError e) {
-            Assert.assertTrue(e.getMessage().contains("Incompatable schema"));
+            Assert.assertTrue(e.getMessage().contains("Incompatible schema"));
         }
     }
 


Reply via email to