In some sense, you don’t solve it. You are correct to perceive you are at a crossroads. And the hard part is knowing that either choice may foreclose some possibilities on the other path.
There’s still plenty of time to change gears, or move back and forth between the two choices. There are also other paths; see my comment above.
Important part is to not ignore the discomfort. I suggest reading Charity Majors’ blog posts around leadership vs engineering roles.