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

Internal Error on Redmine 2.6 #66

Closed
abertolli opened this issue Apr 29, 2016 · 6 comments
Closed

Internal Error on Redmine 2.6 #66

abertolli opened this issue Apr 29, 2016 · 6 comments
Assignees

Comments

@abertolli
Copy link

I am trying to install this plugin on Redmine 2.6 and I have tried plugin version 0.1.1 and 0.1.0. After migrating the plugin, and restarting apache I get the following error (my settings require login):

ActionView::Template::Error (Missing partial banner/project_body_bottom with {:locale=>[:en], :formats=>[:html], :handlers=>[:erb, :builder, :rsb]}. Searched in:
  * "/var/www/redmine-2.6.0/app/views"
):
    56:         <%= view_layouts_base_sidebar_hook_response %>
    57:     </div>
    58:
    59:     <div id="content">
    60:         <%= render_flash_messages %>
    61:         <%= yield %>
    62:         <%= call_hook :view_layouts_base_content %>
  lib/redmine/hook.rb:61:in `block (2 levels) in call_hook'
  lib/redmine/hook.rb:61:in `each'
  lib/redmine/hook.rb:61:in `block in call_hook'
  lib/redmine/hook.rb:58:in `tap'
  lib/redmine/hook.rb:58:in `call_hook'
  lib/redmine/hook.rb:158:in `call_hook'
  app/views/layouts/base.html.erb:59:in `_app_views_layouts_base_html_erb__2916634008638019023_17558600'
  app/controllers/application_controller.rb:465:in `block (2 levels) in render_error'
  app/controllers/application_controller.rb:463:in `render_error'
  app/controllers/application_controller.rb:451:in `render_404'
  app/controllers/application_controller.rb:475:in `missing_template'

@akiko-pusu
Copy link
Owner

Hi, @abertolli
Thank you so much your trying to use my plugin, and sorry for my delayed reply.

I've just confirmed that plugin works fine in my clean sandbox with Remine 2.6.10 and Redmine Banner 0.1.1.
So, could you please confirm your plugin directory.

  • Copy the plugin directory into the $REDMINE_ROOT/plugins directory.
  • Please note that plugin's folder name should be "redmine_banner".
  • If directory name was changed or different, some migration task will be failed.
  • If directory name is correctly, please re-run rake redmine:plugins:migrate RAILS_ENV=production

E.g. $REDMINE_ROOT/plugins/redmine_banner
Following is my Redmine's directory tree.

$ tree -L 2
.
├── CONTRIBUTING.md
├── Gemfile
├── Gemfile.lock
├── README.rdoc
├── Rakefile
├── app
│   ├── controllers
│   ├── helpers
│   ├── models
│   ├── sweepers
│   └── views
├── config
│   ├── additional_environment.rb.example
│    .... Snip ....
│   ├── routes.rb
│   └── settings.yml
├── config.ru
├── db
│   ├── development.sqlite3
│   ├── migrate
│   └── schema.rb
├── extra
│   ├── mail_handler
│   ├── sample_plugin
│   └── svn
├── log
│   ├── delete.me
│   └── development.log
├── plugins
│   ├── README
│   └── redmine_banner <- Here!
├── public
│   ├── 404.html
│   ├── 500.html
│   ├── dispatch.fcgi.example
│   ├── favicon.ico
 ...........

@akiko-pusu akiko-pusu self-assigned this May 3, 2016
@abertolli
Copy link
Author

abertolli commented May 4, 2016

Thanks. After you replied, I immediately knew what the problem was: the package unpacks as redmine_banner- and you said make sure it only says redmine_banner.

I apologize if this is standard practice for Redmine--I do not expect that the plugin folder name will make a difference.

It seems to work after updating the folder name.

@akiko-pusu
Copy link
Owner

@abertolli , I'm glad the issue has been resolved.
If you need anything else, please let me know ;)

@akiko-pusu akiko-pusu mentioned this issue May 5, 2016
@abertolli
Copy link
Author

I actually have another issue that I will submit later: loos like the banner for individual projects produces an error when over 255 characters long. Not sure if it’s a problem with the plugin, or Redmine is not failing gracefully when it encounters a value that is bigger than expected.

On May 5, 2016, at 1:18 AM, Akiko Takano notifications@github.com wrote:

@abertolli https://github.com/abertolli , I'm glad the issue has been resolved.
If you need anything else, please let me know ;)


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub #66 (comment)

@akiko-pusu
Copy link
Owner

@abertolli
Type of description column for Project Banner is text, so that this should store more than 255 chars.
Could you please confirm your database schema and migration status?
Or please let me know which database you use. (Such as MySQL, PostgreSQL..)

Following is example with SQLite3.

sqlite> select * from schema_migrations where version like "%redmine_banner";
1-redmine_banner
2-redmine_banner
3-redmine_banner
4-redmine_banner
5-redmine_banner

sqlite> .schema banners
CREATE TABLE "banners" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "enabled" boolean, "style" varchar DEFAULT 'info' NOT NULL, "banner_description" text, "use_timer" boolean, "start_date" datetime, "end_date" datetime, "project_id" integer NOT NULL, "updated_on" datetime, "display_part" varchar DEFAULT 'all' NOT NULL);

If migration record of "5-redmine_banner “ does not exists, banner_description column type might be string, and type should be changed as text.

@abertolli
Copy link
Author

It has taken me some time to get back to this issue. Before going further, I upgraded from 0.1.0 to 0.1.1 and I noticed that the migrate task made that column as text. So it appears everything is working fine on 0.1.1

Thanks for responding and looking into it.

On May 5, 2016, at 5:13 PM, Akiko Takano notifications@github.com wrote:

@abertolli https://github.com/abertolli
Type of description column for Project Banner is text, so that this should store more than 255 chars.
Could you please confirm your database schema and migration status?
Or please let me know which database you use. (Such as MySQL, PostgreSQL..)

Following is example with SQLite3.

sqlite> select * from schema_migrations where version like "%redmine_banner";
1-redmine_banner
2-redmine_banner
3-redmine_banner
4-redmine_banner
5-redmine_banner

sqlite> .schema banners
CREATE TABLE "banners" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "enabled" boolean, "style" varchar DEFAULT 'info' NOT NULL, "banner_description" text, "use_timer" boolean, "start_date" datetime, "end_date" datetime, "project_id" integer NOT NULL, "updated_on" datetime, "display_part" varchar DEFAULT 'all' NOT NULL);
If migration record of "5-redmine_banner “ does not exists, banner_description column type might be string, and type should be changed as text.


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub #66 (comment)

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

2 participants