They worshipped the golden calf early in their exile from Egypt [Ex. 32:7-35].
In Shittim the people played the harlot with the daughters of Moab and worshipped Moab’s gods [Num.25:1-18].
They refused to go into the land after the spies came back with a terrifying report. For their unbelief, they were kept out of the land for 40 years, a year for every day they had been spying [Num 14:1-38].
Israel continued in idolatry, constantly going after Ashtaroth and Baal [Judg 2:11, 10:13; I Sam 7:3-4, 12:10; I King 11:5, 33 to name just a few]. God remembered their disobedience and judged them with sudden terror which took them into Babylon as conquered slaves. The captivity lasted for 70 years [Jer 25:11,12; 29:10].
Judah played the harlot, for they had all manner of pagan worship in the temple itself. [Ezek 8]
The children of Israel failed to keep the entire covenant, specifically Jubilees, upon returning to the land.
And if in spite of this you will not hearken to me, then I will chastise you again sevenfold for your sins, Lev. 26:18
FYI: Seven is symbolic of completion and ritual cleansing for His people. [Lev 14:1-8, 15:13-24, 16:15-19, Ezek 39:11-16]
Israel was to learn that being ruled by God is much better than being ruled by men. Every believer should understand that God is a jealous God, and will not tolerate idolatry from those who covenant with Him.
Moses’ final message to Israel found in Deuteronomy 29:16 – 30:10 warns that they will be driven from the land until a final restoration. The sword, pestilence, and famine would follow them and ultimately Israel would be scattered among the nations, leaving the land to rest in desolation for the Sabbaths not kept.
“Then the land shall enjoy its sabbaths as long as it lies desolate, while you are in your enemies’ land; then the land shall rest, and enjoy its sabbaths.” Lev. 26:34