Found the answer! I will leave it here for the future.
Indeed, it was my mistake in the code. The problem was that some TextSpan that I was using (not related to the Box engraver) was not being correctly formatted, leaving some open TextSpan's. Once I correct them, each box went to its local scope.
Best, Juan
