ansible script module fails in ansible 2.3.1

Hello,

I am running powershell script using script module on ansible core 2.3.1.0. But it works on older version ansible core 2.2. Is this a bug in ansible 2.3 and higher version, any fixes or any workarounds would be appreciated.