Shaykh Abū Muḥammad Zayd ibn Muḥammad ibn Hādī al-Madkhalī (d. 1435 AH / 2014 CE) ؒ answered the following question:
Question
ما ضابط النقل عن المخالف، وهل يعتبر النقل عنه موافقة له في بدعته فيلحق به؟ وبين لنا أحوال المخالفين ومتى يصح النقل عنهم ومتى يمتنع؟
“What governs transmitting from someone whose views differ? Does transmitting from him count as agreeing with his innovation, so that the transmitter is treated like him? Explain the different situations of dissenters, when transmitting from them is permissible and when it is impermissible.”
Answer
He replied:
The dissenter may be from the people of Sunnah in every respect, differing from others over matters in which differences are permissible. He is one of the qualified scholars of independent judgement (ijtihād) whose disagreement is accepted by the scholars. In such a case, the matters over which he differs from other scholars are examined, as are everyone’s proofs. The statement of whoever bases his position on evidence must then be accepted.
If the dissenter is from the people of desires and innovation, many of the Pious Predecessors (Salaf) established that knowledge is not taken from callers to innovation and those who promote them, and their narrations are not accepted because of their sinful conduct and loss of probity (ʿadālah). Their testimony and reports are likewise not accepted. Marriage is not contracted with them, nor chosen to lead people in prayer.
Someone who transmits from them knowing that they are people of innovation and misguidance promotes them and is treated like them, with no honour accorded to him.
As for those who conceal their own innovations, their evil is against themselves as long as they conceal those innovations from people. They are treated as Muslims until their situation becomes known. As the poet said:
ومهما تكن عند امرئ من خليقة وإن خالها تخفى على الناس تعلم.
“Whatever trait a person possesses, even if he imagines it hidden from people, it will become known.” (Verse quoted by Zayd al-Madkhalī in the answer.)
The conditions for accepting their narrations are that they do not narrate what strengthens their innovations, and that they have not been accused of lying by recognised scholars of criticism and commendation (al-jarḥ wa-t-taʿdīl).
References
Al-Madkhalī, Zayd ibn Muḥammad ibn Hādī, Al-Ajwibah al-Athariyyah ʿan al-Masāʾil al-Manhajiyyah: Khamsūn Suʾālan wa-Jawāban, question 3, p. 19, verified in the public book scan, PDF page 21.