Thanks Jujuba.
This solved the problem for me.
In my case it was re-logging into the apple developer account.
Topic:
App & System Services
SubTopic:
Automation & Scripting
Tags: