Invalid JSON error on builder-dot-lighthouse-ci
osartun opened this issue · 4 comments
I'm currently implementing Lighthouse in our CI. However, it's a bit more complicated as we're deploying via Netlify and having a dynamically generated URL for each PR.
That's why I'm manually sending a POST request to https://lighthouse-ci.appspot.com/run_on_chrome
This works more or less fine. However, I just ran the first request from Travis and getting an error in the list of checks on the GitHub PR.
Error. invalid json response body at https://builder-dot-lighthouse-ci.appspot.com/ci reason: Unexpected token < in JSON at position 0
As I'm not making any requests to https://builder-dot-lighthouse-ci.appspot.com/ci I guess this is triggered by lighthouse-ci.appspot.com
That's why I think that there's something not working at your end
EDIT: The second time it ran successfully. So, it doesn't seem to be a general issue.
Sometimes Lighthouse comes back with errors and the service doesn't do a good job of cleaning that up. Are you still seeing this?
How of curiosity, can you share the site you're testing so I can look through the logs?
The page I've been running the test on were PR deployments on Netlify: https://deploy-preview-26--publizist-frontend.netlify.com/meal-plan-app/
However, the tests only ran in the PR where I tested the Lighthouse integration and I ended up closing the PR without merging it because of a few other issues. So, we're not running any further tests with Lighthouse CI which is why I can't say whether these issues are still appearing or not.
Looks like things are working again. I can't repro on that site. It's possible there was a server / network issue when you ran it the first time.
Hi @ebidel
I have recently had the same or a similar issue running lh-bot, i was hoping you might be able to help me troubleshoot it.
This is the error:
(I have had the same error occur on 3 different PRs, and have not yet been able to get the bot to comment in the pr)
"Error from CI backend. invalid json response body at https://builder-dot-lighthouse-ci.appspot.com/ci reason: Unexpected token U in JSON at position 0"
This is the PR in staging: https://website-ssr-pr-14.herokuapp.com/
Travis yaml:
sudo: false
language: node_js
node_js:
- '10'
install: - node -v
before_script: - yarn
cache:
directories:- node_modules
yarn: true
git:
depth: 3
script: - yarn build
after_success: - sleep 4m
- yarn run lhbot https://website-ssr-pr-$TRAVIS_PULL_REQUEST.herokuapp.com/
- node_modules
Please let me know if you need any other information from me im really keen to get this working 😃