Skip to content
This repository has been archived by the owner on Nov 24, 2018. It is now read-only.

"Error: Unknown command: protocol" when following example from serverless readme #387

Open
smoll opened this issue Jan 11, 2018 · 3 comments

Comments

@smoll
Copy link

smoll commented Jan 11, 2018

This is a Bug Report

Description

I followed the steps listed in https://github.com/graphcool/chromeless/tree/master/serverless with the following changes

custom:
  stage: dev
- debug: "*"
- awsIotHost: ${env:AWS_IOT_HOST}
+ debug: false
+ awsIotHost: myiotendp.iot.us-east-2.amazonaws.com
  chrome:
    functions:
      - run
@ -12,7 +12,7 @@ provider:
  name: aws
  runtime: nodejs6.10
  stage: ${self:custom.stage}
- region: eu-west-1
+ region: us-east-2
  environment:
    DEBUG: ${self:custom.debug}
    AWS_IOT_HOST: ${self:custom.awsIotHost}

However, when I ran the full example https://github.com/graphcool/chromeless/tree/master/serverless#full-example I get the following error:

$ node spike.js
Error: Unknown command: protocol

I also tried updating the chromeless dependency in https://github.com/graphcool/chromeless/blob/master/serverless/package.json#L15 to 1.4.0 but that didn't seem to change anything.

Additional Data

  • Chromeless Version you're using: 1.3.0 or 1.4.0
  • Operating System: macOS High Sierra 10.13
  • Stack Trace: not sure how to get a better stack trace, please advise
  • Error messages: when I add debug: true to the opts, I see one additional log statement
$ node spike.js
Connected to message broker.
Running remotely: {"type":"goto","url":"https://www.google.com"}
Error: Unknown command: protocol
@smoll
Copy link
Author

smoll commented Jan 11, 2018

Just discovered that downgrading my sls chromeless dependency down to 1.2.0 fixes this issue.

nsfmc added a commit to nsfmc/chromeless that referenced this issue Mar 13, 2018
This fixes the vague `Error: Unknown command: protocol` error (schickling#387).

pinned version found via a similar issue report:
adieuadieu/serverless-chrome#120
@asendia
Copy link

asendia commented Apr 11, 2018

I got the same error when following the readme tutorial using the latest npm version of chromeless.

  • nodejs version: v9.8.0
  • yarn version: 1.3.2
  • Chromeless version: 1.5.1
  • Operating System: macOS High Sierra 10.13.4
$ node google-remote.js
Connected to message broker.
Running remotely: {"type":"goto","url":"https://www.google.com"}
Error: Unknown command: protocol
Chromeless Proxy disconnected due to inactivity (no commands sent for 30 seconds).

@aaronromeo
Copy link

aaronromeo commented Apr 27, 2018

@asendia bumping the chromeless version as seen in PR #415 got me past this issue. (I had to then redeploy my remote browser)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants