<commit_before><% if failed_multiple_queues? && !params[:queue] %>
<h1>All Failed Queues: <%= Resque::Failure.queues.size %> total</h1>
<% else %>
<h1>Failed Jobs <%= "on '#{params[:queue]}'" if params[:queue] %> <%= "with class '#{params[:class]}'" if params[:class] %></h1>
<% end %>

<% unless failed_size.zero? %>
<form method="POST" action="<%= u "failed#{'/' + params[:queue] if params[:queue]}/clear" %>">
  <input type="submit" name="" value="Clear <%= params[:queue] ? "'#{params[:queue]}'" : 'Failed' %> Jobs" />
</form>
<form method="POST" action="<%= u "failed#{'/' + params[:queue] if params[:queue]}/requeue/all" %>">
  <input type="submit" name="" value="Retry <%= params[:queue] ? "'#{params[:queue]}'" : 'Failed' %> Jobs" />
</form>
<% end %>

<% if failed_multiple_queues? && !params[:queue] %>
<%= partial :failed_queues_overview %>
<% else %>
<p class='sub'>Showing <%= failed_start_at %> to <%= failed_end_at %> of <b><%= failed_size %></b> jobs</p>


<ul class='failed'>
  <% Resque::Failure.each(failed_start_at, failed_per_page, params[:queue], params[:class], failed_order) do |id, job| %>
    <%= partial :failed_job, :id => id, :job => job, :queue => "failed#{'/' + params[:queue] if params[:queue]}" %>
  <% end %>
</ul>

<%= partial :next_more, :start => failed_start_at, :size => failed_size, :per_page => failed_per_page %>
<% end %><commit_msg>Prompt for confirmation on clearing failed jobs<commit_after><% if failed_multiple_queues? && !params[:queue] %>
<h1>All Failed Queues: <%= Resque::Failure.queues.size %> total</h1>
<% else %>
<h1>Failed Jobs <%= "on '#{params[:queue]}'" if params[:queue] %> <%= "with class '#{params[:class]}'" if params[:class] %></h1>
<% end %>

<% unless failed_size.zero? %>
<form method="POST" action="<%= u "failed#{'/' + params[:queue] if params[:queue]}/clear" %>">
  <input type="submit" name="" value="Clear <%= params[:queue] ? "'#{params[:queue]}'" : 'Failed' %> Jobs" onclick='return confirm("Are you absolutely sure? This cannot be undone.");' />
</form>
<form method="POST" action="<%= u "failed#{'/' + params[:queue] if params[:queue]}/requeue/all" %>">
  <input type="submit" name="" value="Retry <%= params[:queue] ? "'#{params[:queue]}'" : 'Failed' %> Jobs" />
</form>
<% end %>

<% if failed_multiple_queues? && !params[:queue] %>
<%= partial :failed_queues_overview %>
<% else %>
<p class='sub'>Showing <%= failed_start_at %> to <%= failed_end_at %> of <b><%= failed_size %></b> jobs</p>


<ul class='failed'>
  <% Resque::Failure.each(failed_start_at, failed_per_page, params[:queue], params[:class], failed_order) do |id, job| %>
    <%= partial :failed_job, :id => id, :job => job, :queue => "failed#{'/' + params[:queue] if params[:queue]}" %>
  <% end %>
</ul>

<%= partial :next_more, :start => failed_start_at, :size => failed_size, :per_page => failed_per_page %>
<% end %>
{'fraction_non_alphanumeric': 0.254278728606357, 'fraction_numerical': 0.0027942717429269995, 'mean_word_length': 5.86810551558753, 'pattern_counts': {'":': 0, '<': 81, '<?xml version=': 0, '>': 93, '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': '953939', 'n_tokens_mistral': 1082, 'n_tokens_neox': 990, 'n_words': 232}