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

install issues, Bundler could not find compatible versions for gem "bundler" #47

Open
danielsprouse opened this issue Jan 14, 2019 · 51 comments

Comments

@danielsprouse
Copy link

danielsprouse commented Jan 14, 2019

I am running archivesspace 2.5.1 on RHEL 7.3,
[dsprouse@tslac4avned ~]$ ruby -v; gem -v
ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-linux]
3.0.2
[dsprouse@tslac4avned ~]$ gem info bundler

*** LOCAL GEMS ***

bundler (2.0.1, 1.17.3, 1.17.2, 1.16.1, 1.12.5)
Authors: André Arko, Samuel Giddins, Colby Swandale, Hiroshi
Shibata, David Rodríguez, Grey Baker, Stephanie Morillo, Chris
Morris, James Wen, Tim Moore, André Medeiros, Jessica Lynn Suttles,
Terence Lee, Carl Lerche, Yehuda Katz
Homepage: http://bundler.io
License: MIT
Installed at (2.0.1): /usr/local/lib/ruby/gems/2.5.0
(1.17.3, default): /usr/local/lib/ruby/gems/2.5.0
(1.17.2): /usr/local/lib/ruby/gems/2.5.0
(1.16.1): /usr/local/lib/ruby/gems/2.5.0
(1.12.5): /usr/local/lib/ruby/gems/2.5.0

The best way to manage your application's dependencies

[dsprouse@tslac4avned ~]$

and I have been having trouble for a while trying to get this plugin installed, but even when it has looked like it installed successfully, it resulted in archivesspace being unable to start.

originally I was getting this error:
ERROR: While executing gem ... (Gem::Requirement::BadRequirementError)
Illformed requirement ["1.12.5\n1.16.1"]
Gem::GemNotFoundException: can't find gem bundler (>= 0.a)
find_spec_for_exe at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems.rb:271
activate_bin_path at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems.rb:298

at ../../gems/bin/bundle:23

and after I installed the old bundler versions 1.12.5 and 1.16.1 it finally looked like it was installing, although with an error:
[dsprouse@tslac4avned scripts]$ sudo ./initialize-plugin.sh aspace-import-excel
ERROR: While executing gem ... (Gem::Requirement::BadRequirementError)
Illformed requirement ["1.12.5\n1.16.1"]
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and
installing your bundle as root will break this application for all non-root
users on this machine.
Using bundler 2.0.1
Using nokogiri 1.10.0 (java)
Using rubyzip 1.2.2
Using rubyXL 3.3.31
Bundle complete! 1 Gemfile dependency, 4 gems now installed.
Use bundle info [gemname] to see where a bundled gem is installed.
[dsprouse@tslac4avned scripts]$

and the result of that is that archivesspace starts, but is non-functional and this is the webpage output:
Internal Server Error (500)
Request Method: GET
Request URL: http://aris.tsl.texas.gov/

Bundler could not find compatible versions for gem "bundler": In Gemfile: rails (= 5.0.1) java was resolved to 5.0.1, which depends on bundler (< 2.0, >= 1.3.0) java Current Bundler version: bundler (2.0.1) This Gemfile requires a different version of Bundler. Perhaps you need to update Bundler by running gem install bundler? Could not find gem 'bundler (< 2.0, >= 1.3.0)', which is required by gem 'rails (= 5.0.1)', in any of the sources. from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/resolver.rb:56:in start' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/resolver.rb:22:in resolve' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/definition.rb:258:in resolve' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/definition.rb:170:in specs' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/definition.rb:237:in specs_for' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/definition.rb:226:in requested_specs' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/runtime.rb:108:in block in requested_specs' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/runtime.rb:20:in setup' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler.rb:107:in setup' from /var/www/aris/html/archivesspace/plugins/aspace-import-excel/gems/gems/bundler-2.0.1/lib/bundler/setup.rb:20:in

