Mishkat al-Masabih 1684
وَعَنْ جَعْفَرِ بْنِ مُحَمَّدٍ عَنْ أَبِيهِ أَنَّ الْحَسَنَ بْنَ عَلِيٍّ كَانَ جَالِسًا فَمُرَّ عَلَيْهِ بِجَنَازَةٍ فَقَامَ النَّاسُ حَتَّى جَاوَزَتِ الْجَنَازَةُ فَقَالَ الْحَسَنُ: إِنَّمَا مُرَّ بِجَنَازَةِ يَهُودِيٍّ وَكَانَ رَسُولِ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ عَلَى طَرِيقِهَا جَالِسا وَكره أَن تعلوا رَأسه جَنَازَة يَهُودِيّ فَقَامَ. رَوَاهُ النَّسَائِيّ
From Jaʿfar ibn Muhammad, from his father: Al-Hasan ibn ʿAli was sitting when a funeral was carried past him, and the people stood up until the funeral had passed. Al-Hasan said: "It was only that the funeral of a Jew was carried past, and the Messenger of Allah ﷺ was sitting on its way, and he disliked that the funeral of a Jew should be above his head, so he stood up." Reported by an-Nasaʾi.