<commit_before>- content_for :summary do
  #sidebar
    %h3
      = link_to @project.name, project_url(@project)
    %dl
      %dt
        Received at
      %dd
        = l(@error.raised_at, :format => :long_ordinal)
      %dt
        Most recent at
      %dd
        = l(@error.last_raised_at, :format => :long_ordinal)
      %dt
        Similar Errors
      %dd.last
        Occured
        = @error.count
        times

#error
  - form_for @root_error, :html => {:class => 'edit_error'}  do |f|
    = hidden_field_tag 'error[resolved]', !@error.resolved
    = f.submit @error.resolved ? 'Unresolved' : 'Resolved'

  %h1 Error summary

  %p#resolved
    = "This error is marked as #{@error.resolved ? 'resolved' : 'unresolved'}."

  %dl
    %dt Error
    %dd=h @error.message
    %dt URL
    %dd=link_to @error.url
    %dt Parameters
    %dd
      %pre= @error.params.inspect

  %h2 Request
  %ul
    - @error.request.each do |key, val|
      - unless ['url', 'params'].include? key
        %li="#{key}: #{val}"

  %h2 Session
  %ul
    - @error.session.each do |key, val|
      %li="#{key}: #{val}"

  %h2 Environment
  %ul
    - @error.environment.each do |key, val|
      %li="#{key}: #{val}"

  %h2 Backtrace
  - @error.backtrace.each do |line|
    = '&nbsp;' * (line.to_s.match(/^ +/).to_a.first || '').length
    = line.to_s
    %br

  %h2 Data
  %ul
    - @error.data.each do |key, val|
      %li="#{key}: #{val}"<commit_msg>see backtrace with &nbsp; in first charactere but with a more rubyist's way<commit_after>- content_for :summary do
  #sidebar
    %h3
      = link_to @project.name, project_url(@project)
    %dl
      %dt
        Received at
      %dd
        = l(@error.raised_at, :format => :long_ordinal)
      %dt
        Most recent at
      %dd
        = l(@error.last_raised_at, :format => :long_ordinal)
      %dt
        Similar Errors
      %dd.last
        Occured
        = @error.count
        times

#error
  - form_for @root_error, :html => {:class => 'edit_error'}  do |f|
    = hidden_field_tag 'error[resolved]', !@error.resolved
    = f.submit @error.resolved ? 'Unresolved' : 'Resolved'

  %h1 Error summary

  %p#resolved
    = "This error is marked as #{@error.resolved ? 'resolved' : 'unresolved'}."

  %dl
    %dt Error
    %dd=h @error.message
    %dt URL
    %dd=link_to @error.url
    %dt Parameters
    %dd
      %pre= @error.params.inspect

  %h2 Request
  %ul
    - @error.request.each do |key, val|
      - unless ['url', 'params'].include? key
        %li="#{key}: #{val}"

  %h2 Session
  %ul
    - @error.session.each do |key, val|
      %li="#{key}: #{val}"

  %h2 Environment
  %ul
    - @error.environment.each do |key, val|
      %li="#{key}: #{val}"

  %h2 Backtrace
  - @error.backtrace.each do |line|
    = line.to_s.gsub(/^(\s+)/){ |x|  '&nbsp;' * ($1.size) }
    %br

  %h2 Data
  %ul
    - @error.data.each do |key, val|
      %li="#{key}: #{val}"
{'fraction_non_alphanumeric': 0.16540577716643742, 'fraction_numerical': 0.00515818431911967, 'mean_word_length': 2.239420935412027, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2951926', 'n_tokens_mistral': 1093, 'n_tokens_neox': 1064, 'n_words': 258}