ES6 bug - Explain API fails deterministically for specific set of search parameters value

I am using ES6.2 (on elastic.co) and I have a giant search query that has many in-line painless scripting. And in that search query, I have "explain": true to see the result scoring explanation. Most of the time the search result returns explanation, but for the same query with a specific set of different search parameters values, it doesn't return the explanation while it returns the search result correctly.

Is it a bug in ES itself that explanation disappear for some reason? Or do I need to do something to get explanation back consistently?

Without more information, like the query, it's extremely hard to say.