- xml - AJAX/Jquery XML 解析
- 具有多重继承的 XML 模式
- .net - 枚举序列化 Json 与 XML
- XML 简单类型、简单内容、复杂类型、复杂内容
在我的电脑上一切正常,但我无法推送到 Heroku。
我正在做名为“Ruby on Rails 教程(第 3 版)”,他们希望我在 Gemfile 中有一行
gem 'sass-rails', '5.0.1'
如果没有那一行,我在推送时没有问题,但如果添加这一行,我会得到:
->git push heroku master
Counting objects: 3, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 321 bytes | 0 bytes/s, done.
Total 3 (delta 2), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Ruby app detected
remote: -----> Compiling Ruby/Rails
remote: -----> Using Ruby version: ruby-2.2.1
remote: -----> Installing dependencies using 1.7.12
remote: Ruby version change detected. Clearing bundler cache.
remote: Old: ruby 2.0.0p643 (2015-02-25 revision 49749) [x86_64-linux]
remote: New: ruby 2.2.1p85 (2015-02-26 revision 49769) [x86_64-linux]
remote: Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
remote: Fetching gem metadata from https://rubygems.org/...........
remote: Using rake 10.4.2
remote: Installing minitest 5.5.1
remote: Installing i18n 0.7.0
remote: Installing thread_safe 0.3.5
remote: Installing builder 3.2.2
remote: Installing mini_portile 0.6.2
remote: Installing erubis 2.7.0
remote: Installing rack 1.6.0
remote: Installing mime-types 2.4.3
remote: Installing coffee-script-source 1.9.1.1
remote: Installing arel 6.0.0
remote: Installing execjs 2.5.2
remote: Installing thor 0.19.1
remote: Installing json 1.8.2
remote: Using bundler 1.7.12
remote: Installing multi_json 1.11.0
remote: Installing rails_stdout_logging 0.0.3
remote: Using rdoc 4.2.0
remote: Installing rails_serve_static_assets 0.0.4
remote: Installing tilt 1.4.1
remote: Installing sass 3.4.13
remote: Installing tzinfo 1.2.2
remote: Installing rack-test 0.6.3
remote: Installing sprockets 3.0.0
remote: Installing mail 2.6.3
remote: Installing coffee-script 2.4.1
remote: Installing uglifier 2.5.3
remote: Installing sdoc 0.4.0
remote: Installing rails_12factor 0.0.2
remote: Installing activesupport 4.2.0
remote: Installing rails-deprecated_sanitizer 1.0.3
remote: Installing globalid 0.3.5
remote: Installing activemodel 4.2.0
remote: Installing jbuilder 2.2.3
remote: Installing activejob 4.2.0
remote: Installing activerecord 4.2.0
remote: Installing pg 0.17.1
remote: Installing nokogiri 1.6.6.2
remote: Installing rails-dom-testing 1.0.6
remote: Installing loofah 2.0.1
remote: Installing rails-html-sanitizer 1.0.2
remote: Installing actionview 4.2.0
remote: Installing actionpack 4.2.0
remote: Installing actionmailer 4.2.0
remote: Installing sprockets-rails 2.2.4
remote: Installing railties 4.2.0
remote: Installing coffee-rails 4.1.0
remote: Installing jquery-rails 4.0.3
remote: Installing rails 4.2.0
remote: Installing sass-rails 5.0.1
remote: Installing turbolinks 2.3.0
remote: Your bundle is complete!
remote: Gems in the groups development and test were not installed.
remote: It was installed into ./vendor/bundle
remote: Bundle completed (31.90s)
remote: Cleaning up the bundler cache.
remote: Could not detect rake tasks
remote: ensure you can run `$ bundle exec rake -P` against your app with no environment variables present
remote: and using the production group of your Gemfile.
remote: This may be intentional, if you expected rake tasks to be run
remote: cancel the build (CTRL+C) and fix the error then commit the fix:
remote: rake aborted!
remote: NameError: uninitialized constant Sass::Script
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass/rails/helpers.rb:11:in `<top (required)>'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass/rails.rb:8:in `require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass/rails.rb:8:in `<top (required)>'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass-rails.rb:1:in `require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass-rails.rb:1:in `<top (required)>'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:76:in `require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:72:in `each'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:72:in `block in require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:61:in `each'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:61:in `require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler.rb:134:in `require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/config/application.rb:7:in `<top (required)>'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/Rakefile:4:in `require'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/Rakefile:4:in `<top (required)>'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/rake_module.rb:28:in `load'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/rake_module.rb:28:in `load_rakefile'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:689:in `raw_load_rakefile'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:94:in `block in load_rakefile'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:176:in `standard_exception_handling'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:93:in `load_rakefile'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:77:in `block in run'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:176:in `standard_exception_handling'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/2.2.0/rake/application.rb:75:in `run'
remote: /tmp/build_c3f0fc873b0d5baf26f3fbbfb448e8a1/vendor/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/rake-10.4.2/bin/rake:33:in `<top (required)>'
remote: vendor/bundle/bin/rake:16:in `load'
remote: vendor/bundle/bin/rake:16:in `<main>'
remote:
remote: ###### WARNING:
remote: No Procfile detected, using the default web server (webrick)
remote: https://devcenter.heroku.com/articles/ruby-default-web-server
remote:
remote: -----> Discovering process types
remote: Procfile declares types -> (none)
remote: Default types for Ruby -> console, rake, web, worker
remote:
remote: -----> Compressing... done, 29.0MB
remote: -----> Launching... done, v8
remote: https://warm-bayou-7787.herokuapp.com/ deployed to Heroku
remote:
remote: Verifying deploy... done.
To https://git.heroku.com/warm-bayou-7787.git
7b733ac..a4a374f master -> master
但是当我跑的时候,如他们所愿
->heroku run -a warm-bayou-7787 bundle exec rake -P
我明白了
Running `bundle exec rake -P` attached to terminal... up, run.4029
rake aborted!
NameError: uninitialized constant Sass::Script
/app/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass/rails/helpers.rb:11:in `<top (required)>'
/app/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass/rails.rb:8:in `require'
/app/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass/rails.rb:8:in `<top (required)>'
/app/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass-rails.rb:1:in `require'
/app/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.1/lib/sass-rails.rb:1:in `<top (required)>'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:76:in `require'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:72:in `each'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:72:in `block in require'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:61:in `each'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler/runtime.rb:61:in `require'
/app/vendor/bundle/ruby/2.2.0/gems/bundler-1.7.12/lib/bundler.rb:134:in `require'
/app/config/application.rb:7:in `<top (required)>'
/app/Rakefile:4:in `require'
/app/Rakefile:4:in `<top (required)>'
(See full trace by running task with --trace)
WARNING: Toolbelt v3.31.3 update available.
我该怎么办?我有一种感觉,就像之前一直在做那个教程一样,我从来没有遇到任何问题,一切都很好。
如果我删除 sass 并再次推送一次一切正常
最佳答案
我刚刚在 Cloud9 路由上遇到了同样的错误,并通过在 gemfiles 中使用 5.0.2+ 版本修复了它。
关于ruby-on-rails - ruby sass-rails gem 和 heroku 推送错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29593765/
sanitize 是什么意思在 Rails 中是什么意思? 我正在阅读 CanCanCan 的文档.它说: When using strong_parameters or Rails 4+, you
在过去的几个月里,我感觉自己对 Ruby on Rails (RoR) 开发的了解达到了极限。我为大/小客户和 friend /爱好项目开发了大大小小的应用程序。我知道如何开发这些应用程序,但开始感觉
我昨天参加了一个关于扩展 Rails 的聚会,其中一个主题是 Hexagonal Rails。然而,我只做了一年的 Rails,对 MVC 结构非常满意(也许太舒服了),所以我不太了解适配器和消息队列
我使用多个 Rails 应用程序,一些在 Rails 3.2/Ruby 2.0 上,一些在 Rails 2.3/Ruby 1.8.7 上。 他们的共同点是,随着他们的成长和添加更多的依赖项/ gem
这个问题在这里已经有了答案: Using Rails-UJS in JS modules (Rails 6 with webpacker) (5 个答案) 关闭 3 年前。 我正在尝试使用 UJS
我正在开发一个当前使用 Rails 1.2 的 Rails 应用程序,所以我现在离最新的稳定版本(Rails 2.3)还有很长的路要走。 我应该如何进行迁移到更新版本的 Rails 的过程? 我应该一
尝试按照 Ryan Bates Backbone.js 教程构建抽奖应用程序,但我已经遇到了第一段代码的问题。在 application.js 的 init 函数中,他初始化了 Raffler 路由的
我正在使用 Rails 3.2 并且我有一个数据库表,我想在其中找到符合以下条件的所有行: a = true and b = true and ( 0 true, :b =>
我有一个用户类和一个联系人,其中联系人是用户的子类。这两个类都存储在用户表中。 我的联系人可能有也可能没有电子邮件地址,而我的用户需要一个电子邮件地址(我的用户模型定义中有 validates_pre
我正在编写一个教程,我在其中演示了一些 rails 命令。在我的机器上 rails和 script/rails两者都同样有效。有“首选”形式吗?两者中哪一个更普遍? 最佳答案 当您运行 rails 时
我正在寻找有关通过我的应用程序前进的最佳方式的建议,这是我首次开始集成Elasticsearch。我是一名初学者,但是热衷于深入研究,以便原谅任何明显的错误! 我遵循了http://www.sitep
我刚刚用 Rails new 启动了一个新的 Rails 应用程序,将默认数据库设置更改为 PostgresSQL。我用 bin/rails s 启动服务器,结果很奇怪 2016-04-21 05:0
我收到一个参数并希望它是这样的字符串: "abc,efg" 或者像这样的数组 ["abc","efg"] 在第一种情况下,我想将它转换成一个数组,什么是好的方法? 这是我的想法 if params[:
我刚刚用 Rails new 启动了一个新的 Rails 应用程序,将默认数据库设置更改为 PostgresSQL。我用 bin/rails s 启动服务器,结果很奇怪 2016-04-21 05:0
我收到一个参数并希望它是这样的字符串: "abc,efg" 或者像这样的数组 ["abc","efg"] 在第一种情况下,我想将它转换成一个数组,什么是好的方法? 这是我的想法 if params[:
我有 Rails 4,这是我的默认版本(我仍然希望它是)。但我不想在我的电脑上添加 rails 3.2。在以下命令中:gem install rails -v 3.2.16 我有这个警告: railt
您好,我想使用 Sheevaplug 构建一个“Rails Brick”来自 Marvell(操作系统是开箱即用的 Ubuntu,但您可以在其上安装其他发行版)。它将成为家庭服务器和静音、低成本(99
我需要能够从 Rails 控制台发送我的 Rails 应用程序的 Postgres 数据库中所有未接受的邀请。 (我有一个名为 Invitations 的表,其中包含一个名为 accepted 的 b
validate :cannot_modify_if_locked, on: :update def cannot_modify_if_locked if self.locked erro
我正在学习教程(学习 Rails 播客),需要更改以下路由语法,以便它与 Rails 3.0 兼容。谁能帮忙? map.view_page ':name', :controller => 'viewe
我是一名优秀的程序员,十分优秀!