{"issue":{"created_at":"2011-11-18T14:15:54Z","state":"open","updated_at":"2011-11-18T14:15:54Z","comments":0,"user":{"gravatar_id":"0273cfca70ccb1caa0914cfc28e219e9","id":25157,"url":"https://api.github.com/users/hukl","login":"hukl","avatar_url":"https://secure.gravatar.com/avatar/0273cfca70ccb1caa0914cfc28e219e9?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"body":"Usecase: \r\n\r\nMy app with 2mio daily users uses a CDN to deliver assets. 80% of users use HTTP and 20% HTTPS. Therefor the request protocol should be reflected in the CDN url as SSL CDN traffic at a certain volume is much more expensive.\r\n\r\nNow when I precompile assets like stylesheets which contain asset_path( source ) calls, it crashes because at that point no request object for the proc is present. I think this unnecessary because if stylesheets are loaded from the CDN than assets referenced in them with relative urls will use the CDN host automatically so I don't need the host within stylesheets / js files.\r\n\r\nSo instead of raising an exception I'd rather not set the host in the stylesheets and use relative urls as if the asset host wasn't set at all.\r\n\r\n","assignee":null,"id":2280423,"number":3677,"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"labels":[],"title":"asset_path raising exception when using asset_host is a Proc","closed_at":null,"html_url":"https://github.com/rails/rails/issues/3677","milestone":null,"url":"https://api.github.com/repos/rails/rails/issues/3677"},"action":"opened"}