[ https://issues.apache.org/jira/browse/SOLR-11263?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16859704#comment-16859704 ]
Munendra S N commented on SOLR-11263: ------------------------------------- [^SOLR-11263.patch] [~ichattopadhyaya] In the master, NPE is not thrown on undefined fields. This change was done in SOLR-11610. I have attached a test to verify this While writing a test, I observed that * there is no check on minimum number of args required for a function query. So, if user passes *payload()* without any args, NPE is thrown. Few of these cases were handled in SOLR-11883. Problem is that parseArg() in FunctionQParser could return null and only few function queries handles the null returned by parseArg(). I will raise separate issue for the args validation * Other function queries like docfreq, tf doesn't fail on undefined field(This behavior is present from the beginning) whereas payload fails on undefined field > Payload function throws NPE for undefined fields > ------------------------------------------------ > > Key: SOLR-11263 > URL: https://issues.apache.org/jira/browse/SOLR-11263 > Project: Solr > Issue Type: Bug > Affects Versions: 6.6 > Reporter: Ishan Chattopadhyaya > Priority: Major > Attachments: SOLR-11263.patch > > > With an undefined field used with the payload function query, there's an NPE > thrown. Maybe we should throw a meaningful message instead. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org