Impossible to know when it is not clear what would be the expected result…
However, I feel with you. Debugging RouterOS scripting is extremely tricky and it often behaves different from what you expect.
What I learned the hard way is to always break up things in small statements. The expression evaluator is very primitive.
However, I don’t know how to apply that to your problem.
But where is that transferred to $status? I don’t see that anywhere.
I think you need to:
:set $status [:interface pppoe…]
and then you can set the array variable to $status.
As I wrote earlier, the expression evaluator is very primitive.
Separate what you want to do in some steps.
First put the status in a variable, then put the variable value in the array.
But I don’t understand this “monitor” command and the relation to the $status variable, so I could be wrong.