Lookit what I found. According to my research, this beast is called an Ichneumonid wasp. While large and slightly horrific looking, she has no actual stinger. She is using her ovipositor (the long stringy things coming out of her butt) to lay her eggs in the tree.
Incidentally, this particular tree is riddled with emerald ash borer, an invasive species of beetle, and is marked for elimination by the city of Ottawa. So her larvae better grow up fast and bust a move or they’re all going to the wood chipper.