caxlsx / caxlsx_rails

A Rails plugin to provide templates for the axlsx gem
MIT License
744 stars 84 forks source link

Unable to run rails server with gem: "already initialized constant APP_PATH" #45

Closed rdgco closed 9 years ago

rdgco commented 9 years ago

I added the axlsx_rails gem and installed in my project. If I run the rails server, I get the following error:

warning: already initialized constant APP_PATH ~/project/bin/rails:6: warning: previous definition of APP_PATH was here

I tried this with both rails 4.2.4 and 4.2.0. Here are the gem versions with using 4.2.0:

rdgco commented 9 years ago

Ok, shortly after posting this I read the nice README again, and discovered my problem. After setting the following gem versions and running bundle update for those gems in my gemfile, I'm able to run the server: gem 'rubyzip', '= 1.0.0' gem 'axlsx', '= 2.0.1' gem 'axlsx_rails'

straydogstudio commented 9 years ago

@rdgco Thanks for the feedback. Next time I get to work on the gem I'm hoping to hammer out the different gem version compatibilities. Not sure if I can do that as an automated test but I will try. At the very least I would like an error in the log or during bundle update if this is the case. I'm reluctant to lock the gem down to axlsx 2.0.x, but that may have to happen.