"Then the chiefs of Edom were dismayed" (Exodus 15:15). If you should say that they were coming to inherit their land — has it not already been said, "You are passing through the border of your brothers, the children of Esau, and so forth, and you shall be very careful, do not provoke them" (Deuteronomy 2:4–5)? Then what does Scripture teach by saying "Then the chiefs of Edom were dismayed"? On account of grief.
The Chiefs of Edom Dismayed Though Israel Spared Their Land
Yalkut Shimoni on Torah 251:11
(שמות טו טו) אָז נִבְהֲלוּ אַלּוּפֵי אֱדוֹם. אִם תֹּאמַר שֶׁהֵן בָּאִין לִירַשׁ אֶת אַרְצָם, הֲלֹא כְּבָר נֶאֱמַר (דברים ב, ד ה) "אַתֶּם עֹבְרִים בִּגְבוּל אֲחֵיכֶם בְּנֵי עֵשָׂו וְגוֹ' וְנִשְׁמַרְתֶּם מְאֹד אַל תִּתְגָּרוּ בָם", הָא מַה תַּלְמוּד לוֹמַר אָז נִבְהֲלוּ אַלּוּפִי אֱדוֹם, מִפְּנֵי אֲנִינוּת.