code: def remaining(self):
          
          if self.depth == 0:
              return _STREAM_REMAINING
          return self.limit - self.queue.position
docs: Determines how many bytes are remaining in the current context.