Project

General

Profile

Actions

Defect #38491

closed

Invalid scheme format: ' VP1'

Added by p w over 1 year ago. Updated over 1 year ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Custom fields
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Duplicate
Affected version:

Description

Hello,

Our redmine installation ran years without problems (~2000 tickets). Now we have two tickets that causes an "Internal Error" when we are trying to open it. The log shows:

I, [2023-04-13T09:17:40.591920 #18082]  INFO -- : [2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] Completed 500 Internal Server Error in 42ms (ActiveRecord: 6.4ms | Allocations: 27520)
F, [2023-04-13T09:17:40.592583 #18082] FATAL -- : [2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]   
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] ActionView::Template::Error (Invalid scheme format: ' VP1'):
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     75:     rows.right l(:label_spent_time), issue_spent_hours_details(@issue), :class => 'spent-time'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     76:   end
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     77: end %>
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     78: <%= render_half_width_custom_fields_rows(@issue) %>
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     79: <%= call_hook(:view_issues_show_details_bottom, :issue => @issue) %>
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     80: </div>
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]     81: 
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3]   
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:276:in `block in url_from_pattern'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:276:in `gsub!'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:276:in `url_from_pattern'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:254:in `block in formatted_value'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:252:in `map'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:252:in `formatted_value'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:401:in `formatted_value'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/field_format.rb:246:in `formatted_custom_value'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/application_helper.rb:300:in `format_object'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/custom_fields_helper.rb:167:in `show_value'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/custom_fields_helper.rb:156:in `custom_field_value_tag'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/issues_helper.rb:377:in `block (2 levels) in render_half_width_custom_fields_rows'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/issues_helper.rb:375:in `each'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/issues_helper.rb:375:in `each_with_index'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/issues_helper.rb:375:in `block in render_half_width_custom_fields_rows'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/issues_helper.rb:365:in `issue_fields_rows'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/helpers/issues_helper.rb:374:in `render_half_width_custom_fields_rows'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/views/issues/show.html.erb:78
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/controllers/issues_controller.rb:118:in `block (2 levels) in show'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] app/controllers/issues_controller.rb:110:in `show'
[2b0c6c5e-7b7e-4e4a-9ac5-f950eae812a3] lib/redmine/sudo_mode.rb:61:in `sudo_mode'

"VP1" is something that is frequentely entered into a certain custom field ("Order Reference" in German), followed by ":" (e.g. "VP1:45632535").

Is the space causing the problem?
It's important for us to know how to prevent the error in future and maybe you are able to fix the bug.

Environment:
  Redmine version                5.0.3.stable
  Ruby version                   2.5.5-p157 (2019-03-15) [x86_64-linux-gnu]
  Rails version                  6.1.7
  Environment                    production
  Database adapter               Mysql2
  Mailer queue                   ActiveJob::QueueAdapters::AsyncAdapter
  Mailer delivery                smtp
Redmine settings:
  Redmine theme                  Alternate
SCM:
  Filesystem                     
Redmine plugins:
  redmine_dashboard              2.12.2
  redmine_drawio                 1.4.4
  redmine_impersonate            2.0.0
  redmine_issues_tree            0.0.15
  redmine_silencer               0.5.0
  redmine_tint_issues            1.3.2

Related issues

Is duplicate of Redmine - Defect #38464: Rendering a custom field with a URL pattern set and containing " :" in the value raises Addressable::URI::InvalidURIErrorClosedGo MAEDA

Actions
Actions

Also available in: Atom PDF