<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_next_revision(self, session_id, revision, delta):
 """ Determine the next revision number for a given session id, revision and delta. In case the client is up-to-date, this method will block until the next revision is available. :param int session_id: Session identifier :param int revision: Client revision number :param int delta: Client revision delta (old client version number) :return: Next revision number :rtype: int """


        session = self.sessions[session_id]
        session.state = State.connected

        if delta == revision:
            # Increment revision. Never decrement.
            session.revision = max(session.revision, revision)

            # Wait for next revision to become ready.
            self.next_revision_available.wait()

        return self.revision