Could this single event have butterflied away WWI if European political and military leaders realised they wouldn't be able to score a quick, offensive victory?
Nnnnot entirely, IMHO.
Though more weight of defensiv doctrines on the Entente side might have helped to ... "localize" the war, given Sarajevo and the July-crisis still happens as IOTL.
For the russians : IOTL they invested heavily in fortress guns, several times what they invested in field guns (it's somewhere in Norman Stone "The Eastern Front", just don't have the time right now to look up the exact numbers).
And it put quite a strain on their military budget. A strain, that kept them to quite some away from upgrading the building substance of their fortresses. Only Ossowiezc and NovoGeorgievsk bot some upgrade on their buildings, not Ostrolenka, Lomza and Pultusk and esp. not Ivangorod (made mainly from bricks).
Even if they would have found the money to improve their existing fortresses, there most likely wouldn't have been enough for new ones, esp. along the Vistula, not to speak of the galizian border
And the germans : Well, WHEN France started to build its fortresses, Moltke the Elder advised, asked about it :
"Don't build fortresses, build railways."
Therefore I tend to the possibility, that the offensive option - as laid out by
@Stenz - would be kept on the list. IF Colmar von der Goltz might follow at some point, there might be a strong voice for fortresses AND railways.

Though he still was a advocate of strategic offense, even (or esp. ?) out of tactical defense.
However. With france building the mentioned fortresses, its own hyper-offensiveness might dwindle enough for ... well not doing too much in favor of the russians.
Another question would be how Hötzendorf might develop under a prevailance of defensive doctrine. Would he still become CinC of A-H ?