The 21-year-old Glasgow Warriors forward was Scotland's star performer in the 34-21 loss to France last weekend after a barnstorming display in attack and defence.
Gray was set to win his eighth cap against Wales in an unchanged starting XV named by Andy Robinson on Wednesday, but now the head coach could be forced to re-jig his back row after the lock missed the team photo and final training session before the crucial Six Nations encounter with a stomach bug.
Nathan Hines may switch from blindside flanker to his more usual second-row spot alongside captain Alastair Kellock, with Richie Vernon promoted from the bench to number eight and Kelly Brown moving into the number six jersey.
Edinburgh lock Scott MacLeod is on standby and could be promoted to the bench.
Scotland head coach Andy Robinson said: "As a precaution we have drafted Edinburgh lock Scott MacLeod to our squad and he trained with us today, having also worked with us earlier in the week.
"Scott gave a quality performance in Scotland A's victory over Ireland A at Netherdale last month and we would have no qualms if he is required tomorrow."