I can suggest about the first it must be "he made a big mistake by doing that"
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.
jemaasjr
By usually means before a due date, "Finish by Friday," This I buy. or it names the doer of an action as it does here. I have to ponder on this one...
If you say "He wasted no time by kissing her," you would be saying he avoided waisting time by kissing her (he was the doer of the action). Your understanding of in