' from org/jruby/RubyKernel.java:961:in require' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:1:in (root)' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:133:in <main>' from org/jruby/RubyKernel.java:961:in require' from /var/www/aris/html/archivesspace/data/tmp/jetty-0.0.0.0-8080-frontend.war-_-any-/webapp/WEB-INF/config/boot.rb:10:in (root)' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:1:in (root)' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in require' from uri:classloader:/jruby/rack/rails/environment3.rb:23:in ' from launcher/launcher.rb:92:in start_server' from launcher/launcher.rb:168:in main' from launcher/launcher.rb:261:in `'

You're seeing this error because you use JRuby::Rack::ErrorApp::ShowStatus.

any help/hints/tips on how to get this moving forward?

@bobbi-SMR
Copy link
Member

Hi, Daniel,

We think there's a problem related to the new major version of Bundler that was released shortly after the New Year. If you would download our attempted fix from https://github.com/harvard-library/aspace-import-excel/archive/issue_46.zip , remove the current plugins/aspace-import-excel, and replacing it with the unzipped files (renaming, of course, to aspace-import-excel), run the initialize script, and try again, this hopefully will resolve the problem.

Sorry you're having trouble with this.

@danielsprouse
Copy link
Author

danielsprouse commented Jan 14, 2019 via email

@danielsprouse
Copy link
Author

danielsprouse commented Jan 14, 2019 via email

@danielsprouse
Copy link
Author

danielsprouse commented Jan 14, 2019 via email

@bobbi-SMR
Copy link
Member

Hi,

If you're on the archivesspace-users mailing list, you will already have seen that we don't know (yet) how to fix this problem; I'm sorry for the delay. It seems that the new Bundler release isn't Playing Well With Others, despite their original assurances. We're in touch with lyrasis about this, as a fix may need to "come from the top" (we suspect that initializing any plugin with a Gemfile will have this problem! :-(

I'm also marking this as a duplicate with #46 (#46 ), as this was previously reported by someone running Aspace under Windows.

@bobbi-SMR
Copy link
Member

Duplicate of #46

1 similar comment
@bobbi-SMR
Copy link
Member

Duplicate of #46

@danielsprouse
Copy link
Author

danielsprouse commented Jan 14, 2019 via email

@pobocks
Copy link
Member

pobocks commented Jan 14, 2019

I hate to be the bearer of bad news, but it's pretty unlikely that installing on an earlier version will work - the core problem is that the ASpace release was built in a world where 2.0.1 wasn't out yet, and anything we're doing now is built in a world where it is out.

The build system definitely needs rethinking and reworking. I think if you checked out ASpace 2.5.1 from github, and built it into a zip yourself, then installed the plugin in the resulting build, that should bypass this?

@Blake-
Copy link

Blake- commented Jan 14, 2019

How did you end up with bundler 2.0.1 ?

@pobocks
Copy link
Member

pobocks commented Jan 14, 2019

The initialize-plugin.bat|.sh bundle installs plugin gems.

@Blake-
Copy link

Blake- commented Jan 14, 2019

Running ./scripts/initialize-plugin.sh aspace-import-excel (ArchivesSpace 2.5.2RC) gives me Successfully installed bundler-1.16.1 on Ubuntu 18. That gives you bundler 2 on RHEL?

@pobocks
Copy link
Member

pobocks commented Jan 14, 2019

Windows and OSX so far, on 2.5.1 release.

@pobocks
Copy link
Member

pobocks commented Jan 14, 2019

Though I'm still seeing a problem with a version where I altered initialize-plugin.bat to do

gem install bundler -v1.17.1
bundle _1.17.1_ install

so it's clear that something else hinky is going on.

@lorawoodford
Copy link

lorawoodford commented Jan 14, 2019 via email

@pobocks
Copy link
Member

pobocks commented Jan 14, 2019

Are you doing this from a zip release or one you built yourself at some point?

@Blake-
Copy link

Blake- commented Jan 14, 2019

zip for me

@lorawoodford
Copy link

zips for both the 2.5.1 release and 2.5.2RC. Also just gave it a whirl on the only previously aspace-unaware machine I've got here - an '08 MacBook native booting Ubuntu - and still cannot replicate the issue. initialize-plugin.sh still respects bundler 1.16, even though when I installed ruby/bundler on the system it got 2.0.1.

