Welcome to the Forums G,
Are you using custom roles by any chance, ran into this issue just today.
Authentication in scripts? (no script data in pages table for custom roles) - PowerShell Universal - Ironman Software Forums