{"action":"created","issue":{"url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions/issues/110","repository_url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions","labels_url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions/issues/110/labels{/name}","comments_url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions/issues/110/comments","events_url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions/issues/110/events","html_url":"https://github.com/serverless/serverless-google-cloudfunctions/issues/110","id":342503290,"node_id":"MDU6SXNzdWUzNDI1MDMyOTA=","number":110,"title":"  Serverless plugin \"serverless-google-cloudfunctions\" initialization errored: Unexpected token )","user":{"login":"knitterb","id":166302,"node_id":"MDQ6VXNlcjE2NjMwMg==","avatar_url":"https://avatars1.githubusercontent.com/u/166302?v=4","gravatar_id":"","url":"https://api.github.com/users/knitterb","html_url":"https://github.com/knitterb","followers_url":"https://api.github.com/users/knitterb/followers","following_url":"https://api.github.com/users/knitterb/following{/other_user}","gists_url":"https://api.github.com/users/knitterb/gists{/gist_id}","starred_url":"https://api.github.com/users/knitterb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knitterb/subscriptions","organizations_url":"https://api.github.com/users/knitterb/orgs","repos_url":"https://api.github.com/users/knitterb/repos","events_url":"https://api.github.com/users/knitterb/events{/privacy}","received_events_url":"https://api.github.com/users/knitterb/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":12,"created_at":"2018-07-18T21:45:10Z","updated_at":"2018-10-30T01:30:13Z","closed_at":null,"author_association":"NONE","body":"When doing a fresh install of the plugins (`npm install`) I get the error in the title when issuing the `serverless help` command.  Further debugging profiles the following:\r\n\r\n```\r\nSyntaxError: Unexpected token )\r\nnode_modules/serverless-google-cloudfunctions/package/lib/compileFunctions.js:43\r\n      );\r\n      ^\r\n```\r\n\r\nI took a look in the file and there appears to be an extra comma that is not tolerated:\r\n\r\n```\r\n40      funcTemplate.properties.labels = _.assign({},\r\n41        _.get(this, 'serverless.service.provider.labels') || {},\r\n42        _.get(funcObject, 'labels') || {},\r\n43      );\r\n44\r\n45      const eventType = Object.keys(funcObject.events[0])[0];\r\n```\r\n\r\nThe comma at the end of line 42, when removed, let's everything function as it should.\r\n\r\n```\r\n  Your Environment Information -----------------------------\r\n     OS:                     darwin\r\n     Node Version:           6.11.5\r\n     Serverless Version:     1.28.0\r\n```\r\n\r\nLet me know what else I can provide to help!"},"comment":{"url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions/issues/comments/434139385","html_url":"https://github.com/serverless/serverless-google-cloudfunctions/issues/110#issuecomment-434139385","issue_url":"https://api.github.com/repos/serverless/serverless-google-cloudfunctions/issues/110","id":434139385,"node_id":"MDEyOklzc3VlQ29tbWVudDQzNDEzOTM4NQ==","user":{"login":"knitterb","id":166302,"node_id":"MDQ6VXNlcjE2NjMwMg==","avatar_url":"https://avatars1.githubusercontent.com/u/166302?v=4","gravatar_id":"","url":"https://api.github.com/users/knitterb","html_url":"https://github.com/knitterb","followers_url":"https://api.github.com/users/knitterb/followers","following_url":"https://api.github.com/users/knitterb/following{/other_user}","gists_url":"https://api.github.com/users/knitterb/gists{/gist_id}","starred_url":"https://api.github.com/users/knitterb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knitterb/subscriptions","organizations_url":"https://api.github.com/users/knitterb/orgs","repos_url":"https://api.github.com/users/knitterb/repos","events_url":"https://api.github.com/users/knitterb/events{/privacy}","received_events_url":"https://api.github.com/users/knitterb/received_events","type":"User","site_admin":false},"created_at":"2018-10-30T01:30:13Z","updated_at":"2018-10-30T01:30:13Z","author_association":"NONE","body":"Thanks for that lint fix!\n\n--\n-bk\n\n\n\nOn Mon, Oct 29, 2018 at 3:05 PM Erik Erikson <notifications@github.com>\nwrote:\n\n> This snippet is from our eslintrc.yml:\n>\n>   # Note: this is to prevent compile errors for Node < 8.x. When Node 6 is\n>   #   deprecated, this comma-dangle rule exception can be removed.\n>   comma-dangle:\n>     - error\n>     - arrays: always-multiline\n>       objects: always-multiline\n>       imports: ignore\n>       exports: ignore\n>       functions: never\n>\n> Probably a more targeted approach would be to use the comment at the end\n> of the line:\n>\n> // eslint-disable-line comma-dangle\n>\n> —\n> You are receiving this because you were mentioned.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/serverless/serverless-google-cloudfunctions/issues/110#issuecomment-434098391>,\n> or mute the thread\n> <https://github.com/notifications/unsubscribe-auth/AAKJnr0E1pvDfjKNODGELkprxlWaEN9Jks5up3upgaJpZM4VVa9W>\n> .\n>\n"}}
{"actor":{"display_login":"knitterb"}}