<commit_before>module Fastlane
  # Adds all the necessary emojis (obv)
  #
  class InspectorReporter
    NUMBER_OF_ISSUES_INLINE = 3

    # Called just as the investigation has begun.
    def inspector_started_query(query, inspector)
      puts ""
      puts "Looking for related GitHub issues on #{inspector.repo_owner}/#{inspector.repo_name}..."
      puts "Search query: #{query}" if FastlaneCore::Globals.verbose?
      puts ""
    end

    # Called once the inspector has recieved a report with more than one issue.
    def inspector_successfully_recieved_report(report, inspector)
      report.issues[0..(NUMBER_OF_ISSUES_INLINE - 1)].each { |issue| print_issue_full(issue) }

      if report.issues.count > NUMBER_OF_ISSUES_INLINE
        puts "and #{report.total_results - NUMBER_OF_ISSUES_INLINE} more at: #{report.url}"
        puts ""
      end

      print_open_link_hint
    end

    # Called once the report has been recieved, but when there are no issues found.
    def inspector_recieved_empty_report(report, inspector)
      puts "Found no similar issues. To create a new issue, please visit:"
      puts "https://github.com/#{inspector.repo_owner}/#{inspector.repo_name}/issues/new"
      puts "Run `fastlane env` to append the fastlane environment to your issue"
    end

    # Called when there have been networking issues in creating the report.
    def inspector_could_not_create_report(error, query, inspector)
      puts "Could not access the GitHub API, you may have better luck via the website."
      puts "https://github.com/#{inspector.repo_owner}/#{inspector.repo_name}/search?q=#{query}&type=Issues&utf8=✓"
      puts "Error: #{error.name}"
    end

    private

    def print_issue_full(issue)
      resolved = issue.state == 'closed'
      status = (resolved ? issue.state.green : issue.state.red)

      puts "➡️  #{issue.title.yellow}"
      puts "   #{issue.html_url} [#{status}] #{issue.comments} 💬"
      puts "   #{Time.parse(issue.updated_at).to_pretty}"
      puts ""
    end

    def print_open_link_hint(newline = false)
      puts "" if newline
      puts "🔗  You can ⌘ + double-click on links to open them directly in your browser." if Helper.mac?
    end
  end
end<commit_msg>Align messages telling people to search the issues (#8968)<commit_after>module Fastlane
  # Adds all the necessary emojis (obv)
  #
  class InspectorReporter
    NUMBER_OF_ISSUES_INLINE = 3

    # Called just as the investigation has begun.
    def inspector_started_query(query, inspector)
      puts ""
      puts "Looking for related GitHub issues on #{inspector.repo_owner}/#{inspector.repo_name}..."
      puts "Search query: #{query}" if FastlaneCore::Globals.verbose?
      puts ""
    end

    # Called once the inspector has recieved a report with more than one issue.
    def inspector_successfully_recieved_report(report, inspector)
      report.issues[0..(NUMBER_OF_ISSUES_INLINE - 1)].each { |issue| print_issue_full(issue) }

      if report.issues.count > NUMBER_OF_ISSUES_INLINE
        puts "and #{report.total_results - NUMBER_OF_ISSUES_INLINE} more at: #{report.url}"
        puts ""
      end

      print_open_link_hint
    end

    # Called once the report has been recieved, but when there are no issues found.
    def inspector_recieved_empty_report(report, inspector)
      puts "Found no similar issues. To create a new issue, please visit:"
      puts "https://github.com/#{inspector.repo_owner}/#{inspector.repo_name}/issues/new"
      puts "Run `fastlane env` to append the fastlane environment to your issue"
    end

    # Called when there have been networking issues in creating the report.
    def inspector_could_not_create_report(error, query, inspector)
      puts "Could not access the GitHub API, you may have better luck via the website."
      puts "https://github.com/#{inspector.repo_owner}/#{inspector.repo_name}/search?q=#{query}&type=Issues&utf8=✓"
      puts "Error: #{error.name}"
    end

    private

    def print_issue_full(issue)
      resolved = issue.state == 'closed'
      status = (resolved ? issue.state.green : issue.state.red)

      puts "➡️  #{issue.title.yellow}"
      puts "    #{issue.html_url} [#{status}] #{issue.comments} 💬"
      puts "    #{Time.parse(issue.updated_at).to_pretty}"
      puts ""
    end

    def print_open_link_hint(newline = false)
      puts "" if newline
      puts "🔗  You can ⌘ + double-click on links to open them directly in your browser." if Helper.mac?
    end
  end
end
{'fraction_non_alphanumeric': 0.09997773324426631, 'fraction_numerical': 0.0026720106880427524, 'mean_word_length': 3.2257761053621823, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 4, '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': '3957315', 'n_tokens_mistral': 1453, 'n_tokens_neox': 1400, 'n_words': 409}