Top Menu

Jump to content
Home
    Modules
      • Projects
      • Activity
      • Work packages
      • Gantt charts
      • Calendars
      • Team planners
      • Boards
      • News
    • Getting started
    • Introduction video
      Welcome to OpenProject Community
      Get a quick overview of project management and team collaboration with OpenProject. You can restart this video from the help menu.

    • Help and support
    • Upgrade to Enterprise edition
    • User guides
    • Videos
    • Shortcuts
    • Community forum
    • Enterprise support

    • Additional resources
    • Data privacy and security policy
    • Digital accessibility (DE)
    • OpenProject website
    • Security alerts / Newsletter
    • OpenProject blog
    • Release notes
    • Report a bug
    • Development roadmap
    • Add and edit translations
    • API documentation
  • Sign in
      Forgot your password?

      or sign in with your existing account

      Google

Side Menu

  • Overview
  • Activity
    Activity
  • Roadmap
  • Work packages
    Work packages
  • Gantt charts
    Gantt charts
  • Calendars
    Calendars
  • Team planners
    Team planners
  • Boards
    Boards
  • News
  • Forums

Content

Plugins
  1. OpenProject
  2. Forums
  3. Plugins
  4. 500 Internal server error / css isn't precompiled

500 Internal server error / css isn't precompiled

Added by Nicola Tiling almost 11 years ago

The meeting and the global roles don’t work because theirs .css aren’t “precompiled”.

Started GET "/users/3/edit" for 192.168.4.94 at 2014-07-22 00:15:48 +0200
Processing by UsersController#edit as HTML
  Parameters: {"id"=>"3"}
  Rendered layouts/_action_menu_base.html.erb (0.1ms)
  Rendered layouts/_action_menu_specific.html.erb (0.4ms)
  Rendered users/_impaired_settings.html.erb (2.4ms)
  Rendered users/_mail_notifications.html.erb (7.9ms)
  Rendered users/_preferences.html.erb (6.9ms)
  Rendered users/_form.html.erb (33.0ms)
  Rendered users/_general.html.erb (37.2ms)
  Rendered users/_memberships.html.erb (13.4ms)
  Rendered /usr/local/lib/ruby/gems/2.1/bundler/gems/openproject-global_roles-2afc52cdc755/app/views/shared/_global_roles_header.html.erb (26.2ms)
  Rendered /usr/local/lib/ruby/gems/2.1/bundler/gems/openproject-global_roles-2afc52cdc755/app/views/users/_global_roles.html.erb (26.5ms)
  Rendered common/_tabs.html.erb (79.6ms)
  Rendered users/edit.html.erb within layouts/admin (93.3ms)
Completed 500 Internal Server Error in 105.4ms

