The rabbis did not approve that the Hasmonean dynasty, issued from the Maccabean revolt, assumed the kingship of Israel, instead of giving it back to David’s family. The Torah says the kingship belongs only to David’s family:
The staff shall not depart from Judah [David’s tribe], nor the scepter from between his feet, until Shiloh arrives, and to him shall the obedience of the people be. [Gen. 49:10]
The Ramban writes ties the death and disappearance of Hasmoneans to their taking the throne:
In my opinion, the kings who reigned over Israel who came from tribes other than Judah, after David, were violating the expressed wishes of their forefather Jacob and were usurping Judah’s rightful inheritance… And this was the punishment of the Hasmoneans who ruled as kings during the Second Temple [period]. [Now,] they were [certainly] righteous people, and if not for them, Torah and mitzvot would have been forgotten by the Jewish People. Even so, they were punished with great retribution: … All their descendants were killed off because of this sin. [Ramban on Gen. 49:10]