"Who led you through the wilderness." He hinted to them that they were destined to rebel against the Omnipresent, and to worship idolatry in exchange for the goodness that He lavished upon them, as it is said, "And I multiplied silver for her, and gold they made for Baal" (Hosea 2:10). And on account of this He was destined to exile them among the four kingdoms. "A fiery serpent and scorpion and thirst where there is no water" — this is the guilty kingdom, who are thirsty for the Holy Spirit and for words of Torah, as it is said, "Not a hunger for bread, nor a thirst for water, but of hearing the words of the LORD" (Amos 8:11). But in the time to come, "For I will pour water upon the thirsty" (Isaiah 44:3).
The Wilderness Serpents as a Warning of Israel's Idolatry and Exile
Midrash Aggadah, Deuteronomy 8:15
המוליכך במדבר. רמז להם שעתידים למרוד במקום, ולעבוד ע"ז חלף הטובה שהשפיע להם, כמו שנאמר וכסף הרביתי (להם) [לה] וזהב עשו לבעל (הושע ב י). והוא בעבור כך עתיד להגלותם בארבעה מלכיות: נחש שרף ועקרב וצמאון אשר אין מים. זו מלכות חייבת שהם צמאים מרוח הקדש ומדברי תורה. שנאמר לא רעב ללחם ולא צמא למים וגו' (עמוס ח יא), אבל לעתיד לבוא כי אצק מים על צמא (ישעי' מד ג):