I was wondering is this a bug or is it something that legitimately happens?
Legitimately happens.
As other CMDRs pretty much well explained that I won't repeat it. But I'd like to point out one thing - plot your route as a last thing you do before journey. many CMDRs fell victim of "target exceeding jump range" error message.
As you already know, your jump range comes from your current mass. Jumping uses fuel and lowering your mass. Refuelling add range and mass. Tho these differences aren't that big compared to overall ship mass, they have significant impact on your ability to jump or not.
If you plot your route and then load up cargo you may find that your ship is unable to execute that plotted jump.
If you plot your route and then refuel, same as above.
If you plotted long route and started jumping, after relog game recalculates your target taking under consideration your current mass. Hence the differences. If you want to be sure what is your real jump range, look at "laden/min range". Max range is calculated with empty cargo and fuel barley enough to cover that jump.
Interesting note - some CMDRs use that feature for their advantage to ensure highest jump range possible. Usually explorers get the best and biggest fuel scoop to make refuelling the fastest as possible. Now, fast scooping adds lots of fuel fast, which in the end results in increased mass. More mass, shorter range. So some CMDRs install slow scoops to keep track how much they refuel. This way they can scoop just enough fuel to cover their extreme range jump which would be impossible with full tank.