Well, Hamas is backed by Iran. They don’t act without clear orders from Iran. Also, other Iran militants were instructed to join Hamas in October 7th like Hezbollah and fighters from Syria. But somehow bailed out last minute.
And it is suspicious this attack happened days after Saudi Arabia brought 2 state solution back to the table.