The Prophet ﷺ entered the House and found in it an image of Ibrahim and an image of Maryam. He said, "As for them, they have heard that the angels do not enter a house in which there is an image. Here is Ibrahim depicted in an image, and what is he doing drawing lots with arrows?"
دخل النبي ﷺ البيت، فوجد فيه صورة إبراهيم وصورة مريم فقال: أما هم فقد سمعوا أن الملائكة لا تدخل بيتا فيه صورة، هذا إبراهيم مصور، فما له يستقسم.
Bukhari related it in the Book of Prophets (3351), from Yahya bin Sulayman, who said, Ibn Wahb narrated to me, who said, Amr informed me that Bukayr told him, on the authority of Kurayb, the freedman of Ibn Abbas, from Abdullah bin Abbas, who said, and then he related it.Istiqsam means seeking to know the portion that has been allotted and decreed for a person, out of what has not yet been allotted or decreed. When one of them intended to travel, or marry, or undertake some other important matter, he would cast the azlam, which were arrows used for divination. On one of them was written, "My Lord has commanded me," on another, "My Lord has forbidden me," and on another, nothing at all. If the one that came out read "commanded me," he proceeded with his affair. If it read "forbidden me," he held back. If the blank one came out, he would shuffle them again and cast another round, continuing until either the command or the prohibition came out. See al-Nihayah.