BK conditions are not satisfied:no stable equilibrium

Hello, everyone.
I am trying to run a model of small open economy with financial frictions.
When Private budget constraint equation set:

C_h+R(-1)*b(-1)/Pi+B_P_star(-1)*REER/Pi_star/betta=Y+W*N-mc*Y+b+B_P_star;
The dynare 5.2 reports an erro:
image

The MODEL_DIAGNOSTICS: No obvious problems with this mod-file were detected.

I check the timing of variables and the equations, I think all things are right.

But if I change the Private budget constraint equation,(swap the position of the variable B_P_star, the model can run successfully:

C_h+R(-1)*b(-1)/Pi+1/R*B_P_star=Y+W*N-mc*Y+b+B_P_star(-1)*REER/Pi_star/betta;

But as we all konw, the budget constraint is wrong.

I would like to know, where is wrong with this model?

The probably means that B_P_star is explosive in your model and you “fixed” that by altering the timing. Obviously that is not a proper fix.

Thanks for your reply, Prof pfeifer.
How can I correct the model for this situation?

You need to find out why debt is not stabilized.

Thanks for your prompt reply, Prof Pfeifer.
I’ll try it right away.
Thanks!