Skip to content
This repository has been archived by the owner on Dec 7, 2021. It is now read-only.

Gemfile of a project using the plugin #128

Open
jpboudreault opened this issue Sep 18, 2017 · 4 comments
Open

Gemfile of a project using the plugin #128

jpboudreault opened this issue Sep 18, 2017 · 4 comments

Comments

@jpboudreault
Copy link

I've been struggling to make the blog's app work with the plugin. Had to get the right Ruby and Rails version. Then had issues with the MySQL PK definition. Got an issue with mass-assign protected attributes and how I am facing issues with the repos controller.

Can you share the Gemfile of a project using hubstats? I suspect that my current issue is also related to the versions of plugins and getting a working example would help a lot.

If curious this is my current issue

RuntimeError (Called id for nil, which would mistakenly be 4 -- if you really wanted the id of nil, use object_id):
  hubstats (0.6.0) app/controllers/hubstats/repos_controller.rb:34:in `show'
  actionpack (3.2.22.5) lib/action_controller/metal/implicit_render.rb:4:in `send_action'
  actionpack (3.2.22.5) lib/abstract_controller/base.rb:167:in `process_action'
  actionpack (3.2.22.5) lib/action_controller/metal/rendering.rb:10:in `process_action'
  actionpack (3.2.22.5) lib/abstract_controller/callbacks.rb:18:in `block in process_action'
  activesupport (3.2.22.5) lib/active_support/callbacks.rb:425:in `_run__95072941065603249__process_action__3492069711977148877__callbacks'
  activesupport (3.2.22.5) lib/active_support/callbacks.rb:405:in `__run_callback'
  activesupport (3.2.22.5) lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
  activesupport (3.2.22.5) lib/active_support/callbacks.rb:81:in `run_callbacks'
  actionpack (3.2.22.5) lib/abstract_controller/callbacks.rb:17:in `process_action'
@elliott-beach
Copy link

elliott-beach commented Nov 4, 2017

Did you try to use the example project under test/dummy? That was very quick to set up for me.

Might be obvious, but the issue in your stack trace is caused @repo being null in show, not sure how to fix atm.

@emmahsax
Copy link
Contributor

emmahsax commented Dec 4, 2017

Here is the Gemfile of our application which uses Hubstats. Note that I removed some pieces of the code that contained secrets or private gems.

source 'https://rubygems.org'

gem 'rails', '~> 4.2.6'
gem 'mysql2', '~> 0.3.2'
gem 'puma'
gem 'jquery-rails'
gem 'okcomputer'
gem 'hubstats', '~> 0.11.0'
gem 'status_check', path: './engine_status_check'
gem 'bootstrap-datepicker-rails', '~> 1.5'
gem 'railties', '= 4.2.6'
gem 'actionpack', '= 4.2.6'
gem 'sprockets-rails', '~> 2.3.3'
gem 'typhoeus'
gem 'newrelic_rpm'
gem 'omniauth-github'
gem 'conflate-rails'
gem 'aws-sdk', '~> 2'
gem 'sport_ngin_aws_auditor', '~> 4.2.1'
gem 'elasticsearch', '~> 1.0'
gem 'whenever', :require => false
gem 'sidekiq'
gem 'sidekiq-limit_fetch'
gem 'lograge'
gem 'logstash-event'
gem 'rabl', '~> 0.13.1'
gem 'octokit', '~> 4.6.0'
gem 'responders', '~> 2.3.0'
gem 'chartkick'
gem 'local_time'
gem 'slack-notifier'
gem 'scribbler'
gem 'logstash_scribbler'

# Gems used only for assets and not required
# in production environments by default.
group :assets do
  gem 'coffee-rails'

  # See https://github.com/sstephenson/execjs#readme for more supported runtimes
  gem 'therubyracer', :platforms => :ruby

  gem 'uglifier', '>= 1.0.3'

  gem 'bootstrap-sass', '~> 3.2.0'
  gem 'sass-rails', '>= 3.2'
  gem 'autoprefixer-rails'

end

group :development do
  gem 'pry-nav'
  gem 'pry-stack_explorer'
  gem 'guard-rspec'
end

group :test, :development do
  gem 'pry-rails'
  gem 'rspec-rails', '~> 3.1'
  gem 'rspec-its'
  gem 'capybara'
  gem 'powder'
end

group :test do
  gem 'webmock'
end

# To use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.0.0'

# To use Jbuilder templates for JSON
# gem 'jbuilder'

# Use unicorn as the app server
# gem 'unicorn'

# Deploy with Capistrano
# gem 'capistrano'

# To use debugger
# gem 'debugger'

source 'https://rails-assets.org' do
  gem 'rails-assets-bootstrap-jasny'
  gem 'rails-assets-bootstrap-confirmation2'
end

@emmahsax
Copy link
Contributor

emmahsax commented Dec 4, 2017

It's possible that the mass-assign error has something to do with a new version of Rails or something. I've seen something familiar to that, but I don't remember what the solution or exact cause was.

@jpboudreault
Copy link
Author

jpboudreault commented Dec 5, 2017

Thank you @emmasax4

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

No branches or pull requests

3 participants