Visiting a down hidden service that was recently up results in many hsdesc fetches
Run a hidden service, so it correctly establishes intro points and uploads its descriptor correctly. Then shut off the hidden service.
Then try to visit it, and watch your HS_DESC control events. You get something like:
1421275707.240294 [torctl-log] localhost:9051 650 HS_DESC REQUESTED yjiqkj6p7drpiwyq NO_AUTH $0011BD2485AD45D984EC4159C88FC066E5E3300E~CalyxInstitute14 776oil3sjfhbxkj6eewqu3mtzrsnesm2
1421275708.081418 [torctl-log] localhost:9051 650 HS_DESC RECEIVED yjiqkj6p7drpiwyq NO_AUTH $0011BD2485AD45D984EC4159C88FC066E5E3300E~CalyxInstitute14
1421275710.275964 [torctl-log] localhost:9051 650 HS_DESC REQUESTED yjiqkj6p7drpiwyq NO_AUTH $1D6A27AED313662E35F550B212335D4797DCCDF6~CriptoLabTORRelay3 dvcsya66ae4vvzekabjojyrgkdcttnfh
1421275711.550731 [torctl-log] localhost:9051 650 HS_DESC RECEIVED yjiqkj6p7drpiwyq NO_AUTH $1D6A27AED313662E35F550B212335D4797DCCDF6~CriptoLabTORRelay3
1421275713.156023 [torctl-log] localhost:9051 650 HS_DESC REQUESTED yjiqkj6p7drpiwyq NO_AUTH $002121252467538C9DA1BC2378997E64629814F6~metroholografix 776oil3sjfhbxkj6eewqu3mtzrsnesm2
1421275713.767901 [torctl-log] localhost:9051 650 HS_DESC RECEIVED yjiqkj6p7drpiwyq NO_AUTH $002121252467538C9DA1BC2378997E64629814F6~metroholografix
1421275716.254822 [torctl-log] localhost:9051 650 HS_DESC REQUESTED yjiqkj6p7drpiwyq NO_AUTH $000F18AC2CDAE4C710BA0898DC9E21E72E0117D8~TorNinurtaName 776oil3sjfhbxkj6eewqu3mtzrsnesm2
1421275717.405024 [torctl-log] localhost:9051 650 HS_DESC RECEIVED yjiqkj6p7drpiwyq NO_AUTH $000F18AC2CDAE4C710BA0898DC9E21E72E0117D8~TorNinurtaName
In this case I fetched the hsdesc four times for the service. According to the original design, I was supposed to fetch it twice: that is, I fetch it once, try all the intro points, once they've all failed, I fetch it once more just to see if it changed, and if it didn't change, I should stop and fail right then.
So: is there a bug where we continue rather than failing? Or is the descriptor that I receive different in each case? What's going on?