@bobbi-SMR
Copy link
Member

Laura, can you run archivesspace after you've initialized it? The original issue was that it seemed to be initialized, but re-starting archivesspace presented a problem.

@lorawoodford
Copy link

lorawoodford commented Jan 14, 2019 via email

@pobocks
Copy link
Member

pobocks commented Jan 15, 2019

Hmmm. I may have actually mis-remembered whether I replicated on OSX; but we've got Daniel on RHEL and Windows on multiple machines.

@bobbi-SMR
Copy link
Member

Laura, can you run archivesspace after you've initialized it? The original issue was that it seemed to be initialized, but re-starting archivesspace presented a problem.

@danielsprouse
Copy link
Author

Over the coming weekend I will be testing it on Centos7 minimal install, and CentOS7 developer install, and I will be testing migrating back to 2.4.x, installing the plugin, and re-migrate forward to 2.5.x.
I'll post here whatever happens.

@danielsprouse
Copy link
Author

also, want to point out that I have tried to install the plugin with current ( 3.0.2 ) and previous ( 2.7.0 ) versions of gem and with bundler 1.16.1 set as the default version of bundler, and both using sudo and as root, still get the same errors.

@danielsprouse
Copy link
Author

thought I had it this time, no cigar...

[dsprouse@tslac4avned plugins]$ sudo ../scripts/initialize-plugin2.sh aspace-import-excel
Successfully installed bundler-1.16.1
1 gem installed
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and
installing your bundle as root will break this application for all non-root
users on this machine.
Fetching gem metadata from http://rubygems.org/........
Using bundler 1.16.1
Fetching coderay 1.1.1
Installing coderay 1.1.1
Fetching ffi 1.9.17 (java)
Installing ffi 1.9.17 (java)
Fetching method_source 0.8.2
Installing method_source 0.8.2
Fetching nokogiri 1.7.0.1 (java)
Installing nokogiri 1.7.0.1 (java)
Fetching slop 3.6.0
Installing slop 3.6.0
Fetching spoon 0.0.6
Installing spoon 0.0.6
Fetching pry 0.10.4 (java)
Installing pry 0.10.4 (java)
Fetching rubyzip 1.0.0
Installing rubyzip 1.0.0
Fetching rubyXL 3.1.0
Installing rubyXL 3.1.0
Bundle complete! 3 Gemfile dependencies, 10 gems now installed.
Use bundle info [gemname] to see where a bundled gem is installed.

=====================================

=====================================

got this error in archivesspace.out:
[!] There was an error parsing Gemfile: You cannot specify the same gem twice with different version requirements.
You specified: rubyzip (~> 1.2.2) and rubyzip (= 1.0.0). Bundler cannot continue.

from /var/www/aris/html/archivesspace/data/tmp/jetty-0.0.0.0-8089-backend.war-_-any-/webapp/WEB-INF/Gemfile:60

-------------------------------------------

require 'asutils'

> ASUtils.load_plugin_gems(self)

-------------------------------------------

