aces / cbrain

CBRAIN is a flexible Ruby on Rails framework for accessing and processing of large data on high-performance computing infrastructures.
GNU General Public License v3.0
71 stars 42 forks source link

An error message when starting console without intalling pluging #1445

Closed MontrealSergiy closed 3 days ago

MontrealSergiy commented 3 days ago

I am getting hirb error on the console start (both master and dev) after disabling plugins. Console works fine though (save BACs attribute_names and friends). Maybe then raise warning rather than error?

CBRAIN Rails Console Initialization starting
Current user is now: admin

Current project is now: (nil)

load error: /home/users/sboroday/cbrain/BrainPortal/config/console_rc/init_rc.rb

NoMethodError: undefined method `attribute_names' for BackgroundActivity:Class

Did you mean?  attr_internal

    /home/users/sboroday/cbrain/BrainPortal/config/console_rc/lib/wirble_hirb_looksee.rb:80:in `block in <top (required)>'

    /home/users/sboroday/cbrain/BrainPortal/config/console_rc/lib/wirble_hirb_looksee.rb:76:in `each'

    /home/users/sboroday/cbrain/BrainPortal/config/console_rc/lib/wirble_hirb_looksee.rb:76:in `<top (required)>'

    /home/users/sboroday/.rvmpath/ruby/2.7.0/gems/activesupport-5.0.7.2/lib/active_support/dependencies.rb:293:in `require'

to reproduce run

cd ~/cbrain/BrainPortal  # or other place of CBRAIN installation
rake cbrain:plugins:clean:all
rails console
prioux commented 3 days ago

Try to install the plugins at least? CBRAIN comes with internal plugins that are required. Run

rake cbrain:plugins:install:all

and then try the console again.

MontrealSergiy commented 3 days ago

that helps. BackgroundActivity is more of intrinsic feature than a plugin, so one may expect it to work without plugin installation procedure.

prioux commented 3 days ago

Some of the core functionality is provided as internal plugins. So running the script to install plugins is required at all times, even on a bare system that has no external plugins.