I went out with the Messenger of Allah ﷺ from Madinah to Makkah, and he continued to shorten the prayer until he returned, even though he stayed there for ten days.
أخبرنا قتيبة قال حدثنا أبو عوانة عن يحيى بن أبي إسحق
خرجت مع رسول الله ﷺ من المدينة إلى مكة فلم يزل يقصر حتى رجع فأقام بها عشرا
No references are available.
Muslim narrated it, no. 15/693, from Qutayba (see the previous hadith), and Bukhari, in the chapter on shortening the prayer, etc., no. 1081, from the hadith of Yahya bin Abu Ishaq with this wording, and it is also found in the chapter on what has been said about shortening the prayer in Al-Kubra, no. 1896.