His grandfather reported that the Messenger of Allah ﷺ forbade buying and selling in the mosque, announcing lost items there, and reciting poetry in it. He also forbade gathering in circles before the prayer on Friday.
حدثنا مسدد حدثنا يحيى عن ابن عجلان
عن جده أن رسول الله ﷺ نهى عن الشراء والبيع في المسجد وأن تنشد فيه ضالة وأن ينشد فيه شعر ونهى عن التحلق قبل الصلاة يوم الجمعة
Chain evaluation, its isnad is hasan. Nasai narrated it in Kitab Masajid, in the chapter on the prohibition of buying and selling in the masjid, etc., hadith no. 715, from the hadith of Yahya Qattan, with the same chain. Ibn Majah also narrated it, hadith nos. 766 and 1133, and Tirmidhi graded it hasan, hadith no. 322. Ibn Ajlan explicitly stated hearing it directly, as found in Ahmad, 2/179, see also Atraf Musnad, 4/32, hadith no. 517.