Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

Fix build by using precise distro, added more Ruby versions to test #2488

Merged
merged 2 commits into from
Oct 6, 2017
Merged

Conversation

morgoth
Copy link
Contributor

@morgoth morgoth commented Sep 17, 2017

No description provided.

@morgoth
Copy link
Contributor Author

morgoth commented Sep 18, 2017

@geoffharcourt Looks like there was a change in default travis image which after, paperclip tests are failing. https://blog.travis-ci.com/2017-08-29-trusty-image-updates
I tried to use previous one, but it fails as well.
I can try to write Travis support unless you have some other findings or want to do it on your own.

@josephpage
Copy link

josephpage commented Sep 27, 2017

Hey @morgoth, I found this message in the blog post : For the sudo: false images, this workaround is not available..

Also, why use dist: trusty and not language: ruby ?

@morgoth
Copy link
Contributor Author

morgoth commented Sep 27, 2017

@josephpage Tried different configurations ;-) No luck so far

@josephpage
Copy link

josephpage commented Sep 27, 2017

Locally, simulating Travis container with this Docker image, it works after uninstall and reinstall the imagemagick apt package. So, very strange.

Did you tried adding these lines ?

addons:
  apt:
    packages:
    - imagemagick

Source 1 : Troubleshooting Locally in a Docker Image (docs.travis-ci.com)
Source 2 : Installing Packages on Container-Based-Infrastructure (docs.travis-ci.com)

@morgoth
Copy link
Contributor Author

morgoth commented Sep 27, 2017

@josephpage
Copy link

josephpage commented Sep 27, 2017

Found !
The ghostscript dependency is missing (which depends on others : libcupsfilters1 libcupsimage2 libgs9 libgs9-common libijs-0.35 libjbig2dec0 libpaper-utils libpaper1 poppler-data)

addons:
  apt:
    packages:
    - ghostscript

Successfully tested locally.

@josephpage
Copy link

Yeah 🎉 the errors are not the same !

@morgoth
Copy link
Contributor Author

morgoth commented Sep 27, 2017

I'm getting totally different failure locally, but also with cucumber...

    Given I generate a new rails application                                            # features/step_definitions/rails_steps.rb:1
    And I run a rails generator to generate a "User" scaffold with "name:string"        # features/step_definitions/rails_steps.rb:82
      expected "rails generate scaffold User name:string" to be successfully executed (RSpec::Expectations::ExpectationNotMetError)
      ./features/step_definitions/rails_steps.rb:83:in `/^I run a rails generator to generate a "([^"]*)" scaffold with "([^"]*)"$/'
      features/rake_tasks.feature:5:in `And I run a rails generator to generate a "User" scaffold with "name:string"'

@josephpage
Copy link

I'm getting exactly the same !! 😞

@josephpage
Copy link

To reproduce the same errors as in Travis builds, you need to execute export BUNDLE_GEMFILE=$PWD/gemfiles/5.0.gemfile before bundle install
See : https://travis-ci.org/thoughtbot/paperclip/jobs/280457277#L575

@morgoth
Copy link
Contributor Author

morgoth commented Sep 28, 2017

Now I'm confused.
It now passes, but it says it's still using latest bundler Using bundler 1.15.4 during gems install.
Anyway, it's green - I'm not touching it :-)

@josephpage Thank you for your help.

@geoffharcourt Looks like this PR fixes master build - can you have a look please?

@josephpage
Copy link

Thank you very much @morgoth ! 🎉

2 notes :

  • maybe we should explicitly mention imagemagick in the addons.apt.packages key, to prevent future issues with dependencies. As ghostscript is a optional dependency of imagemagick (packages.ubuntu.com), we should mention both (maybe in the README.md too).
  • I confirm this locally works with modern bundler (1.15.4)...

@geoffharcourt geoffharcourt merged commit 38166cf into thoughtbot:master Oct 6, 2017
@geoffharcourt
Copy link
Contributor

@morgoth thank you very much for fixing these build problems!

@josephpage I noticed when I was testing locally that I hadn't installed imagemagick on this particular machine and had some issues. If you can do a PR to update dependency checking and/or documentation I'd be happy to review.

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

Successfully merging this pull request may close these issues.

3 participants