hadoop-pig-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefan Groschupf (JIRA)" <j...@apache.org>
Subject [jira] Commented: (PIG-100) Tests: NullPointerException parser.QueryParser.Alias(QueryParser.java:471)
Date Thu, 21 Feb 2008 19:13:19 GMT

    [ https://issues.apache.org/jira/browse/PIG-100?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12571151#action_12571151
] 

Stefan Groschupf commented on PIG-100:
--------------------------------------

Olga, 
there is always value in throwing an exception especially for such a young project as pig.

Pig does in many cases a bad job in giving the user an idea of what is going on/ wrong. 
On the one hand side I can understand that there is an interestes  of not bordering users
with stack traces. On the other hand side, users of pig are not end users but mostly developers.
Showing stack traces will help to understand faster the problem - it will invite more developer
to read the code - what will help to grow the contributor base of a open source project. What
finally will help to iron out more issues faster.

There are endless debates about exception handling but from my experience throwing an exception
and handle it as high as possible always help to improve code stability.
Fail early...
Just my 2 cents.

> Tests: NullPointerException parser.QueryParser.Alias(QueryParser.java:471)
> --------------------------------------------------------------------------
>
>                 Key: PIG-100
>                 URL: https://issues.apache.org/jira/browse/PIG-100
>             Project: Pig
>          Issue Type: Bug
>          Components: impl
>    Affects Versions: 0.1.0
>            Reporter: Benjamin Francisoud
>            Priority: Minor
>         Attachments: PIG-100-tests.log, PIG-100-v01.patch
>
>
> I think the root problem was that I forget to specify the configuration using -Djunit.hadoop.conf=hadoop-site.xml
while running the tests.
> But the error could be clearer...
> The logs are big so I will provide them in a separate file...
> But the core problem is:
> {noformat}
>     [junit] java.lang.NullPointerException
>     [junit] 	at org.apache.pig.impl.logicalLayer.parser.QueryParser.Alias(QueryParser.java:471)
>     [junit] 	at org.apache.pig.impl.logicalLayer.parser.QueryParser.NestedExpr(QueryParser.java:411)
>     [junit] 	at org.apache.pig.impl.logicalLayer.parser.QueryParser.NestedExpr(QueryParser.java:417)
>     [junit] 	at org.apache.pig.impl.logicalLayer.parser.QueryParser.GroupItem(QueryParser.java:1027)
> ...
>     [junit] org.apache.pig.impl.logicalLayer.parser.ParseException: Encountered "group"
at line 1, column 9.
>     [junit] Was expecting one of:
>     [junit]     <IDENTIFIER> ...
>     [junit]     "(" ...
>     [junit]     
>     [junit] 	at org.apache.pig.impl.logicalLayer.parser.QueryParser.generateParseException(QueryParser.java:4142)
> ...
>     [junit] org.apache.pig.impl.logicalLayer.parser.ParseException: Encountered "generate"
at line 1, column 1.
>     [junit] Was expecting one of:
>     [junit]     "load" ...
>     [junit]     "filter" ...
> {noformat}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message