I write a custom portfolio construction model, which has a dictionary that computes the weight of each target symbol, and return the normalized percentage for the targets

targets = []

for symbol, weight in self.symbol_weights.items():

targets.append(PortfolioTarget.percent(algorithm, symbol, weight * 0.98 / sum(self.symbol_weights.values())))

However, it has a lot of Backtest Handled Error: Order Error: ids: [112414], Insufficient buying power to complete orders (Value:[292394.1552]), Reason: Id: 112414, Initial Margin: 146220.972598494, Free Margin: 90860.1985049576491822.
Even times the 0.98 does not help. This does not make sense to me, do I miss some basic thing here? ImmediateExecutionModel is used following custom PCM