ERROR: java.lang.IllegalArgumentException out of range when updating a file

Hi All.
Using Azure Devops pipelines with repos in Bitbucket, we’re getting the following error when making a change to a file in the project.

It occurs in two instances:

  1. When we make an addition to a file in the project, thus increasing the number of lines for the file, the error shows this:
    2.*##[error]java.lang.IllegalArgumentException: Line 31 is out of range for file <>. File has 30 lines.**
  2. When we make an amendment to a file in the project, retaining the same number of lines but changing the code in the file, we get this error:
    4.*##[error]java.lang.IllegalArgumentException: 34 is not a valid line offset for pointer. File <> has 33 character(s) at line 17**

Has anyone else experienced this? Thank you!

Hi, I don’t know if it’s actually related to your error, but we’re experiencing an apparently no-reason Java errror as well, (see here).
It happened out of the blue this morning over many pipelines. We don’t know why this is happening.