Norms in terms of employment vary a lot by industry. It's not uncommon to have people moving around several times in a row every 12-24 months in start-up land, while the average in large/established companies is probably closer to 2-4 years. You'll have to judge what that is for you.
For the first 10 years or so, it's not a problem at all to try new things. We are all learning about ourselves and what we want out of a career just as much as we are developing professionally.
You did make a relationship boo-boo by continuing to look for work after accepting a raise. Are you still unhappy? By taking your next offer of 20k+ raise, it seems you are a) severely underpaid, or b) lucky with the new company who's desperate for someone with your skills.
Since you continued to look after you took the raise, it seems you are unhappy or dissatisfied. In my view, rightfully so if you are 40%+ underpaid. It's unlikely they will give you another raise to stay, so I would do what you can do avoid burning a bridge (3-4 week notice, wrap up and document all the status on your projects and/or train your replacement, etc.).
To give a personal example, I left my first job (1) after ~18 months to jump to another company doing the same thing with new clients for a 10% raise (company #2). During that interview period, I received another offer (company #3), but declined since it wasn't what I wanted and started working at #2. A few months later, #3 contacted me again with a better offer which was substantially more than what I was making at #2 (and probably what I would expect to make if I stayed for another 3 years). It was too much to pass up, and also a good career opportunity, so I took it. That short stint is not ideal, but I advanced my career (skills/experience/etc.) and make a LOT more today than I would have if I stayed at either #1 or #2. If a future employer asks why I left, I think they'll understand leaving for a 30%+ raise. If they don't, then I'll just have to find someone else who will. Certainly, some people will be put off by that, but others won't care. Overall, better for my career. Nothing is perfect, so you have to take the good (more money) with the bad (mark of leaving shortly).
Fortunately, for you, you're still at the same employer, so it will only be one company change for a big raise. I'd take it, if I were you.