The city's publicity office admitted the faux pas on its Sina Weibo social media page, noting that a sudden change in wind direction had blown the tear gas from the edge of town towards much more populated parts, Global Times reported.
Shanghai Radio and Television's Kankan News reportedly released a video showing residents crowded in the city hospital, seeking treatment.
"We inhaled very pungent gas, and my nose and throat itched for days, but no one bothered to tell us what happened. Not too many believe it was just because of a military drill," a local resident said, Asia Times reported.
City security officials reassured residents, however, that any discomfort they experienced would wear off after leaving the affected area, but to still go to the hospital if they feel bad.
"People can use water to wash their eyes and noses, and rinse their mouth to eliminate the discomfort. They normally recover in five to 15 minutes," military expert and TV commentator Song Zhongping told Global Times Sunday.
Last month, the French government accidentally tear gassed riders in the world's most famous bicycle race, the Tour de France, sending bikers to the side of the road to wash their faces.
Vice reported that on July 24, French police trying to disperse protesting farmers who had hurled bales of hay onto the racing path deployed tear gas, which the bikers soon encountered. The race was delayed for more than 15 minutes as riders rinsed out their eyes with water bottles and eye drops.