fix os v2_replacement requiring pattern to have as many groups