clear-code / redmine_full_text_search

Full text search for Redmine
MIT License
61 stars 24 forks source link

Error on Rails6 #97

Closed ryouma-nagare closed 2 years ago

ryouma-nagare commented 3 years ago

An error occurs when searching with RedMica and Redmine (trunk) in Rails6 environment. The situation does not change with either arrow-libs 2.0 / 3.0 / 4.0 There is no error in redmine 4.2 of Rails5.

Environment

Environment:
  Redmine version                4.2.1.devel.20978
  Ruby version                   2.6.3-p62 (2019-04-16) [x86_64-linux]
  Rails version                  6.1.3.1
  Environment                    production
  Database adapter               PostgreSQL
  Mailer queue                   ActiveJob::QueueAdapters::AsyncAdapter
  Mailer delivery                smtp
SCM:
  Subversion                     1.10.2
  Git                            2.27.0
  Filesystem                     
Redmine plugins:
  alm                            1.7.4
  full_text_search               1.0.4

production.log

ActionView::Template::Error (Invalid time offset value: "PT9H"):
    166:       </ul>
    167:     </div>
    168:     <dl id="search-results">
    169:       <% @result_set.each_with_index do |e, i| %>
    170:         <dt class="<%= e.event_type %> icon icon-<%= e.event_type %>">
    171:           <%= content_tag("span", e.project, :class => "project") unless @project == e.project %>
    172:           <%= link_to(e.event_highlighted_title,
kou commented 3 years ago

Could you also show backtrace?

ryouma-nagare commented 3 years ago

Paste additional logs

ActionView::Template::Error (Invalid time offset value: "PT9H"):
    166:       </ul>
    167:     </div>
    168:     <dl id="search-results">
    169:       <% @result_set.each_with_index do |e, i| %>
    170:         <dt class="<%= e.event_type %> icon icon-<%= e.event_type %>">
    171:           <%= content_tag("span", e.project, :class => "project") unless @project == e.project %>
    172:           <%= link_to(e.event_highlighted_title,

plugins/full_text_search/lib/full_text_search/pgroonga.rb:101:in `compute_time_offset'
plugins/full_text_search/lib/full_text_search/pgroonga.rb:30:in `time_offset'
plugins/full_text_search/lib/full_text_search/searcher.rb:304:in `block in records'
plugins/full_text_search/lib/full_text_search/searcher.rb:301:in `map'
plugins/full_text_search/lib/full_text_search/searcher.rb:301:in `records'
plugins/full_text_search/lib/full_text_search/searcher.rb:318:in `each'
plugins/full_text_search/app/views/search/index.html.erb:169:in `each_with_index'
plugins/full_text_search/app/views/search/index.html.erb:169
lib/redmine/sudo_mode.rb:61:in `sudo_mode'
kou commented 3 years ago

Thanks. We'll add support for Rails 6 eventually. We need to prepare GitHub Actions CI environment first.

kou commented 2 years ago

CI is green with Redmine 5.0: https://github.com/clear-code/redmine_full_text_search/actions/runs/2152048971

Does someone want to try the master with Redmine 5.0?

ryouma-nagare commented 2 years ago

Sorry for the late report. I have confirmed the operation with RedMica 2.0 (master) and Redmine (trunk)! I am extremely grateful!

image image