Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace sass-rails gem by sassc-rails #1876

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Replace sass-rails gem by sassc-rails #1876

wants to merge 1 commit into from

Conversation

voodoorai2000
Copy link
Member

@voodoorai2000 voodoorai2000 commented Feb 12, 2019

References

PR: consuldemocracy#3286

Objectives

Replacing sass-rails by its C version, the former relying on a deprecated gem.

Does this PR need a Backport to CONSUL?

No, this comes from Upstream.

Notes

Manual testing in staging server required.

Update

Getting an error when deploying to the staging environment at the point of installing the gem. Looks like there is a missing system library dependency:

01:45 bundler:install
      01 /aytomad/app/participa/participacion/rvm1scripts/rvm-auto.sh 2.3.2 bundle install --path /aytomad/app/participa/parti…
      01
      01 Warning: PATH set to RVM ruby but GEM_HOME and/or GEM_PATH not set, see:
      01     https://github.com/rvm/rvm/issues/3212
      01
      01 Warning! PATH is not properly set up, $GEM_HOME is not set.
      01          Usually this is caused by shell initialization files. Search for 'PATH=...' entries.
      01          You can also re-add RVM to your profile by running: 'rvm get stable --auto-dotfiles'.
      01          To fix it temporarily in this shell session run: 'rvm use ruby-2.3.2'.
      01          To ignore this error add rvm_silence_path_mismatch_check_flag=1 to your ~/.rvmrc file.
      01
      01 Warning: PATH set to RVM ruby but GEM_HOME and/or GEM_PATH not set, see:
      01     https://github.com/rvm/rvm/issues/3212
      01
      01 Warning! PATH is not properly set up, $GEM_HOME is not set.
      01          Usually this is caused by shell initialization files. Search for 'PATH=...' entries.
      01          You can also re-add RVM to your profile by running: 'rvm get stable --auto-dotfiles'.
      01          To fix it temporarily in this shell session run: 'rvm use ruby-2.3.2'.
      01          To ignore this error add rvm_silence_path_mismatch_check_flag=1 to your ~/.rvmrc file.
      01 Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
      01
      01 current directory:
      01 /aytomad/app/participa/participacion/shared/bundle/ruby/2.3.0/gems/sassc-1.12.1/ext
      01 /aytomad/app/participa/.rvm/rubies/ruby-2.3.2/bin/ruby -rubygems
      01 /aytomad/app/participa/participacion/shared/bundle/ruby/2.3.0/gems/rake-12.3.2/exe/rake
      01 RUBYARCHDIR=/aytomad/app/participa/participacion/shared/bundle/ruby/2.3.0/extensions/x86_64-linux/2.3.0/sassc-1.12.1
      01 RUBYLIBDIR=/aytomad/app/participa/participacion/shared/bundle/ruby/2.3.0/extensions/x86_64-linux/2.3.0/sassc-1.12.1
      01 cd libsass
      01 make lib/libsass.so
      01 mkdir lib
      01 cc -Wall -O2 -I
      01 /aytomad/app/participa/participacion/shared/bundle/ruby/2.3.0/gems/sassc-1.12.1/ext/libsass/include
      01 -fPIC -fPIC -c -o src/cencode.o src/cencode.c
      01 src/cencode.c: In function 'base64_encode_block':
      01 src/cencode.c:50: warning: empty declaration
      01 src/cencode.c:64: warning: empty declaration
      01 g++ -Wall -O2 -std=c++0x -I
      01 /aytomad/app/participa/participacion/shared/bundle/ruby/2.3.0/gems/sassc-1.12.1/ext/libsass/include
      01 -fPIC -fPIC -c -o src/ast.o src/ast.cpp
      01 In file included from src/ast.cpp:2:
      01 src/ast.hpp: In member function 'virtual size_t Sass::Vectorized<T>::hash()':
      01 src/ast.hpp:336: error: expected initializer before ':' token

@@ -42,7 +42,7 @@ gem 'redcarpet', '~> 3.4.0'
gem 'responders', '~> 2.4.0'
gem 'rinku', '~> 2.0.2', require: 'rails_rinku'
gem 'rollbar', '~> 2.18.0'
gem 'sass-rails', '~> 5.0', '>= 5.0.4'
gem 'sassc-rails', '~> 1'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping. (https://github.com/bbatsov/ruby-style-guide#consistent-string-literals)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants