The common side effects of lactulose are: bloating, burping, stomach rumbling/pain, nausea, and cramps. It is advisable to see a doctor if other unlikely side effects occur eg diarrhea, vomiting, muscle cramps/weakness, irregular heartbeat, mental/mood changes, seizures. I would suggest seeing a doctor if you suspect that it is causing lack of sleep.
PS. Thanks for keeping this platform active by posting numerous questions that are of great importance and educative. Keep them coming.