from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;dsl.rb:110:in `gem&#x27;
from (eval):6:in `&lt;eval&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyBasicObject.java:1693:in `instance_eval&#x27;
from uri:classloader:&#x2F;asutils.rb:245:in `block in load_plugin_gems&#x27;
from org&#x2F;jruby&#x2F;RubyArray.java:1734:in `each&#x27;
from uri:classloader:&#x2F;asutils.rb:241:in `load_plugin_gems&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;Gemfile:60:in `&lt;eval&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyBasicObject.java:1705:in `instance_eval&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;dsl.rb:47:in `eval_gemfile&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;dsl.rb:12:in `evaluate&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;definition.rb:35:in `build&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler.rb:135:in `definition&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler.rb:101:in `setup&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;setup.rb:20:in `&lt;main&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyKernel.java:961:in `require&#x27;
from uri:classloader:&#x2F;META-INF&#x2F;jruby.home&#x2F;lib&#x2F;ruby&#x2F;stdlib&#x2F;rubygems&#x2F;core_ext&#x2F;kernel_require.rb:133:in `require&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;app&#x2F;main.rb:1:in `&lt;main&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyKernel.java:961:in `require&#x27;
from uri:classloader:&#x2F;META-INF&#x2F;jruby.home&#x2F;lib&#x2F;ruby&#x2F;stdlib&#x2F;rubygems&#x2F;core_ext&#x2F;kernel_require.rb:55:in `require&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;app&#x2F;main.rb:1:in `block in (root)&#x27;
from org&#x2F;jruby&#x2F;RubyBasicObject.java:1687:in `instance_eval&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;config.ru:1:in `(root)&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;config.ru:4:in `&lt;main&gt;&#x27;
from launcher&#x2F;launcher.rb:92:in `start_server&#x27;
from launcher&#x2F;launcher.rb:157:in `main&#x27;
from launcher&#x2F;launcher.rb:261:in `&lt;main&gt;&#x27;

You're seeing this error because you use JRuby::Rack::ErrorApp::ShowStatus.

). Retrying... tail: archivesspace.out: file truncated

=====================================

=====================================

environment:
[root@tslac4avned ~]# ruby -v; gem -v; gem info bundler; cat /var/www/aris/html/archivesspace/scripts/initialize-plugin2.sh
ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-linux]
3.0.2

*** LOCAL GEMS ***

bundler (2.0.1, 1.17.3, 1.17.2, 1.16.1, 1.12.5)
Authors: André Arko, Samuel Giddins, Colby Swandale, Hiroshi
Shibata, David Rodríguez, Grey Baker, Stephanie Morillo, Chris
Morris, James Wen, Tim Moore, André Medeiros, Jessica Lynn Suttles,
Terence Lee, Carl Lerche, Yehuda Katz
Homepage: http://bundler.io
License: MIT
Installed at (2.0.1): /usr/local/lib/ruby/gems/2.5.0
(1.17.3): /usr/local/lib/ruby/gems/2.5.0
(1.17.2): /usr/local/lib/ruby/gems/2.5.0
(1.16.1, default): /usr/local/lib/ruby/gems/2.5.0
(1.12.5): /usr/local/lib/ruby/gems/2.5.0

The best way to manage your application's dependencies

#!/bin/bash

plugin="$1"

We'll provide our own values for these

unset GEM_HOME
unset GEM_PATH

export ASPACE_LAUNCHER_BASE="$("dirname $0"/find-base.sh)"

cd "$ASPACE_LAUNCHER_BASE/gems/gems"
BUNDLER_VERSION=$(ls | grep bundler | cut -d'-' -f 2)

cd "$ASPACE_LAUNCHER_BASE/plugins/$plugin"

if [ "$plugin" = "" ]; then
echo "Usage: $0 "
exit
fi

if [ "$?" != "0" ]; then
echo "Failed to find plugin: $plugin"
exit
fi

export JRUBY=
for dir in ../../gems/gems/jruby-; do
JRUBY="$JRUBY:$dir/lib/
"
done

export GEM_HOME=gems

gem info bundler to get version, the original line breaks with "malformed expression" error

#java $JAVA_OPTS -cp "../../lib/$JRUBY" org.jruby.Main -S gem install bundler -v "$BUNDLER_VERSION"
java $JAVA_OPTS -cp "../../lib/
$JRUBY" org.jruby.Main -S gem install bundler -v 1.16.1
java $JAVA_OPTS -cp "../../lib/*$JRUBY" org.jruby.Main ../../gems/bin/bundle install --gemfile=Gemfile

@bobbi-SMR
Copy link
Member

Hi, Daniel,

It's clear that, while your presenting problem, like #46 , was due to the bundler version upgrade, it seems that you have at least one other problem: the initialize-plugin.sh script provided in the core code should not be breaking. I'm tagging @lorawoodford and @lmcglohon on that problem.

That said, when I saw the version collision error message, it was strangely familiar, and I remembered why we hadn't included the Gemfile.lock in our repo: it was to avoid this collision, for which I have no explanation.

