Marwan reported,

Go, Rafi, as my doorkeeper, to Ibn Abbas and say to him, "If every one of us is delighted with what he has been given and loves to be praised for what he has not done, then we shall all be punished."Ibn Abbas replied, "What have you to do with this verse? It was only revealed concerning the People of the Book."Then Ibn Abbas recited, "And remember when Allah took the covenant of those who were given the Scripture, that you must make it clear to the people" [Aal Imran 3:187], this verse.And Ibn Abbas recited, "Do not think that those who rejoice in what they have done and love to be praised for what they have not done" [Aal Imran 3:188].Ibn Abbas said, "The Prophet ﷺ asked them about something, and they concealed it from him and told him something else instead. They went out having shown him that they had answered what he asked, and they sought praise from him for that, and rejoiced in what they had done by concealing from him what he had asked them about."

Ahmad 2712

Sahih

حدثنا حجاج عن ابن جريج قال أخبرني ابن أبي مليكة أن حميد بن عبد الرحمن بن عوف أخبره أن

مروان قال

اذهب يا رافع لبوابه إلى ابن عباس فقل لئن كان كل امرئ منا فرح بما أوتي وأحب أن يحمد بما لم يفعل لنعذبن أجمعون فقال ابن عباس وما لكم وهذه إنما نزلت هذه في أهل الكتاب ثم تلا ابن عباس {وإذ أخذ الله ميثاق الذين أوتوا الكتاب لتبيننه للناس} هذه الآية وتلا ابن عباس {لا تحسبن الذين يفرحون بما أتوا ويحبون أن يحمدوا بما لم يفعلوا} وقال ابن عباس سألهم النبي ﷺ عن شيء فكتموه إياه وأخبروه بغيره فخرجوا قد أروه أن قد أخبروه بما سألهم عنه واستحمدوا بذلك إليه وفرحوا بما أتوا من كتمانهم إياه ما سألهم عنه

أحمد 2712صحيح
Contents
Reference
Commentary
Ayat
Collection
Musnad Ahmad
Book
Abdullah bin Abbas bin Abdul-Muttalib
Numbering
Darussalam 2712
Ahmad 2712