<Ruby on Rails エラー編> herokuでデプロイするときに発生したエラー
1回目
-----> Building on the Heroku-20 stack -----> Determining which buildpack to use for this app ! Warning: Multiple default buildpacks reported the ability to handle this app. The first buildpack in the list below will be used. Detected buildpacks: Ruby,Node.js See https://devcenter.heroku.com/articles/buildpacks#buildpack-detect-order -----> Ruby app detected -----> Installing bundler 2.2.16 -----> Removing BUNDLED WITH version in the Gemfile.lock -----> Compiling Ruby/Rails -----> Using Ruby version: ruby-2.6.6 -----> Installing dependencies using bundler 2.2.16 Running: BUNDLE_WITHOUT='development:test' BUNDLE_PATH=vendor/bundle BUNDLE_BIN=vendor/bundle/bin BUNDLE_DEPLOYMENT=1 bundle install -j4 Your Gemfile lists the gem aws-sdk-rails (>= 0) more than once. You should probably keep only one of them. Remove any duplicate entries and specify the gem only once. While it's not a problem now, it could cause errors if you change the version of one of them later. Your bundle only supports platforms ["x86_64-darwin-20"] but your local platform is x86_64-linux. Add the current platform to the lockfile with `bundle lock --add-platform x86_64-linux` and try again. Bundler Output: Your Gemfile lists the gem aws-sdk-rails (>= 0) more than once. You should probably keep only one of them. Remove any duplicate entries and specify the gem only once. While it's not a problem now, it could cause errors if you change the version of one of them later. Your bundle only supports platforms ["x86_64-darwin-20"] but your local platform is x86_64-linux. Add the current platform to the lockfile with `bundle lock --add-platform x86_64-linux` and try again. ! ! Failed to install gems via Bundler. ! ! Push rejected, failed to compile Ruby app. ! Push failed
Your Gemfile lists the gem aws-sdk-rails (>= 0) more than once.
から、gemfileで重複していたaws-sdk-railsを削除
ここで、herokuでサポートされている最新のバージョンのruby3.0.1になっていなかったことに気づいて変更して、念の為もう一度heroku push
https://devcenter.heroku.com/articles/ruby-support#ruby-versions
2回目
-----> Building on the Heroku-20 stack -----> Determining which buildpack to use for this app ! Warning: Multiple default buildpacks reported the ability to handle this app. The first buildpack in the list below will be used. Detected buildpacks: Ruby,Node.js See https://devcenter.heroku.com/articles/buildpacks#buildpack-detect-order -----> Ruby app detected -----> Installing bundler 2.2.16 -----> Removing BUNDLED WITH version in the Gemfile.lock -----> Compiling Ruby/Rails -----> Using Ruby version: ruby-3.0.1 -----> Installing dependencies using bundler 2.2.16 Running: BUNDLE_WITHOUT='development:test' BUNDLE_PATH=vendor/bundle BUNDLE_BIN=vendor/bundle/bin BUNDLE_DEPLOYMENT=1 bundle install -j4 Fetching gem metadata from https://rubygems.org/.......... Fetching rake 13.0.3 〜省略〜 Installing bootstrap 5.0.1 Bundle complete! 27 Gemfile dependencies, 102 gems now installed. Gems in the groups 'development' and 'test' were not installed. Bundled gems are installed into `./vendor/bundle` Bundle completed (163.23s) Cleaning up the bundler cache. -----> Installing node-v12.16.2-linux-x64 -----> Installing yarn-v1.22.4 -----> Detecting rake tasks -----> Preparing app for Rails asset pipeline Running: rake assets:precompile yarn install v1.22.4 [1/4] Resolving packages... [2/4] Fetching packages... info fsevents@2.3.2: The platform "linux" is incompatible with this module. info "fsevents@2.3.2" is an optional dependency and failed compatibility check. Excluding it from installation. info fsevents@1.2.13: The platform "linux" is incompatible with this module. info "fsevents@1.2.13" is an optional dependency and failed compatibility check. Excluding it from installation. [3/4] Linking dependencies... warning " > bootstrap@5.0.1" has unmet peer dependency "@popperjs/core@^2.9.2". [4/4] Building fresh packages... Done in 25.96s. I, [2021-06-02T13:39:00.278337 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/manifest-b4bf6e57a53c2bdb55b8998cc94cd00883793c1c37c5e5aea3ef6749b4f6d92b.js I, [2021-06-02T13:39:00.278779 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/manifest-b4bf6e57a53c2bdb55b8998cc94cd00883793c1c37c5e5aea3ef6749b4f6d92b.js.gz I, [2021-06-02T13:39:00.279173 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/akadamakinugasatake-71fb3883dd6034b8c25182024af2570fcee1b197d41f46cfefc1c27cf6a8a291.png I, [2021-06-02T13:39:00.280564 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/amigasatake-35f500506e096388078ca5e01fd8a5c77d9b6c2dfde2252ead103b0e1d693882.png I, [2021-06-02T13:39:00.281103 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/benitengutake-5ea4ad04569b1041a0795c6d7492cff6bd59da8e23fef0733a2ccc4408802062.png I, [2021-06-02T13:39:00.281563 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/kaentake-657e92355edef4df6ff742bf63253b1d75c1b307bce7f9aeb8cbb486e3c97c92.png I, [2021-06-02T13:39:00.282130 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/kakishimezi-50878dfc4a10eb4b7060f63145e3ac79f24895829c0aefeb2909b31fec312a7c.png I, [2021-06-02T13:39:00.282721 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/kanzoutake-1a95e01d3d1565f363cb6067bb9988997d887d538b21cf1f48082dc0bbcbd3f8.png I, [2021-06-02T13:39:00.283140 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/kinoko-e06a2b4e2ae765e65a693926cbe0b822e20d9d4b4e78028250873f4639631191.png I, [2021-06-02T13:39:00.283706 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/kusaurabenitake-229be4a8d30c315b6931a6e28f6c39eea81214eda66a5e4f2e544ff686122e8b.png I, [2021-06-02T13:39:00.284441 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/sasakurehitoyotake-38fa61cfb566349ebf4948bbe31721c37326aa5531d2e82b783387c73c200eaa.png I, [2021-06-02T13:39:00.285108 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/shirotamagotengutake-cc81a8733a62bdd9b030b96a600fb5b4a455d966571d01007ec076358c036c28.png I, [2021-06-02T13:39:00.285841 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/tukiyotake-b8a617bf1aeb2ada4fe0d0637580c20f58951030e6bf2945794c5a0d10815c4b.png I, [2021-06-02T13:39:00.286249 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/application-46fde15497d4d5e232ff92d0eb558d7b04222e2d34c1e808f5c4a001108f768b.css I, [2021-06-02T13:39:00.286501 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/application-46fde15497d4d5e232ff92d0eb558d7b04222e2d34c1e808f5c4a001108f768b.css.gz I, [2021-06-02T13:39:00.286778 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/balloon-b98683eaa7c4aa99affca3e3353efd18a77b961b6a87e2f361cd3dd1dac24171.css I, [2021-06-02T13:39:00.286961 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/balloon-b98683eaa7c4aa99affca3e3353efd18a77b961b6a87e2f361cd3dd1dac24171.css.gz I, [2021-06-02T13:39:00.287262 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/results-a660d06b2b728f702540e3cac59b1eb4633b469c977cf8041bed8a4c9a86d20e.css I, [2021-06-02T13:39:00.287834 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/results-a660d06b2b728f702540e3cac59b1eb4633b469c977cf8041bed8a4c9a86d20e.css.gz I, [2021-06-02T13:39:00.288123 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/top-3ae5747852a558743cc03d6130525f9e639e7583fc17957dabcb9d68afbf367d.css I, [2021-06-02T13:39:00.288361 #1481] INFO -- : Writing /tmp/build_0e8c3275/public/assets/top-3ae5747852a558743cc03d6130525f9e639e7583fc17957dabcb9d68afbf367d.css.gz Compiling... Compilation failed: Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods", { "loose": true }] to the "plugins" section of your Babel config. ModuleNotFoundError: Module not found: Error: Can't resolve '@popperjs/core' in '/tmp/build_0e8c3275/node_modules/bootstrap/dist/js' at /tmp/build_0e8c3275/node_modules/webpack/lib/Compilation.js:925:10 at /tmp/build_0e8c3275/node_modules/webpack/lib/NormalModuleFactory.js:401:22 at /tmp/build_0e8c3275/node_modules/webpack/lib/NormalModuleFactory.js:130:21 at /tmp/build_0e8c3275/node_modules/webpack/lib/NormalModuleFactory.js:224:22 at /tmp/build_0e8c3275/node_modules/neo-async/async.js:2830:7 at /tmp/build_0e8c3275/node_modules/neo-async/async.js:6877:13 at /tmp/build_0e8c3275/node_modules/webpack/lib/NormalModuleFactory.js:214:25 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:213:14 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js:44:7 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:25:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:67:43 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:41:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/ModuleKindPlugin.js:30:40 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:14:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/forEachBail.js:30:14 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js:44:7 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:25:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:67:43 at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:14:1) at /tmp/build_0e8c3275/node_modules/enhanced-resolve/lib/RootPlugin.js:37:38 at _next42 (eval at create (/tmp/build_0e8c3275/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1) resolve '@popperjs/core' in '/tmp/build_0e8c3275/node_modules/bootstrap/dist/js' Parsed request is a module using description file: /tmp/build_0e8c3275/node_modules/bootstrap/package.json (relative path: ./dist/js) Field 'browser' doesn't contain a valid alias configuration resolve as module looking for modules in /tmp/build_0e8c3275/app/javascript using description file: /tmp/build_0e8c3275/package.json (relative path: ./app/javascript) Field 'browser' doesn't contain a valid alias configuration using description file: /tmp/build_0e8c3275/package.json (relative path: ./app/javascript/@popperjs/core) no extension Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core doesn't exist .mjs Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.mjs doesn't exist .js Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.js doesn't exist .sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.sass doesn't exist .scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.scss doesn't exist .css Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.css doesn't exist .module.sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.module.sass doesn't exist .module.scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.module.scss doesn't exist .module.css Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.module.css doesn't exist .png Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.png doesn't exist .svg Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.svg doesn't exist .gif Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.gif doesn't exist .jpeg Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.jpeg doesn't exist .jpg Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/app/javascript/@popperjs/core.jpg doesn't exist as directory /tmp/build_0e8c3275/app/javascript/@popperjs/core doesn't exist /tmp/build_0e8c3275/node_modules/bootstrap/dist/js/node_modules doesn't exist or is not a directory /tmp/build_0e8c3275/node_modules/bootstrap/dist/node_modules doesn't exist or is not a directory /tmp/build_0e8c3275/node_modules/bootstrap/node_modules doesn't exist or is not a directory /tmp/build_0e8c3275/node_modules/node_modules doesn't exist or is not a directory /tmp/node_modules doesn't exist or is not a directory /node_modules doesn't exist or is not a directory looking for modules in /tmp/build_0e8c3275/node_modules using description file: /tmp/build_0e8c3275/package.json (relative path: ./node_modules) Field 'browser' doesn't contain a valid alias configuration using description file: /tmp/build_0e8c3275/package.json (relative path: ./node_modules/@popperjs/core) no extension Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core doesn't exist .mjs Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.mjs doesn't exist .js Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.js doesn't exist .sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.sass doesn't exist .scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.scss doesn't exist .css Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.css doesn't exist .module.sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.module.sass doesn't exist .module.scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.module.scss doesn't exist .module.css Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.module.css doesn't exist .png Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.png doesn't exist .svg Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.svg doesn't exist .gif Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.gif doesn't exist .jpeg Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.jpeg doesn't exist .jpg Field 'browser' doesn't contain a valid alias configuration /tmp/build_0e8c3275/node_modules/@popperjs/core.jpg doesn't exist as directory /tmp/build_0e8c3275/node_modules/@popperjs/core doesn't exist ! ! Precompiling assets failed. ! ! Push rejected, failed to compile Ruby app. ! Push failed
Though the "loose" option was set to "false" in your @babel/preset-env config, it will not be used for @babel/plugin-proposal-private-methods since the "loose" mode option was set to "true" for @babel/plugin-proposal-class-properties. The "loose" option must be the same for @babel/plugin-proposal-class-properties, @babel/plugin-proposal-private-methods and @babel/plugin-proposal-private-property-in-object (when they are enabled): you can silence this warning by explicitly adding ["@babel/plugin-proposal-private-methods”, { "loose": true }] to the "plugins" section of your Babel config. babel/preset-env設定で "loose"オプションが "false"に設定されていますが、@babel/plugin-proposal-class-properties の "loose" モードオプションが "true" に設定されているため、@babel/plugin-proposal-private-methodsでは使用されません。 babel/plugin-proposal-class-properties、@babel/plugin-proposal-private-methods、および @babel/plugin-proposal-property-in-object(これらが有効な場合)では、"loose"オプションは同じでなければなりません。 Babel/plugin-proposal-private-methods", { "loose": true }] を、あなたの Babel コンフィグの "plugins" セクションに明示的に追加することで、この警告を黙らせることができます。
ということなので、
https://github.com/nuxt/nuxt.js/issues/9224
を参考に、pluginsのところへ明示的に記入。
babel.config.js
... plugins: [ ["@babel/plugin-proposal-private-methods", { loose: true }], ...
またgit push heroku 作業ブランチ:mainすると、エラーが変わった。
3回目
-----> Building on the Heroku-20 stack -----> Determining which buildpack to use for this app ! Warning: Multiple default buildpacks reported the ability to handle this app. The first buildpack in the list below will be used. Detected buildpacks: Ruby,Node.js See https://devcenter.heroku.com/articles/buildpacks#buildpack-detect-order -----> Ruby app detected -----> Installing bundler 2.2.16 -----> Removing BUNDLED WITH version in the Gemfile.lock -----> Compiling Ruby/Rails -----> Using Ruby version: ruby-3.0.1 -----> Installing dependencies using bundler 2.2.16 Running: BUNDLE_WITHOUT='development:test' BUNDLE_PATH=vendor/bundle BUNDLE_BIN=vendor/bundle/bin BUNDLE_DEPLOYMENT=1 bundle install -j4 Fetching gem metadata from https://rubygems.org/.......... Fetching rake 13.0.3 〜省略〜 Installing bootstrap 5.0.1 Bundle complete! 27 Gemfile dependencies, 102 gems now installed. Gems in the groups 'development' and 'test' were not installed. Bundled gems are installed into `./vendor/bundle` Bundle completed (162.35s) Cleaning up the bundler cache. -----> Installing node-v12.16.2-linux-x64 -----> Installing yarn-v1.22.4 -----> Detecting rake tasks -----> Preparing app for Rails asset pipeline Running: rake assets:precompile yarn install v1.22.4 [1/4] Resolving packages... [2/4] Fetching packages... info fsevents@2.3.2: The platform "linux" is incompatible with this module. info "fsevents@2.3.2" is an optional dependency and failed compatibility check. Excluding it from installation. info fsevents@1.2.13: The platform "linux" is incompatible with this module. info "fsevents@1.2.13" is an optional dependency and failed compatibility check. Excluding it from installation. [3/4] Linking dependencies... warning " > bootstrap@5.0.1" has unmet peer dependency "@popperjs/core@^2.9.2". [4/4] Building fresh packages... Done in 23.51s. I, [2021-06-02T14:26:05.711596 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/manifest-b4bf6e57a53c2bdb55b8998cc94cd00883793c1c37c5e5aea3ef6749b4f6d92b.js I, [2021-06-02T14:26:05.711998 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/manifest-b4bf6e57a53c2bdb55b8998cc94cd00883793c1c37c5e5aea3ef6749b4f6d92b.js.gz I, [2021-06-02T14:26:05.712283 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/akadamakinugasatake-71fb3883dd6034b8c25182024af2570fcee1b197d41f46cfefc1c27cf6a8a291.png I, [2021-06-02T14:26:05.713852 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/amigasatake-35f500506e096388078ca5e01fd8a5c77d9b6c2dfde2252ead103b0e1d693882.png I, [2021-06-02T14:26:05.714328 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/benitengutake-5ea4ad04569b1041a0795c6d7492cff6bd59da8e23fef0733a2ccc4408802062.png I, [2021-06-02T14:26:05.714800 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/kaentake-657e92355edef4df6ff742bf63253b1d75c1b307bce7f9aeb8cbb486e3c97c92.png I, [2021-06-02T14:26:05.715509 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/kakishimezi-50878dfc4a10eb4b7060f63145e3ac79f24895829c0aefeb2909b31fec312a7c.png I, [2021-06-02T14:26:05.718116 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/kanzoutake-1a95e01d3d1565f363cb6067bb9988997d887d538b21cf1f48082dc0bbcbd3f8.png I, [2021-06-02T14:26:05.719638 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/kinoko-e06a2b4e2ae765e65a693926cbe0b822e20d9d4b4e78028250873f4639631191.png I, [2021-06-02T14:26:05.721303 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/kusaurabenitake-229be4a8d30c315b6931a6e28f6c39eea81214eda66a5e4f2e544ff686122e8b.png I, [2021-06-02T14:26:05.722192 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/sasakurehitoyotake-38fa61cfb566349ebf4948bbe31721c37326aa5531d2e82b783387c73c200eaa.png I, [2021-06-02T14:26:05.723958 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/shirotamagotengutake-cc81a8733a62bdd9b030b96a600fb5b4a455d966571d01007ec076358c036c28.png I, [2021-06-02T14:26:05.724964 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/tukiyotake-b8a617bf1aeb2ada4fe0d0637580c20f58951030e6bf2945794c5a0d10815c4b.png I, [2021-06-02T14:26:05.725653 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/application-46fde15497d4d5e232ff92d0eb558d7b04222e2d34c1e808f5c4a001108f768b.css I, [2021-06-02T14:26:05.726128 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/application-46fde15497d4d5e232ff92d0eb558d7b04222e2d34c1e808f5c4a001108f768b.css.gz I, [2021-06-02T14:26:05.727558 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/balloon-b98683eaa7c4aa99affca3e3353efd18a77b961b6a87e2f361cd3dd1dac24171.css I, [2021-06-02T14:26:05.729402 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/balloon-b98683eaa7c4aa99affca3e3353efd18a77b961b6a87e2f361cd3dd1dac24171.css.gz I, [2021-06-02T14:26:05.730227 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/results-a660d06b2b728f702540e3cac59b1eb4633b469c977cf8041bed8a4c9a86d20e.css I, [2021-06-02T14:26:05.730953 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/results-a660d06b2b728f702540e3cac59b1eb4633b469c977cf8041bed8a4c9a86d20e.css.gz I, [2021-06-02T14:26:05.731212 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/top-3ae5747852a558743cc03d6130525f9e639e7583fc17957dabcb9d68afbf367d.css I, [2021-06-02T14:26:05.731401 #1484] INFO -- : Writing /tmp/build_68105761/public/assets/top-3ae5747852a558743cc03d6130525f9e639e7583fc17957dabcb9d68afbf367d.css.gz Compiling... Compilation failed: ModuleNotFoundError: Module not found: Error: Can't resolve '@popperjs/core' in '/tmp/build_68105761/node_modules/bootstrap/dist/js' at /tmp/build_68105761/node_modules/webpack/lib/Compilation.js:925:10 at /tmp/build_68105761/node_modules/webpack/lib/NormalModuleFactory.js:401:22 at /tmp/build_68105761/node_modules/webpack/lib/NormalModuleFactory.js:130:21 at /tmp/build_68105761/node_modules/webpack/lib/NormalModuleFactory.js:224:22 at /tmp/build_68105761/node_modules/neo-async/async.js:2830:7 at /tmp/build_68105761/node_modules/neo-async/async.js:6877:13 at /tmp/build_68105761/node_modules/webpack/lib/NormalModuleFactory.js:214:25 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:213:14 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js:44:7 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:25:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:67:43 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:41:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/ModuleKindPlugin.js:30:40 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:14:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/forEachBail.js:30:14 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js:44:7 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:13:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:25:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:67:43 at /tmp/build_68105761/node_modules/enhanced-resolve/lib/Resolver.js:285:5 at eval (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:14:1) at /tmp/build_68105761/node_modules/enhanced-resolve/lib/RootPlugin.js:37:38 at _next42 (eval at create (/tmp/build_68105761/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1) resolve '@popperjs/core' in '/tmp/build_68105761/node_modules/bootstrap/dist/js' Parsed request is a module using description file: /tmp/build_68105761/node_modules/bootstrap/package.json (relative path: ./dist/js) Field 'browser' doesn't contain a valid alias configuration resolve as module looking for modules in /tmp/build_68105761/app/javascript using description file: /tmp/build_68105761/package.json (relative path: ./app/javascript) Field 'browser' doesn't contain a valid alias configuration using description file: /tmp/build_68105761/package.json (relative path: ./app/javascript/@popperjs/core) no extension Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core doesn't exist .mjs Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.mjs doesn't exist .js Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.js doesn't exist .sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.sass doesn't exist .scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.scss doesn't exist .css Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.css doesn't exist .module.sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.module.sass doesn't exist .module.scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.module.scss doesn't exist .module.css Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.module.css doesn't exist .png Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.png doesn't exist .svg Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.svg doesn't exist .gif Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.gif doesn't exist .jpeg Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.jpeg doesn't exist .jpg Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/app/javascript/@popperjs/core.jpg doesn't exist as directory /tmp/build_68105761/app/javascript/@popperjs/core doesn't exist /tmp/build_68105761/node_modules/bootstrap/dist/js/node_modules doesn't exist or is not a directory /tmp/build_68105761/node_modules/bootstrap/dist/node_modules doesn't exist or is not a directory /tmp/build_68105761/node_modules/bootstrap/node_modules doesn't exist or is not a directory /tmp/build_68105761/node_modules/node_modules doesn't exist or is not a directory /tmp/node_modules doesn't exist or is not a directory /node_modules doesn't exist or is not a directory looking for modules in /tmp/build_68105761/node_modules using description file: /tmp/build_68105761/package.json (relative path: ./node_modules) Field 'browser' doesn't contain a valid alias configuration using description file: /tmp/build_68105761/package.json (relative path: ./node_modules/@popperjs/core) no extension Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core doesn't exist .mjs Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.mjs doesn't exist .js Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.js doesn't exist .sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.sass doesn't exist .scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.scss doesn't exist .css Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.css doesn't exist .module.sass Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.module.sass doesn't exist .module.scss Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.module.scss doesn't exist .module.css Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.module.css doesn't exist .png Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.png doesn't exist .svg Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.svg doesn't exist .gif Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.gif doesn't exist .jpeg Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.jpeg doesn't exist .jpg Field 'browser' doesn't contain a valid alias configuration /tmp/build_68105761/node_modules/@popperjs/core.jpg doesn't exist as directory /tmp/build_68105761/node_modules/@popperjs/core doesn't exist ! ! Precompiling assets failed. ! ! Push rejected, failed to compile Ruby app. ! Push failed
warning " > bootstrap@5.0.1" has unmet peer dependency "@popperjs/core@^2.9.2".
と
ModuleNotFoundError: Module not found: Error: Can't resolve '@popperjs/core' in '/tmp/build_68105761/node_modules/bootstrap/dist/js'
から、bootstrap5に依存するpopperjsはpopperjs/coreであるということなので、yarn add @poppserjs/coreした。
成功!