A
A
Andrei Vukolov2018-06-16 15:19:40
Ruby on Rails
Andrei Vukolov, 2018-06-16 15:19:40

GitLab: how to defeat Rails "uninitialized constant" error?

Good time dear colleagues! Starting GitLab from source on an Apache and SSL machine using relative paths. Everything is more or less configured, the system components start up and work, but when web pages are requested, an error occurs in production.log:

Started GET "/gitlab/api/v4/internal/check" for 127.0.0.1 at 2018-06-16 09:31:18 +0000
Started GET "/gitlab/users/sign_in" for <IP> at 2018-06-16 09:31:53 +0000
Processing by SessionsController#new as HTML
Completed 500 Internal Server Error in 14ms (ActiveRecord: 1.6ms)

ActionView::Template::Error (uninitialized constant ActionView::CompiledTemplates::EXPR_ARG):
    1: %ul.nav-links.new-session-tabs.nav-tabs.nav{ role: 'tablist' }
    2:   %li.nav-item{ role: 'presentation' }
    3:     %a.nav-link.active{ href: '#login-pane', data: { toggle: 'tab' }, role: 'tab' } Sign in
    4:   - if allow_signup?
  app/views/devise/shared/_tabs_normal.html.haml:1:in `_app_views_devise_shared__tabs_normal_html_haml___3183421741055724100_47281175216580'
  app/views/devise/sessions/new.html.haml:7:in `_app_views_devise_sessions_new_html_haml__998010156118485515_47281178420240'
  app/controllers/sessions_controller.rb:22:in `new'
  lib/gitlab/i18n.rb:50:in `with_locale'
  lib/gitlab/i18n.rb:56:in `with_user_locale'
  app/controllers/application_controller.rb:362:in `set_locale'
  lib/gitlab/middleware/multipart.rb:95:in `call'
  lib/gitlab/request_profiler/middleware.rb:14:in `call'
  lib/gitlab/middleware/go.rb:17:in `call'
  lib/gitlab/etag_caching/middleware.rb:11:in `call'
  lib/gitlab/middleware/read_only/controller.rb:28:in `call'
  lib/gitlab/middleware/read_only.rb:16:in `call'
  lib/gitlab/request_context.rb:18:in `call'
  lib/gitlab/metrics/requests_rack_middleware.rb:27:in `call'
  lib/gitlab/middleware/release_env.rb:10:in `call'

I don't know Ruby, so I can't check the code. StackOverflow says that the Rails library is throwing the error.
Who faced? How can you win?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
B
blackst0ne, 2018-06-16
@twdragon

GitLab does not yet support Ruby 2.5.
Use 2.4.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question