Closed micahyoung closed 8 years ago
It appears that the configuration of the CircleCI endpoint is incorrect. I ended up configuring the project to use webhooks (which appears to be working), but it would be nice for the polling to work.
It seems that Project Monitor is attempting to use /api/v1/projects/<PROJECT NAME>.json?api_key=<API KEY>
It actually needs to use /api/v1/project/<ORGANIZATION>/<PROJECT NAME>?circle-token=<API KEY>
This means that it also needs to collect "organization", and no longer needs to collect "username".
I might try and make a pull request for this if I can.
For legacy reasons, our project was configured to use CircleCI polling instead of webhooks. Our builds have been silently failing for a few weeks and when we looked into it, it seems this commit likely introduced the regression as it changes the CircleCI format to depend only on the webhooks-style:
https://github.com/pivotal/projectmonitor/commit/ed3283246ece4cf4ac7494012003a5c996c00288
Here is our stacktrace from /projects/PROJECT_ID/payload_log_entries:
The String into Integer is because the result from https://circleci.com/api/v1/project/USERNAME/PROJECT returns an array of hashes, not a hash [{}]