Project

General

Profile

Actions

Defect #25846

closed

Repository directory listing: ActionView::Template::Error (incompatible character encodings: ASCII-8BIT and UTF-8)

Added by Marc Vollmer over 7 years ago. Updated over 4 years ago.

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

0%

Estimated time:
Resolution:
Affected version:

Description

Hello,

we have added 4 repositories (Git Remote) as projectarchvies to redmine.
When we open those repositories in the projectarchive view 3 of them work, one gives the following error:

Started GET "/projects/XXX/repository/XXX" for XXX.XXX.XXX.XXX at 2017-05-15 10:10:00 +0200
Processing by RepositoriesController#show as HTML
  Parameters: {"id"=>"XXX", "repository_id"=>"XXX"}
  Current user: XXX (id=135)
  Rendered repositories/_navigation.html.erb (38.5ms)
  Rendered repositories/_breadcrumbs.html.erb (0.9ms)
  Rendered repositories/_dir_list_content.html.erb (10.4ms)
  Rendered repositories/_dir_list.html.erb (10.9ms)
  Rendered repositories/show.html.erb within layouts/base (53.8ms)
Completed 500 Internal Server Error in 168ms (ActiveRecord: 3.5ms)

ActionView::Template::Error (incompatible character encodings: ASCII-8BIT and UTF-8):
     8:                :locals => { :path => @path, :kind => 'dir', :revision => @rev } %></h2>
     9:
    10: <% if !@entries.nil? && authorize_for('repositories', 'browse') %>
    11:   <%= render :partial => 'dir_list' %>
    12: <% end %>
    13:
    14: <%= render_properties(@properties) %>
  app/views/repositories/show.html.erb:11:in `_app_views_repositories_show_html_erb__1302325350339252382_70155590060320'
  app/controllers/repositories_controller.rb:125:in `show'
  lib/redmine/sudo_mode.rb:63:in `sudo_mode'

My first guess was that theres a directory of file in the repository that has an invalid char as a name, so I wrote a little script to check all filenames against a regex and we just found a file containing a ~ in the name.

We had this repository working before, so the file must be added in the last 1 to 2 month but the file containing the ~ was added 2 years ago.

I already tried to re add the repository with no success and other repositories I added as a test also work.

Thanks for your help in advance!


Files

2.png (10.8 KB) 2.png Toshi MARUYAMA, 2017-05-15 12:27
1.png (12.7 KB) 1.png Toshi MARUYAMA, 2017-05-15 12:27
Actions

Also available in: Atom PDF