Bug with safe_z_home?

There’s some related discussion here: safe_z_home: Add hooks to safe_z_home by ibash · Pull Request #5947 · Klipper3d/klipper · GitHub

I think the behavior you’re describing is the intended behavior. If Z isn’t homed, the firmware has no way of knowing where the toolhead is, including whether the nozzle is at or below the level of the bed. So with safe Z home enabled, it raises the Z before performing a homing move to make sure the nozzle doesn’t hit or scrape the bed.

If your toolhead is likely to end up at max Z travel, you could consider installing a max limit switch so Klipper will know that the toolhead (or in your case, the bed) is at max Z travel and will not continue to move it. You could also change the behavior of the command by overriding the homing gcode as suggested in the link above.