Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:6:23

Then there will be no ˹excuse upon˺ examination except they will say, "By Allah, our Lord, we were not those who associated."  

Then their dissension (read accusative fitnatahum or nominative fitnatuhum) their apology, was (read lam takun or lam yakun) only to say, in other words, ˹was only˺ their saying, ‘By God, our Lord (read rabbinā as an adjective of ˹wa’Llāhi, ‘by God’˺, or rabbanā as a vocative) we were never idolaters’.
القرآن:٦:٢٣

ثُمَّ لَمْ تَكُنْ فِتْنَتُهُمْ إِلَّا أَنْ قَالُوا وَاللَّهِ رَبِّنَا مَا كُنَّا مُشْرِكِينَ  

{ثم لم تكن} بالتاء والياء {فتنتّهم} بالنصب والرفع أي معذرتهم {إلا أن قالوا} أي قولهم {والله ربِّنا} بالجر نعت والنصب نداء {ما كنا مشركين}.