I've created Yet Another Branch (sorry), which doesn't include Gemfile.lock. I suggest that, for your initialize-plugin2.sh, you first see what version of the bundler is at

archivesspace/gems/gems/bundler-*

and use that for your explicit bundler, then try again with the zipfile of this branch: issue_47 .

I'm sorry for how frustrating this is.

@danielsprouse
Copy link
Author

danielsprouse commented Jan 17, 2019 via email

@Blake-
Copy link

Blake- commented Jan 18, 2019

Why are you sudoing things?

sudo ../scripts/initialize-plugin2.sh aspace-import-excel

I'm not sure you should be doing anything with sudo maybe that's messing up permissions? If something ends up owned by root or some other user or not executable that might cause troubles. I think everything should be find owned by your regular user.

@Blake-
Copy link

Blake- commented Jan 18, 2019

also, just noticed, sudo ../scripts/initialize-plugin2.sh aspace-import-excel why is that path ../ instead of just ./ that seems wrong maybe? I think you'd want to run that in the ArchivesSpace directory.

@danielsprouse
Copy link
Author

first of all, when you run the initialize script it gives you a warning not to run it as root, if you don't use sudo you don't have permissions to modify the directories, so that isn't a thing.
Successfully installed bundler-1.16.1
1 gem installed
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and
installing your bundle as root will break this application for all non-root
users on this machine.
and if you provide the right location, relative or absolute, for the initialize-plugin.sh and the name only for the plugin, that's all that matters, it finds it. It only gives errors if you try to give a pathname/name combination for the argument to the script, which is in this case aspace-import-excel. thanks.

@Blake-
Copy link

Blake- commented Jan 18, 2019

It works fine without sudo for me, I see that warning too. I think maybe it's just a warning and not a fatal error?

@danielsprouse
Copy link
Author

I have run it as root several times, it isn't the issue.
There are problems with the $BUNDLER_VERSION variable in initialize-plugin.sh, which isn't prepared for being coerced into an array, it gives a malformed expression upon finding multiple bundler versions and makes no effort to pick the default version.
ERROR: While executing gem ... (Gem::Requirement::BadRequirementError)
Illformed requirement ["1.12.5\n1.16.1"]
Gem::GemNotFoundException: can't find gem bundler (>= 0.a)
find_spec_for_exe at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems.rb:271
activate_bin_path at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems.rb:298

at ../../gems/bin/bundle:23
I forced it to use one, and then after it is forced to use a specific version, the Gemfile.lock generated reports back with the wrong bundler version. It is actually reporting back a version that doesn't even seem to exist on my machine
BUNDLED WITH
1.12.5

@danielsprouse
Copy link
Author

also, the plugin may want to include (in the installation instructions) to remove the Gemfile.lock each time if circumstances force you to make multiple attempts at the installation of the plugin.

@bobbi-SMR
Copy link
Member

Hi, Daniel,

Good point about the Gemfile.lock removal, although I tend (and suggest to others) to either delete the entire tree (or rename it), and unzip again, to make sure that there aren't other subtle issues.

Do you now have a clean install? or are you still thrashing?

@danielsprouse
Copy link
Author

danielsprouse commented Jan 18, 2019 via email

@Blake-
Copy link

Blake- commented Jan 18, 2019

I just did this on centos7, no issues. The only part I didn't do was MySQL. I don't think that would matter in this case.

docker run -d -p 8080:80 -p 8443:443 -p 8022:22 -t otherdata/centos-docker-lamp:latest
docker exec -it hopeful_hamilton bash

as root:
    1  useradd blake
    2  yum install java
    3  su blake

su blake:
    1  wget https://github.com/archivesspace/archivesspace/releases/download/v2.5.2/archivesspace-v2.5.2.zip
    2  unzip archivesspace-v2.5.2.zip 
    3  cd archivesspace
    4  cd plugins/
    5  wget https://github.com/harvard-library/aspace-import-excel/archive/v2.1.18.zip
    6  unzip v2.1.18.zip 
    7  mv aspace-import-excel-2.1.18/ aspace-import-excel
    8  ./scripts/initialize-plugin.sh aspace-import-excel
    9  ./archivesspace.sh start
   10  grep -i error logs/archivesspace.out 