ActionView::Template::Error (global_roles/global_roles.css isn't precompiled):
    19: ++#%>
    20:
    21: <% content_for :header_tags do %>
    22:         <%= stylesheet_link_tag 'global_roles/global_roles.css' %>
    23:         <%= javascript_include_tag 'global_roles/global_roles.js' %>
    24: <% end %>
  app/views/common/_tabs.html.erb:61:in `block in _app_views_common__tabs_html_erb__1018024196552026748_17319501080'
  app/views/common/_tabs.html.erb:60:in `each'
  app/views/common/_tabs.html.erb:60:in `_app_views_common__tabs_html_erb__1018024196552026748_17319501080'
  app/helpers/application_helper.rb:327:in `render_tabs'
  app/views/users/edit.html.erb:43:in `_app_views_users_edit_html_erb__561233729422719047_17372316600'

############################################################

Processing by MeetingsController#index as HTML
  Parameters: {"project_id"=>"test"}
  Rendered /usr/local/lib/ruby/gems/2.1/bundler/gems/openproject-meeting-fed782344428/app/views/shared/_meeting_header.html.erb (32.8ms)
  Rendered /usr/local/lib/ruby/gems/2.1/bundler/gems/openproject-meeting-fed782344428/app/views/meetings/index.html.erb within layouts/base (60.3ms)
Completed 500 Internal Server Error in 226.5ms

ActionView::Template::Error (meeting/meeting.css isn't precompiled):
    20: ++#%>
    21:
    22: <% content_for :header_tags do %>
    23:   <%= stylesheet_link_tag 'meeting/meeting.css' %>
    24: <% end %>

Replies (7)

RE: 500 Internal server error / css isn't precompiled - Added by Christian Ratz almost 11 years ago

Hello Nicola,

if you add or update a plugin you should always run the database migrations and you have to precompile the assets again.

RAILS_ENV=production bundle exec rake db:migrate
RAILS_ENV=production bundle exec rake assets:precompile

Than restart the server (Apache or nginx) and everything should work.

Best
Ratzi

RE: 500 Internal server error / css isn't precompiled / "jquery.ui.all" not found - Added by Nicola Tiling almost 11 years ago

Hi

Thanks a lot for the answer.
The precompile process is aborted bcause “jquery.ui.all” isn’t found :-(
How can I install this?

RAILS_ENV=production bundle exec rake assets:precompile --trace
require 'rails/all'... 0.953s
Bundler.require... 2.078s
** Invoke assets:precompile (first_time)
** Execute assets:precompile
/usr/local/bin/ruby21 /usr/local/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets --trace
require 'rails/all'... 0.938s
Bundler.require... 2.125s
** Invoke assets:precompile:all (first_time)
** Execute assets:precompile:all
** Invoke assets:precompile:primary (first_time)
** Invoke assets:environment (first_time)
** Execute assets:environment
** Invoke environment (first_time)
** Execute environment
Application.initialize!... [deprecated] I18n.enforce_available_locales will default to true in the future. If you really want to skip validation of your locale you can set I18n.enforce_available_locales = false to avoid this message.
3.680s
** Invoke tmp:cache:clear (first_time)
** Execute tmp:cache:clear
** Execute assets:precompile:primary
rake aborted!
Sprockets::FileNotFound: couldn't find file 'jquery.ui.all'
  (in /usr/local/openproject/app/assets/javascripts/application.js.erb:14)
/usr/local/lib/ruby/gems/2.1/gems/sprockets-2.12.1/lib/sprockets/context.rb:106:in `resolve'
/usr/local/lib/ruby/gems/2.1/gems/sprockets-2.12.1/lib/sprockets/context.rb:146:in `require_asset'
...
/usr/local/lib/ruby/gems/2.1/gems/rake-10.3.2/lib/rake/application.rb:75:in `run'
/usr/local/lib/ruby/gems/2.1/gems/rake-10.3.2/bin/rake:33:in `<top (required)>'
/usr/local/bin/rake:23:in `load'
/usr/local/bin/rake:23:in `<main>'
Tasks: TOP => assets:precompile:primary
rake aborted!
Command failed with status (1): [/usr/local/bin/ruby21 /usr/local/bin/rake ...]
/usr/local/lib/ruby/gems/2.1/gems/rake-10.3.2/lib/rake/file_utils.rb:54:in `block in create_shell_runner'
...
/usr/local/lib/ruby/gems/2.1/gems/rake-10.3.2/bin/rake:33:in `<top (required)>'
/usr/local/bin/rake:23:in `load'
/usr/local/bin/rake:23:in `<main>'
Tasks: TOP => assets:precompile

RE: 500 Internal server error / css isn't precompiled - Added by Christian Ratz almost 11 years ago

Hello again,

which version of OpenProject you use?

Best
Ratzi

RE: 500 Internal server error / css isn't precompiled - Added by Nicola Tiling almost 11 years ago

Core Version
OpenProject 3.0.8 (PostgreSQL)
on FreeBSD 9.3

But there are a few “jquery.ui.all.” files underneath openproject/public/assets

RE: 500 Internal server error / css isn't precompiled - Added by Nicola Tiling almost 11 years ago

It seems there is a problem with the path where the precompile process looks for its files.
If I make a link

ln -s /usr/local/openproject/public/assets/jquery.ui.all.js  /usr/local/openproject/lib/assets/javascripts/

query.ui.all is found an the next file is missing:

rake aborted!
Sprockets::FileNotFound: couldn't find file 'jquery.ui.accordion'
  (in /usr/local/openproject/lib/assets/javascripts/jquery.ui.all.js:1)

RE: 500 Internal server error / css isn't precompiled - Added by Nicola Tiling almost 11 years ago

In “app/assets/javascripts/application.js.erb” two folders are referenced to find files:

lib/assets/javascripts and vendor/assets/javascripts,

But also on the opf github source they are nearly empty..

What to do?

// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// the compiled file.
//
// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD
// GO AFTER THE REQUIRES BELOW.
//
//= require jquery
//= require jquery.ui.all
//= require jquery-ui-i18n
//= require jquery.atwho
//= require jquery_ujs
//= require jquery_noconflict
//= require jquery.colorcontrast
//= require jquery.trap
//= require prototype
//= require effects
//= require dragdrop
//= require controls
//= require i18n
//= require i18n/translations
//= require select2
//= require top_menu
//= require action_menu
//= require openproject
//= require breadcrumb
//= require findDomElement
//= require context_menu
//= require jstoolbar
//= require ajaxappender
//= require settings
//= require modal
//= require keyboard_shortcuts
//= require top-shelf
//= require unsupported-browsers
//= require autocomplete_textareas
//= require_tree ./specific
//= require openproject_plugins
//= require versions

RE: 500 Internal server error / css isn't precompiled - Added by Nicola Tiling almost 11 years ago

I’ve copied all *.js files from openproject/public/assets/ to openproject/app/assets/javascript/ and the jquery.ui.all.css from openproject/public/assets/ to openproject/app/assets/stylesheets. Then it works.
But what is the reason the files are not found? should they be in “openproject/app/assets/…” or is the path “openproject/public/assets” not in the precompilation configuration?

  • (1 - 7/7)
Loading...