質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Hubot

HubotはGitHub社が開発したチャットbotのフレームワークです。

Heroku

HerokuはHeroku社が開発と運営を行っているPaaSの名称です。RubyやNode.js、Python、そしてJVMベース(Java、Scala、Clojureなど)の複数のプログラミング言語をサポートしている。

GitHub

GitHubは、Gitバージョン管理システムを利用したソフトウェア開発向けの共有ウェブサービスです。GitHub商用プランおよびオープンソースプロジェクト向けの無料アカウントを提供しています。

Slack

Slackは、Tiny Speckという企業からリリースされたコミュニケーションツールです。GoogleDriveやGitHubなど、さまざまな外部サービスと連携することができます。

Q&A

解決済

1回答

908閲覧

Slackでhubotを働かせたいが、git push heroku masterでエラー分がでる。

chalinca

総合スコア10

Hubot

HubotはGitHub社が開発したチャットbotのフレームワークです。

Heroku

HerokuはHeroku社が開発と運営を行っているPaaSの名称です。RubyやNode.js、Python、そしてJVMベース(Java、Scala、Clojureなど)の複数のプログラミング言語をサポートしている。

GitHub

GitHubは、Gitバージョン管理システムを利用したソフトウェア開発向けの共有ウェブサービスです。GitHub商用プランおよびオープンソースプロジェクト向けの無料アカウントを提供しています。

Slack

Slackは、Tiny Speckという企業からリリースされたコミュニケーションツールです。GoogleDriveやGitHubなど、さまざまな外部サービスと連携することができます。

0グッド

0クリップ

投稿2018/11/03 17:46

前提・実現したいこと

Slackでhubotを働かせたいが、git push heroku masterで以下のエラー文がでる。
(プログラミング歴1週間)

発生している問題・エラーメッセージ

