manageiq: LoadError Unable to autoload constant ManageIQ::Providers::Openstack
We are encountering this issue in the UI when trying to add new cloud provider (possibly on other screens as well)
How to reproduce
- link amazon provider plugin locally with this pr: https://github.com/ManageIQ/manageiq-providers-amazon/pull/580#event-2974868273
- link manage iq api plugin locally with this pr: https://github.com/ManageIQ/manageiq-api/pull/723
- in ui classic use this pr: https://github.com/ManageIQ/manageiq-ui-classic/pull/6402 and run
yarn,bin/webpack - start the server and navigate to
http://localhost:3000/ems_cloud/new
This error happens only after the first access to the page. After refreshing it’s usually OK
INFO -- : Completed 500 Internal Server Error in 1152ms (ActiveRecord: 0.0ms)
[----] F, [2020-01-28T10:06:31.576080 #9323:2abd8351d428] FATAL -- :
[----] F, [2020-01-28T10:06:31.576188 #9323:2abd8351d428] FATAL -- : LoadError (Unable to autoload constant ManageIQ::Providers::Openstack::StorageManager::CinderManager, expected /home/mmarosi/.rbenv/versions/2.5.3/lib/ruby/gems/2.5.0/bundler/gems/manageiq-providers-openstack-4481f21d2ebe/app/models/manageiq/providers/openstack/storage_manager/cinder_manager.rb to define it):
[----] F, [2020-01-28T10:06:31.576299 #9323:2abd8351d428] FATAL -- :
[----] F, [2020-01-28T10:06:31.576433 #9323:2abd8351d428] FATAL -- : activesupport (5.1.7) lib/active_support/dependencies.rb:512:in `load_missing_constant'
activesupport (5.1.7) lib/active_support/dependencies.rb:202:in `const_missing'
activesupport (5.1.7) lib/active_support/inflector/methods.rb:271:in `const_get'
activesupport (5.1.7) lib/active_support/inflector/methods.rb:271:in `block in constantize'
activesupport (5.1.7) lib/active_support/inflector/methods.rb:267:in `each'
activesupport (5.1.7) lib/active_support/inflector/methods.rb:267:in `inject'
activesupport (5.1.7) lib/active_support/inflector/methods.rb:267:in `constantize'
activesupport (5.1.7) lib/active_support/inflector/methods.rb:312:in `safe_constantize'
activesupport (5.1.7) lib/active_support/core_ext/string/inflections.rb:77:in `safe_constantize'
lib/extensions/descendant_loader.rb:235:in `load_subclasses'
lib/extensions/descendant_loader.rb:255:in `descendants'
app/models/ext_management_system.rb:21:in `leaf_subclasses'
app/models/ext_management_system.rb:43:in `supported_types_for_create'
/home/mmarosi/manageiq/manageiq-api/app/controllers/api/providers_controller.rb:148:in `providers_options'
/home/mmarosi/manageiq/manageiq-api/app/controllers/api/providers_controller.rb:93:in `options'
actionpack (5.1.7) lib/action_controller/metal/basic_implicit_render.rb:4:in `send_action'
actionpack (5.1.7) lib/abstract_controller/base.rb:186:in `process_action'
actionpack (5.1.7) lib/action_controller/metal/rendering.rb:30:in `process_action'
actionpack (5.1.7) lib/abstract_controller/callbacks.rb:20:in `block in process_action'
activesupport (5.1.7) lib/active_support/callbacks.rb:131:in `run_callbacks'
actionpack (5.1.7) lib/abstract_controller/callbacks.rb:19:in `process_action'
actionpack (5.1.7) lib/action_controller/metal/rescue.rb:20:in `process_action'
actionpack (5.1.7) lib/action_controller/metal/instrumentation.rb:32:in `block in process_action'
activesupport (5.1.7) lib/active_support/notifications.rb:166:in `block in instrument'
activesupport (5.1.7) lib/active_support/notifications/instrumenter.rb:21:in `instrument'
activesupport (5.1.7) lib/active_support/notifications.rb:166:in `instrument'
actionpack (5.1.7) lib/action_controller/metal/instrumentation.rb:30:in `process_action'
actionpack (5.1.7) lib/action_controller/metal/params_wrapper.rb:252:in `process_action'
activerecord (5.1.7) lib/active_record/railties/controller_runtime.rb:22:in `process_action'
actionpack (5.1.7) lib/abstract_controller/base.rb:124:in `process'
actionpack (5.1.7) lib/action_controller/metal.rb:189:in `dispatch'
actionpack (5.1.7) lib/action_controller/metal.rb:253:in `dispatch'
actionpack (5.1.7) lib/action_dispatch/routing/route_set.rb:49:in `dispatch'
actionpack (5.1.7) lib/action_dispatch/routing/route_set.rb:31:in `serve'
actionpack (5.1.7) lib/action_dispatch/journey/router.rb:50:in `block in serve'
actionpack (5.1.7) lib/action_dispatch/journey/router.rb:33:in `each'
actionpack (5.1.7) lib/action_dispatch/journey/router.rb:33:in `serve'
actionpack (5.1.7) lib/action_dispatch/routing/route_set.rb:844:in `call'
secure_headers (3.0.3) lib/secure_headers/middleware.rb:10:in `call'
lib/request_started_on_middleware.rb:12:in `call'
rack (2.1.1) lib/rack/etag.rb:27:in `call'
rack (2.1.1) lib/rack/conditional_get.rb:40:in `call'
rack (2.1.1) lib/rack/head.rb:14:in `call'
rack (2.1.1) lib/rack/session/abstract/id.rb:277:in `context'
rack (2.1.1) lib/rack/session/abstract/id.rb:271:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/cookies.rb:613:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/callbacks.rb:26:in `block in call'
activesupport (5.1.7) lib/active_support/callbacks.rb:97:in `run_callbacks'
actionpack (5.1.7) lib/action_dispatch/middleware/callbacks.rb:24:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/executor.rb:12:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/debug_exceptions.rb:59:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/show_exceptions.rb:31:in `call'
railties (5.1.7) lib/rails/rack/logger.rb:36:in `call_app'
railties (5.1.7) lib/rails/rack/logger.rb:26:in `call'
sprockets-rails (3.2.1) lib/sprockets/rails/quiet_assets.rb:13:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/remote_ip.rb:79:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/request_id.rb:25:in `call'
rack (2.1.1) lib/rack/method_override.rb:24:in `call'
rack (2.1.1) lib/rack/runtime.rb:24:in `call'
activesupport (5.1.7) lib/active_support/cache/strategy/local_cache_middleware.rb:27:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/executor.rb:12:in `call'
actionpack (5.1.7) lib/action_dispatch/middleware/static.rb:125:in `call'
rack (2.1.1) lib/rack/sendfile.rb:113:in `call'
railties (5.1.7) lib/rails/engine.rb:522:in `call'
puma (4.3.1) lib/puma/configuration.rb:228:in `call'
puma (4.3.1) lib/puma/server.rb:681:in `handle_request'
puma (4.3.1) lib/puma/server.rb:472:in `process_client'
puma (4.3.1) lib/puma/server.rb:328:in `block in run'
puma (4.3.1) lib/puma/thread_pool.rb:134:in `block in spawn_thread'
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 22 (19 by maintainers)
It does but it should be said anyway 😉
Ok @Hyperkid123 @skateman, can you try this change in the api? I tried it against master with the above minimized script and it worked. I don’t have time tonight to try it against your PRs with the patch below: