code: def release(self, session):
          
          if session.state != SessionState.locked:
              return
          with self._lock():
              return self._power_down(session)
docs: Release a machine session resource.