text: Hello,
  I am trying to make this ST3 plug in work in ST2 and I have a problem with the method replace of sublime.View.
  I have a function that must just replace the content of a view like this:
  def replaceViewWith (edit, view, text):
  region = sublime.Region(0, view.size ())
  view.replace(edit, region, text)
  view.replace seem to do nothing to the view, the content stays the same.
  I also tried to use erase and then insert like this:
  def replaceViewWith (edit, view, text):
  region = sublime.Region(0, view.size ())
  view.erase(edit, region)
  view.insert(edit, 0, text)
  But the same issue, erase does not change anything to the view, and insert returns 0
  Can any one tell me what is wrong?
  thanks,Ayoub.
  def updateViews (self, edit, input_view, input, output):
  replaceViewWith (edit, input_view, input)
  replaceViewWith (edit, self.view, output)
  sublimetext.com/docs/3/api_reference.html:
  well as I said I am using sublime text 2, so the 2nd version for the API.
  Edit: in your example you are editing two views input_view and self.view I want to edit just one.In my code I am in the same view and trying to edit it.
  I tried also to use view.begin_edit() and view.finish_edit() but without success
  Have you made sure the correct text is being passed to the function? Perhaps something got messed up while you were refactoring other parts of the code.
  Yeah I checked that it is the correct text. It is the view that is not edited.