HugoHasenbein / redmine_project_themes

Redmine plugin for provides project specific themes
https://www.redmine.org/plugins/redmine_project_theme
GNU General Public License v2.0
7 stars 3 forks source link

Project not accessable after installing/uninstalling redmine_project_themes #6

Closed teatower closed 3 years ago

teatower commented 4 years ago

--edit: Although I was able to access my projects again (foolish me: the plugin folder was not removed), I would really like to use this plugin. The error-logs reads very similar when having installed it. Maybe you have an idea for me. Thank you!

Hello Stephan, thank's for taking the effort for developing and maintaining this plugin. I installed the plugin as described with RM 4.1 and Ruby 5.2, found it in the project administration, activated the plugin there (Haken setzen) and from there on the project was not accessable. I did this with another project. I could not use the solution statet in another issues that is in the list, because I was not sure to know what to to with the hints given there. I re-migrated successfully, but still I can not access the projects.

Production log: Completed 500 Internal Server Error in 51ms (ActiveRecord: 10.0ms)

ActionView::Template::Error (undefined method `ui_theme' for # Did you mean? theme): 8: 9: 10: <%= csrf_meta_tag %> 11: <%= favicon %> 12: <%= stylesheet_link_tag 'jquery/jquery-ui-1.11.0', 'tribute-3.7.3', 'application', 'responsive', :media => 'all' %> 13: <%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %> 14: <%= javascript_heads %>

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:34:in current_theme' app/helpers/application_helper.rb:1625:infavicon_path' app/helpers/application_helper.rb:1620:in favicon' app/views/layouts/base.html.erb:11:in_app_views_layouts_base_html_erb___1899404938929478363_69993625473440' lib/redmine/sudo_mode.rb:65:in sudo_mode' plugins/redmine_dmsf/lib/redmine_dmsf/webdav/custom_middleware.rb:72:incall'

Could you please give me a hint where the problem might be. Or what tables could I manually change.

Thank you very much!

Tom

HugoHasenbein commented 4 years ago

Dear Tom,

which version of the plugin are you using? The file

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb

exists only for legacy reasons and in the current version should not be called at all.

You can find the version in init.rb or in redmine under administration->plugins. Current version is 1.1.1

Best regards

Stephan

Am 22.04.2020 um 14:32 schrieb teatower notifications@github.com:

Hello Stephan, thank's for taking the effort for developing and maintaining this plugin. I installed the plugin as described with RM 4.1 and Ruby 5.2, found it in the project administration, activated the plugin there (Haken setzen) and from there on the project was not accessable. I did this with another project. I could not use the solution statet in another issues that is in the list, because I was not sure to know what to to with the hints given there. I re-migrated successfully, but still I can not access the projects.

Production log: Completed 500 Internal Server Error in 51ms (ActiveRecord: 10.0ms)

ActionView::Template::Error (undefined method `ui_theme' for #Project:0x00005616690f3680 Did you mean? theme): 8: 9: 10: <%= csrf_meta_tag %> 11: <%= favicon %> 12: <%= stylesheet_link_tag 'jquery/jquery-ui-1.11.0', 'tribute-3.7.3', 'application', 'responsive', :media => 'all' %> 13: <%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %> 14: <%= javascript_heads %>

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:34:in current_theme' app/helpers/application_helper.rb:1625:in favicon_path' app/helpers/application_helper.rb:1620:in favicon' app/views/layouts/base.html.erb:11:in _app_views_layouts_base_html_erb___1899404938929478363_69993625473440' lib/redmine/sudo_mode.rb:65:in sudo_mode' plugins/redmine_dmsf/lib/redmine_dmsf/webdav/custom_middleware.rb:72:in call'

Could you please give me a hint where the problem might be. Or what tables could I manually change.

Thank you very much!

Tom

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/HugoHasenbein/redmine_project_themes/issues/6, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJWRDRGSQG6WP2BNTKHRL3LRN3PVPANCNFSM4MOEAB2A.

teatower commented 4 years ago

Hi Stephan! first of all: thank you for gettig back so quickly. I installed your plugin again, V 1.1.1 stright from github. Migrated with --trace to have a look at it ... looks good. Re-Start.... The projects I had activated during the first installation for this plugin are again not accessable. All other projects are.

Production Log: Completed 500 Internal Server Error in 58ms (ActiveRecord: 10.6ms)

ActionView::Template::Error (undefined method `ui_theme' for # Did you mean? theme): 8: 9: 10: <%= csrf_meta_tag %> 11: <%= favicon %> 12: <%= stylesheet_link_tag 'jquery/jquery-ui-1.11.0', 'tribute-3.7.3', 'application', 'responsive', :media => 'all' %> 13: <%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %> 14: <%= javascript_heads %>

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:34:in current_theme' app/helpers/application_helper.rb:1625:infavicon_path' app/helpers/application_helper.rb:1620:in favicon' app/views/layouts/base.html.erb:11:in_app_views_layouts_base_html_erb__2618060618663648677_70183173904600' lib/redmine/sudo_mode.rb:65:in sudo_mode' plugins/redmine_dmsf/lib/redmine_dmsf/webdav/custom_middleware.rb:72:incall'

Redmine version 4.1.0.stable Ruby version 2.5.5-p157 (2019-03-15) Rails version 5.2.4.1

It seems the forbidden file is still called, or am I misinterpreting?

If you might have the chance and will to have another look?

Vielen Dank ;-) Thank you.

Best regards, Tom

HugoHasenbein commented 4 years ago

Dear Tom,

this file is completely neglected by version 1.1.1, unless you have installed a newer version onto an older version and caused a version mismatch.

Please, try to manually delete

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:

if the plugin crashes after the deletion, then may be something wrong in your setup. The aformentioned file should not even be loaded by Rails

Best regards

Am 22.04.2020 um 15:03 schrieb teatower notifications@github.com:

ui_theme

teatower commented 4 years ago

Hello again, I renamed the file. Coming from Windows this usually does the job and is easy to revoke. Obviously not in Linux/Ruby/Rails environment. Deleted the file, as requested. De-Installed. Installed. Working! Thank you very much.

I hope you can enjoy the sunny day!

Tom

HugoHasenbein commented 4 years ago

excellent ! :-) enjoy, too !

Am 22.04.2020 um 16:19 schrieb teatower notifications@github.com:

Hello again, I renamed the file. Coming from Windows this usually does the job and is easy to revoke. Obviously not in Linux/Ruby/Rails environment. Deleted the file, as requested. De-Installed. Installed. Working! Thank you very much.

I hope you can enjoy the sunny day!

Tom

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/HugoHasenbein/redmine_project_themes/issues/6#issuecomment-617808086, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJWRDRC7PID53GKMJ7OHH3LRN34HVANCNFSM4MOEAB2A.

Leobq commented 3 years ago

Deleting "plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:" worked also in my case.

_Centos 8/Redmine 4.1.1/redmine_projectthemes 1.1.1/Ruby 2.5/Rails 5.2

Behaviour: After checking in myproject settings Project-Theme module I had this project page error: "An error occurred on the page you were trying to access. If you continue to experience problems please contact your Redmine administrator for assistance. If you are the Redmine administrator, check your log files for details about the error."

from /opt/redmine/redmine-4.1.1/log/production.log

Started GET "/projects/myproject" for 10.127.61.75 at 2021-05-13 16:12:25 +0200 Processing by ProjectsController#show as HTML Parameters: {"id"=>"myproject"} Current user: myuser (id=5) Rendering plugins/additionals/app/views/projects/show.html.slim within layouts/base Rendered plugins/additionals/app/views/dashboards/blocks/_project_information.html.slim (1.4ms) Rendered plugins/additionals/app/views/dashboards/blocks/_project_issues.html.slim (6.3ms) Unknown block "projecttimeentries" found in Project dashboard (id=2) Rendered projects/_members_box.html.erb (0.8ms) Rendered plugins/additionals/app/views/dashboards/blocks/_project_subprojects.html.slim (0.1ms) Rendered plugins/additionals/app/views/common/_dashboard.html.slim (28.9ms) Rendered plugins/additionals/app/views/projects/show.html.slim within layouts/base (32.7ms) Completed 500 Internal Server Error in 61ms (ActiveRecord: 11.6ms)

ActionView::Template::Error (undefined method `ui_theme' for # Did you mean? theme): 7: 8: = call_hook :view_dashboard_bottom, dashboard: dashboard, project: @project 9: 10: = context_menu 11: 12: / required for drap & drop work 13: / (this should always set, because to support new entries)

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:34:in current_theme' app/helpers/application_helper.rb:1539:inblock in stylesheet_link_tag' app/helpers/application_helper.rb:1536:in map' app/helpers/application_helper.rb:1536:instylesheet_link_tag' app/helpers/application_helper.rb:1485:in block in context_menu' app/helpers/application_helper.rb:1483:incontext_menu' plugins/additionals/app/views/common/_dashboard.html.slim:10:in _e28b5b52e05d66be0ab0c3e4d9a1cc6f' plugins/additionals/app/views/projects/show.html.slim:66:in_fcf6bc85e07be6ececa6bab29e4c04a6' lib/redmine/sudo_mode.rb:65:in `sudo_mode'

Bye, Leo

HugoHasenbein commented 3 years ago

Dear Leo,

did you migrate the plugin?

bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=redmine_project_themes Best regards

Stephan

Am 13.05.2021 um 16:58 schrieb Leonardo @.***>:

Deleting "plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:" worked also in my case.

Centos 8/Redmine 4.1.1/redmine_project_themes 1.1.1/Ruby 2.5/Rails 5.2

Behaviour: After checking in myproject settings Project-Theme module I had this project page error: "An error occurred on the page you were trying to access. If you continue to experience problems please contact your Redmine administrator for assistance. If you are the Redmine administrator, check your log files for details about the error."

from /opt/redmine/redmine-4.1.1/log/production.log

Started GET "/projects/myproject" for 10.127.61.75 at 2021-05-13 16:12:25 +0200 Processing by ProjectsController#show as HTML Parameters: {"id"=>"myproject"} Current user: myuser (id=5) Rendering plugins/additionals/app/views/projects/show.html.slim within layouts/base Rendered plugins/additionals/app/views/dashboards/blocks/_project_information.html.slim (1.4ms) Rendered plugins/additionals/app/views/dashboards/blocks/_project_issues.html.slim (6.3ms) Unknown block "projecttimeentries" found in Project dashboard (id=2) Rendered projects/_members_box.html.erb (0.8ms) Rendered plugins/additionals/app/views/dashboards/blocks/_project_subprojects.html.slim (0.1ms) Rendered plugins/additionals/app/views/common/_dashboard.html.slim (28.9ms) Rendered plugins/additionals/app/views/projects/show.html.slim within layouts/base (32.7ms) Completed 500 Internal Server Error in 61ms (ActiveRecord: 11.6ms)

ActionView::Template::Error (undefined method `ui_theme' for #Project:0x000055e363d8f3a0 Did you mean? theme): 7: 8: = call_hook :view_dashboard_bottom, dashboard: dashboard, project: @project https://github.com/project 9: 10: = context_menu 11: 12: / required for drap & drop work 13: / (this should always set, because to support new entries)

plugins/redmine_project_themes/lib/redmine_project_themes/patches/redmine_theme_patch.rb:34:in current_theme' app/helpers/application_helper.rb:1539:in block in stylesheet_link_tag' app/helpers/application_helper.rb:1536:in map' app/helpers/application_helper.rb:1536:in stylesheet_link_tag' app/helpers/application_helper.rb:1485:in block in context_menu' app/helpers/application_helper.rb:1483:in context_menu' plugins/additionals/app/views/common/_dashboard.html.slim:10:in _e28b5b52e05d66be0ab0c3e4d9a1cc6f' plugins/additionals/app/views/projects/show.html.slim:66:in _fcf6bc85e07be6ececa6bab29e4c04a6' lib/redmine/sudo_mode.rb:65:in `sudo_mode'

Bye, Leo

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/HugoHasenbein/redmine_project_themes/issues/6#issuecomment-840618677, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJWRDRET5WAIGLGNXHKJD6LTNPSJHANCNFSM4MOEAB2A.

Leobq commented 3 years ago

Hi Hugo, I followed the instruction from Install and Uninstall section: I did many tryes wandering if there was a misconfiguration in my system (after uninstallation, I was always able to enter project page). Bye, Leo

HugoHasenbein commented 3 years ago

bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=redmine_project_themes VERSION=0 bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=redmine_project_themes