Interesting question, I found myself in exactly that position a couple of months ago (more on that below).
First, I found an FAA clarification on this, which is a legal interpretation from 2007 and it partly answers your question. The questioner asked the FAA three questions about logging flight time (in a helicopter in this case); questions 1 and 2 are very close to yours. Question 1 is:
- May a pilot log as "flight time" to qualify for a certificate or rating under 14 CFR Part 61, or for purposes of qualifying under 14
CFR 135.243(b)(2), that time accrued in a helicopter when the aircraft
is sitting on the ground with the engine running and rotor blades
turning, but the aircraft has not moved from its parking place and
flight has not yet commenced?
Question 2 is almost the same, but it asks about logging time after parking but when the engine is still running. I know that this is slightly different from your scenario, because you're asking about logging time after the aircraft has moved from its parking place, but the FAA response says the following:
[...] flight time [...] commences the moment that [the aircraft] moves under its
own power away from its parking place for the purpose of flight -
whether departure is commenced by lifting off or taxiing.
So according to that interpretation, you can start logging time as soon as you start taxiing but it goes on to say that you cannot log time after the aircraft lands. That means that your question is still a grey area, and if you want a definite answer then you should probably ask the FAA for your own interpretation. But my personal take is that the FAA is only concerned about people trying to cheat the system by sitting with the engine running, and for practical purposes you can log time as soon as you start taxiing.
And turning to the real-world situation, I don't think it matters at all. Every instructor and pilot I have ever met simply logs whatever time the Hobbs says, regardless of what happens in between. The FAA has absolutely no way to accurately verify what you're logging and there's a large degree of trust in the system.
In my case, the AI gyro didn't spin up and although I didn't need that instrument (the planned flight was VFR in CAVU conditions) I elected not to fly anyway: better safe than sorry, and if one thing is broken it may be a symptom of a bigger problem. I taxied back with 0.2 on the Hobbs: I didn't log it (and the FBO didn't charge me). My thinking was simply that I didn't really 'fly' and 0.2 is irrelevant for all practical purposes. I'm sure that someone somewhere has found themselves 0.1 short of what they needed for a rating and really wished that they had that extra time, but if you ever find yourself in that position, it's no big deal to do a couple of turns in the pattern.
Note: there is another FAA interpretation on this, but it looks like it only applies to part 121. They said yes, you can log it, but that's based on the assumption that after you taxi back to the gate, the airline finds a second aircraft and you fly that one to the original destination. They didn't say what happens if the flight is cancelled completely.