Q. In certain cities, brushing close to people, even pushing, takes place at simchas, by talks, in shules. There is not an apology, but in any case it is disturbing and hurts frailer people. Is a Yid oiver by doing this, and what?
A. Rambam (Chovel Umazik 5:1) rules that one who strikes intentionally another transgresses on the Biblical prohibition (Devorim 25:3) "he shall not exceed (flogging)" The Shulchan Oruch (CM 420:1) states that one who just lifts his hands to hit another person is called a Rosho or evil. However, there is an established tradition to exempt one that harms another person or his property, unintentionally at the time he is complying with a Mitzvah, such as attending a wedding, Simchas Torah or Purim (Rashi and Tos. Suka 45a – Remo O.H. 695:2 and 696:8 – Mishna Berura ibid. – Remo C.M. 378:9 – Trumas Hadeshen 1: 110 et. al.). Two reasons are given for this exemption. It was our Sages intention that a person should rejoice in the fulfillment of a Mitzva with all his hearth and devotion, without being limited by the fear of unintentionally damaging his friend. Others argue that it is based on mutual forgiveness and reciprocated exoneration that benefits all. The difference would be if this applies even when the victim was not partaking in the Mitzva or Simcha. (Mishpetei Hatorah p.95).
Horav Shlomo Miller Shlit'a added, that although the perpetrator may be exempt from paying compensation, it does not exempt him from asking mechila and saying I'm sorry.
Rabbi A. Bartfeld as revised by Horav Shlomo Miller Shlit"a