Also worth noting that the court appears to only be saying that he can't be locked up because the government likely doesn't need the evidence to convict him. That is the stipulation under which he is getting out of jail for contempt. If the government did actually need to compel that evidence to make their case, they would be able to hold him idefinitely. Or else at least this ruling doesn't say otherwise.