I dont know which Buy and Sell price I am getting
Neither do we.
As you can see I used price = self.data.close instead self.data.close
I guess you already realized that's wrong.
How could I go live, if I tested my strategies with self.data.close ?
If could means you already did ... I hope you had luck.
If could means you plan to ... I would do proper backtesting.
Is buy price, "buy at closing price of next bar" ?
Sell = "selling at closing price of next bar"?
Your orders are
Limit and your data is unknown ... my guess is as good as any other as to what you got.