code: def is_instance_running(self, instance_id):
          
          self._init_az_api()
          # Here, it's always better if we update the instance.
          vm = self._get_vm(instance_id, force_reload=True)
          # FIXME: should we rather check `vm.instance_view.statuses`
          # and search for `.code == "PowerState/running"`? or
          # `vm.instance_view.vm_agent.statuses` and search for `.code
          # == 'ProvisioningState/suceeded'`?
          return vm.provisioning_state == u'Succeeded'
docs: Check if the instance is up and running.
  
          :param str instance_id: instance identifier
  
          :return: bool - True if running, False otherwise