ndbroadbent / turbo-sprockets-rails3

Speeds up your Rails 3 assets:precompile by only recompiling changed files, and only compiling once to generate all assets
MIT License
975 stars 78 forks source link

issue with 3.2.9 and heroku #33

Closed jjb closed 11 years ago

jjb commented 11 years ago

i was using turbo-sprockets-rails3 without the buildpack, just to get the other benefits.

it was working well with 0.1.16 and 3.2.8.

i just tried it with the newest version and 3.2.9, and the precompile step is skipped entirely.

let me know if you want any other info or if there is something i should try. thanks!

ndbroadbent commented 11 years ago

That's very strange, it should only skip the precompile step if it detects the presence of public/assets/manifest.yml, or your app doesn't have a rake assets:precompile task. These are heroku features and are unrelated to the gem. Can you check that you haven't checked in your assets, and let me know if rake assets:precompile is working on your local machine? Cheers

jjb commented 11 years ago

yep, no manifests, and precompile works locally. i just emailed you the output of my heroku push. let me know if oyu want any other info like my Gemfile.

to push some non-standard assets to s3 and stuff like that i have some Rake::Task["assets:precompile:nondigest"].enhance do blocks, not sure if that would affect anything.

ndbroadbent commented 11 years ago

Hi there,

Can you please confirm that precompile works properly when you remove 'turbo-sprockets-rails3' from your Gemfile?

On Fri, Nov 9, 2012 at 2:27 PM, John Joseph Bachir <notifications@github.com

wrote:

yep, no manifests, and precompile works locally. i just emailed you the output of my heroku push. let me know if oyu want any other info like my Gemfile.

to push some non-standard assets to s3 and stuff like that i have some Rake::Task["assets:precompile:nondigest"].enhance do blocks, not sure if that would affect anything.

— Reply to this email directly or view it on GitHubhttps://github.com/ndbroadbent/turbo-sprockets-rails3/issues/33#issuecomment-10212494.

jjb commented 11 years ago
➔ grep turbo-sprockets-rails3 Gemfile*
Gemfile:# https://github.com/ndbroadbent/turbo-sprockets-rails3/commit/8b422a974b19a3c91ad70e933bde45bcdede1ba0#commitcomment-2125121
Gemfile:# gem 'turbo-sprockets-rails3'
➔ foreman run bundle exec rake assets:precompile
/Users/john/.rbenv/versions/1.9.3-p286-perf/bin/ruby /Users/john/.rbenv/versions/1.9.3-p286-perf/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
foreman run bundle exec rake assets:precompile  142.82s user 19.29s system 70% cpu 3:50.62 total
➔
ndbroadbent commented 11 years ago

Sorry, I mean when you deploy to Heroku, does the precompile task run if turbo-sprockets-rails3 is removed?

jjb commented 11 years ago

yes

brendanstennett commented 11 years ago

You may not actually get a benefit with this gem deploying on Heroku. Are your old compiled assets even accessible during deployment on Heroku since this is done in a tmp path?

schneems commented 11 years ago

@jjb, did you ever figure out what was causing this issue, is it still a problem?

jjb commented 11 years ago

@schneems no, didn't look into it further. I'm just going to wait until the standard buildpack supports this gem (which i think @ndbroadbent said is probably going to happen?)

schneems commented 11 years ago

I work for Heroku, and i'm in the process of vetting this gem and getting its support into the buildpack. It would be bad if we recommended something that kills people's assets:precompile task all-together. Is your app still on Heroku? Could you email me the app name richard.schneeman@gmail.com?

jjb commented 11 years ago

@schneems i think it was skipping the precompile step because it was assuming that it was being done locally, because i wasn't using the forked buidpack

i've never even tried it with the forked buildpack

(maybe you already knew all that)

would you still like my app name and/or for me to try it with the new buildpack?

schneems commented 11 years ago

Using any of the buildpacks, if it was skipping assets:precompile with the gem in and running assets:precompile without the gem, then that is something I would like to dig into. If you wouldn't mind, i'm still interested, please send it my way.

jjb commented 11 years ago

sent

schneems commented 11 years ago

@ndbroadbent you can close this, we found the issue with something else. @jjb ping back on this thread if you get to the point again where precompiling on Heroku works without the gem but fails with it.

jjb commented 11 years ago

will do

ndbroadbent commented 11 years ago

OK, that's good to hear! Closing

jjb commented 11 years ago

@schneems is this supported in the default buildpack yet?

schneems commented 11 years ago

not yet :(

DouweM commented 11 years ago

Any ETA?

schneems commented 11 years ago

ping @hone, any chance of getting the asset caching patch merged in?

jjb commented 11 years ago

@schneems @hone ping :-)

iamnader commented 11 years ago

@hone +1, would be great to get this in by default. large asset directories take a really long time to deploy

jjb commented 11 years ago

@schneems @hone ping... :)

jjb commented 11 years ago

Here's the relevant pull request https://github.com/heroku/heroku-buildpack-ruby/pull/43 (right @ndbroadbent ?)