The Messenger of Allah ﷺ said, "For one of you to have his belly filled with pus that eats away at him is better for him than to have it filled with poetry."
حدثنا أسود بن عامر قال حدثنا شريك عن الأعمش عن أبي صالح
قال رسول الله ﷺ لأن يمتلئ جوف أحدكم قيحا يريه خير له من أن يمتلئ شعرا
Bukhari, Muslim, Abu Dawud, Tirmidhi, Nasai, and Ibn Majah reported it from Abu Hurairah, and Suyuti indicated in Jami Saghir that it is sahih.