No errors when initializing plugin:

./scripts/initialize-plugin.sh aspace-import-excel
Fetching: bundler-1.16.1.gem (100%)
Successfully installed bundler-1.16.1
1 gem installed
Fetching gem metadata from http://rubygems.org/..............
Resolving dependencies...
Using bundler 1.16.1
Fetching nokogiri 1.10.1 (java)
Installing nokogiri 1.10.1 (java)
Fetching rubyzip 1.2.2
Installing rubyzip 1.2.2
Fetching rubyXL 3.3.29
Installing rubyXL 3.3.29
Bundle complete! 1 Gemfile dependency, 4 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.

@danielsprouse
Copy link
Author

and I got this again anyway. I get this every time, so I think that another part of the plugin or another gem entirely is trying to use two versions of rubyzip.
my current Gemfile and .lock look like this:
[root@tslac4avned aspace-import-excel]# cat Gemfile
ASpaceGems.setup if defined? ASpaceGems

source 'http://rubygems.org'

gem 'rubyXL', "3.1.0", :require => false
gem 'rubyzip', "1.0.0", :require => false
gem 'pry'
[root@tslac4avned aspace-import-excel]# cat Gemfile.lock
GEM
remote: http://rubygems.org/
specs:
coderay (1.1.2)
ffi (1.10.0-java)
method_source (0.9.2)
nokogiri (1.10.1-java)
pry (0.12.2-java)
coderay (> 1.1.0)
method_source (
> 0.9.0)
spoon (~> 0.0)
rubyXL (3.1.0)
nokogiri (>= 1.4.4)
rubyzip (>= 1.0.0)
rubyzip (1.0.0)
spoon (0.0.6)
ffi

PLATFORMS
java

DEPENDENCIES
pry
rubyXL (= 3.1.0)
rubyzip (= 1.0.0)

BUNDLED WITH
1.16.1
[root@tslac4avned aspace-import-excel]#

and, as usual when trying to install the pplugin, I get this when I try to start archivesspace:
[!] There was an error parsing Gemfile: You cannot specify the same gem twice with different version requirements.
You specified: rubyzip (~> 1.2.2) and rubyzip (= 1.0.0). Bundler cannot continue.

from /var/www/aris/html/archivesspace/data/tmp/jetty-0.0.0.0-8089-backend.war-_-any-/webapp/WEB-INF/Gemfile:60

-------------------------------------------

require 'asutils'

> ASUtils.load_plugin_gems(self)

-------------------------------------------

from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;dsl.rb:110:in `gem&#x27;
from (eval):6:in `&lt;eval&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyBasicObject.java:1693:in `instance_eval&#x27;
from uri:classloader:&#x2F;asutils.rb:245:in `block in load_plugin_gems&#x27;
from org&#x2F;jruby&#x2F;RubyArray.java:1734:in `each&#x27;
from uri:classloader:&#x2F;asutils.rb:241:in `load_plugin_gems&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;Gemfile:60:in `&lt;eval&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyBasicObject.java:1705:in `instance_eval&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;dsl.rb:47:in `eval_gemfile&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;dsl.rb:12:in `evaluate&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;definition.rb:35:in `build&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler.rb:135:in `definition&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler.rb:101:in `setup&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;gems&#x2F;gems&#x2F;bundler-1.16.1&#x2F;lib&#x2F;bundler&#x2F;setup.rb:20:in `&lt;main&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyKernel.java:961:in `require&#x27;
from uri:classloader:&#x2F;META-INF&#x2F;jruby.home&#x2F;lib&#x2F;ruby&#x2F;stdlib&#x2F;rubygems&#x2F;core_ext&#x2F;kernel_require.rb:133:in `require&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;app&#x2F;main.rb:1:in `&lt;main&gt;&#x27;
from org&#x2F;jruby&#x2F;RubyKernel.java:961:in `require&#x27;
from uri:classloader:&#x2F;META-INF&#x2F;jruby.home&#x2F;lib&#x2F;ruby&#x2F;stdlib&#x2F;rubygems&#x2F;core_ext&#x2F;kernel_require.rb:55:in `require&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;app&#x2F;main.rb:1:in `block in (root)&#x27;
from org&#x2F;jruby&#x2F;RubyBasicObject.java:1687:in `instance_eval&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;config.ru:1:in `(root)&#x27;
from &#x2F;var&#x2F;www&#x2F;aris&#x2F;html&#x2F;archivesspace&#x2F;data&#x2F;tmp&#x2F;jetty-0.0.0.0-8089-backend.war-_-any-&#x2F;webapp&#x2F;WEB-INF&#x2F;config.ru:4:in `&lt;main&gt;&#x27;
from launcher&#x2F;launcher.rb:92:in `start_server&#x27;
from launcher&#x2F;launcher.rb:157:in `main&#x27;
from launcher&#x2F;launcher.rb:261:in `&lt;main&gt;&#x27;