! [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to 'https://git.heroku.com/frozen-brushlands-*****.git'

該当のソースコード

user@LAPTOP-7JFGU5LM MINGW64 ~ $ cd myhubot user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot $ yo hubot _____________________________ / \ //\ | Extracting input for | ////\ _____ | self-replication process | //////\ /_____\ \ / ======= |[^_/\_]| /---------------------------- | | _|___@@__|__ +===+/ /// \_\ | |_\ /// HUBOT/\ |___/// / \ \ / +---+ \____/ | | | //| +===+ // |xx| ? Owner user <user@gmail.com> ? Bot name userhubot ? Description A simple helpful robot for your Company ? Bot adapter slack create bin\hubot create bin\hubot.cmd create Procfile create README.md create external-scripts.json create hubot-scripts.json create .gitignore create package.json create scripts\example.coffee create .editorconfig _____________________________ _____ / \ \ \ | Self-replication process | | | _____ | complete... | |__\| /_____\ \ Good luck with that. / |//+ |[^_/\_]| /---------------------------- | | _|___@@__|__ +===+/ /// \_\ | |_\ /// HUBOT/\ |___/// / \ \ / +---+ \____/ | | | //| +===+ // |xx| npm WARN deprecated coffee-script@1.6.3: CoffeeScript on NPM has moved to "coffeescript" (no hyphen) npm notice created a lockfile as package-lock.json. You should commit this file. + hubot-pugme@0.1.1 + hubot-google-images@0.2.7 + hubot-scripts@2.17.2 + hubot-help@1.0.1 + hubot-heroku-keepalive@1.0.3 + hubot@3.1.1 + hubot-diagnostics@1.0.0 + hubot-redis-brain@1.0.0 + hubot-maps@0.0.3 + hubot-shipit@0.2.1 + hubot-rules@1.0.0 + hubot-slack@4.5.5 + hubot-google-translate@0.2.1 added 157 packages from 126 contributors and audited 268 packages in 8.061s found 0 vulnerabilities user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot $ bin/hubot audited 268 packages in 1.737s found 0 vulnerabilities body-parser deprecated undefined extended: provide extended option node_modules\hubot\src\robot.js:445:21 No history available userhubot> [Sun Nov 04 2018 02:13:24 GMT+0900 (東京 (標準時))] WARNING Loading scripts from hubot-scripts.json is deprecated and will be removed in 3.0 (https://github.com/github/hubot-scripts/issues/1113) in favor of packages for each script. Your hubot-scripts.json is empty, so you just need to remove it. [Sun Nov 04 2018 02:13:25 GMT+0900 (東京 (標準時))] INFO hubot-redis-brain: Using default redis on localhost:6379 [Sun Nov 04 2018 02:13:25 GMT+0900 (東京 (標準時))] ERROR hubot-heroku-keepalive included, but missing HUBOT_HEROKU_KEEPALIVE_URL. `heroku config:set HUBOT_HEROKU_KEEPALIVE_URL=$(heroku apps:info -s | grep web.url | cut -d= -f2)` userhubot> userhubot ping userhubot> PONG userhubot> exit user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot $ git init Initialized empty Git repository in C:/Users/user/myhubot/.git/ user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ git add . user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ git commit -m "first hubot" [master (root-commit) 96660f8] first hubot 11 files changed, 1517 insertions(+) create mode 100644 .editorconfig create mode 100644 .gitignore create mode 100644 Procfile create mode 100644 README.md create mode 100644 bin/hubot create mode 100644 bin/hubot.cmd create mode 100644 external-scripts.json create mode 100644 hubot-scripts.json create mode 100644 package-lock.json create mode 100644 package.json create mode 100644 scripts/example.coffee user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ heroku create Creating app... done, ⬢ frozen-brushlands-***** https://frozen-brushlands-*****.herokuapp.com/ | https://git.heroku.com/frozen-brushlands-*****.git user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ heroku open user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ heroku config:add HUBOT_SLACK_TEAM=hoge Setting HUBOT_SLACK_TEAM and restarting ⬢ frozen-brushlands-*****... done, v3 HUBOT_SLACK_TEAM: hoge user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ heroku config:add HUBOT_SLACK_BOTNAME=huga Setting HUBOT_SLACK_BOTNAME and restarting ⬢ frozen-brushlands-*****... done, v4 HUBOT_SLACK_BOTNAME: huga user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ heroku config:add HEROKU_URL=https://frozen-brushlands-*****.herokuapp.com/ Setting HEROKU_URL and restarting ⬢ frozen-brushlands-*****... done, v5 ! Warning: The "HEROKU_" namespace is protected and shouldn't be used. HEROKU_URL: https://frozen-brushlands-*****.herokuapp.com/ user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ heroku config:add HUBOT_SLACK_TOKEN=******** Setting HUBOT_SLACK_TOKEN and restarting ⬢ frozen-brushlands-*****... done, v6 HUBOT_SLACK_TOKEN: ******** user@LAPTOP-7JFGU5LM MINGW64 ~/myhubot (master) $ git push heroku master Enumerating objects: 15, done. Counting objects: 100% (15/15), done. Delta compression using up to 8 threads Compressing objects: 100% (11/11), done. Writing objects: 100% (15/15), 16.99 KiB | 3.40 MiB/s, done. Total 15 (delta 0), reused 0 (delta 0) remote: Compressing source files... done. remote: Building source: remote: remote: -----> Node.js app detected remote: remote: -----> Creating runtime environment remote: remote: NPM_CONFIG_LOGLEVEL=error remote: NODE_ENV=production remote: NODE_MODULES_CACHE=true remote: NODE_VERBOSE=false remote: remote: -----> Installing binaries remote: engines.node (package.json): 0.10.x remote: engines.npm (package.json): unspecified (use default) remote: remote: Resolving node version 0.10.x... remote: Downloading and installing node 0.10.48... remote: Detected package-lock.json: defaulting npm to version 5.x.x remote: Bootstrapping npm 5.x.x (replacing 2.15.1)... remote: npm 5.x.x installed remote: remote: /tmp/build_****************/.heroku/node/lib/node_modules/npm/bin/npm-cli.js:79 remote: var notifier = require('update-notifier')({pkg}) remote: ^ remote: SyntaxError: Unexpected token } remote: at Module._compile (module.js:439:25) remote: at Object.Module._extensions..js (module.js:474:10) remote: at Module.load (module.js:356:32) remote: at Function.Module._load (module.js:312:12) remote: at Function.Module.runMain (module.js:497:10) remote: at startup (node.js:119:16) remote: at node.js:945:3 remote: remote: /tmp/build_****************/.heroku/node/lib/node_modules/npm/bin/npm-cli.js:79 remote: var notifier = require('update-notifier')({pkg}) remote: ^ remote: SyntaxError: Unexpected token } remote: at Module._compile (module.js:439:25) remote: at Object.Module._extensions..js (module.js:474:10) remote: at Module.load (module.js:356:32) remote: at Function.Module._load (module.js:312:12) remote: at Function.Module.runMain (module.js:497:10) remote: at startup (node.js:119:16) remote: at node.js:945:3 remote: /app/tmp/buildpacks/********************************/lib/failure.sh: line 500: [: : integer expression expected remote: remote: -----> Building dependencies remote: Installing node modules (package.json + package-lock) remote: remote: /tmp/build_****************/.heroku/node/lib/node_modules/npm/bin/npm-cli.js:79 remote: var notifier = require('update-notifier')({pkg}) remote: ^ remote: SyntaxError: Unexpected token } remote: at Module._compile (module.js:439:25) remote: at Object.Module._extensions..js (module.js:474:10) remote: at Module.load (module.js:356:32) remote: at Function.Module._load (module.js:312:12) remote: at Function.Module.runMain (module.js:497:10) remote: at startup (node.js:119:16) remote: at node.js:945:3 remote: remote: -----> Build failed remote: remote: We're sorry this build is failing! You can troubleshoot common issues here: remote: https://devcenter.heroku.com/articles/troubleshooting-node-deploys remote: remote: If you're stuck, please submit a ticket so we can help: remote: https://help.heroku.com/ remote: remote: Love, remote: Heroku remote: remote: ! Push rejected, failed to compile Node.js app. remote: remote: ! Push failed remote: Verifying deploy... remote: remote: ! Push rejected to frozen-brushlands-*****. remote: To https://git.heroku.com/frozen-brushlands-*****.git ! [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to 'https://git.heroku.com/frozen-brushlands-*****.git'

試したこと

ありません。かなり調べて手は動かしましたが。

補足情報(FW/ツールのバージョンなど)

どのような情報があればいいのかもわからないので、不足があれば逆質問をお願いします。
迅速にお答えします。

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

chalinca

2018/11/04 00:11

すみません。それを試すものだと知りませんでした。試してまた報告します。
chalinca

2018/11/04 05:55

できました。迅速な対応、的確なヒントをありがとうございました!(「Check your buildpack Compare」 「Node and npm Versions」の項目を修正したらできました。)
guest

回答1

0

自己解決

以下、mrkmykiさんの追記コメントのURLにアクセスし、
URL先の項目を上から順にやっていったら解決しました。
(私は上から2個の項目まで試したところ、解決しました。
項目:「Check your buildpack Compare」、「Node and npm Versions」)

”エラーメッセージに書いてあるURLを確認して全て試しましたか? https://devcenter.heroku.com/articles/troubleshooting-node-deploys”

エラー文のURLを試すといいことが分かりました。
初歩的な質問に、ご親切に反応していただいたmrkmykiさんありがとうございました。

投稿2018/11/05 14:04

chalinca

総合スコア10

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問