You're seeing this error because you use JRuby::Rack::ErrorApp::ShowStatus.

). Retrying...

@danielsprouse
Copy link
Author

this is the only occurrence of the string "rubyzip 1.2.2" anywhre in the aspace-import-excel directory:
[root@tslac4avned aspace-import-excel]# grep -R -e "rubyzip 1.2.2" ./*
./gems/specifications/rubyzip-1.2.2.gemspec:# stub: rubyzip 1.2.2 ruby lib

@danielsprouse
Copy link
Author

danielsprouse commented Jan 18, 2019 via email

@Blake-
Copy link

Blake- commented Jan 18, 2019

Running it in a container shouldn't matter at all, but just in case, I spun up a full virtualbox centos vm and followed the same steps I did in the docker container, with the same results. ArchivesSpace started with the plugin enable with no issues. The only thing I did as root was installing java, I didn't sudo anything.

@bobbi-SMR
Copy link
Member

Hi, Daniel,

I'm sorry; I've been away for a while. I just noticed that the Gemfile you cat'd above is way out of date!

This is what you should be seeing :

ASpaceGems.setup if defined? ASpaceGems

source 'http://rubygems.org'

gem 'rubyXL', "3.3.29", :require => false

Remind me which release you're trying to implement? For any version of Aspace 2.22 or higher,, you should be using aspace-import-excel V2.1.18

@Blake-
Copy link

Blake- commented Jan 29, 2019

Hi all, just wondering how this was going? Did you figure it out?

@danielsprouse
Copy link
Author

danielsprouse commented Jan 31, 2019 via email

@Blake-
Copy link

Blake- commented Feb 28, 2019

Hi all, just wondering how this was going? Did you figure it out?

@danielsprouse
Copy link
Author

danielsprouse commented Feb 28, 2019 via email

@Blake-
Copy link

Blake- commented Apr 26, 2019

Hi all, just wondering how this was going? Did you figure it out?

@TheSupportGuy
Copy link

Hello, was this issue resolved? What was done to fix the issue? I'm running into the same issue on a Windows Server

@danielsprouse
Copy link
Author

danielsprouse commented Apr 30, 2021 via email

@danielsprouse
Copy link
Author

danielsprouse commented Apr 30, 2021 via email

@TheSupportGuy
Copy link

Hello, thank you for your replies. We are running ArchivesSpace v2.8.1, aspace-import-excel plugin v3.0.3, and mysql 8.0.24 (which is currently the latest build). Windows server is 2019, fresh install with Java jre1.8.0_291 which was also recently downloaded. The software works fine until I uncomment the line in the cofig.rb (AppConfig[:plugins] = ['aspace-import-excel'] ) for this plugin and then it just refuses to load the admin panel (port 8080) but it does load the public site (port 8081).

@danielsprouse
Copy link
Author

danielsprouse commented May 3, 2021 via email

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

No branches or pull requests

6 participants