<commit_before>class ZabbixRubyClient
  module Plugins
    module Apt
      extend self

      def collect(*args)
        aptcheck = `/usr/lib/update-notifier/apt-check`
        if $?.to_i == 0
          security, pending = aptcheck.split(/;/).map(&:to_i)
        else
          logger.warn "Are you running on ubuntu ?"
          return []
        end
        time = Time.now.to_i
        back = []
        back << "#{host} apt[security] #{time} #{security}"
        back << "#{host} apt[pending] #{time} #{pending}"
        return back
      end

    end
  end
end

ZabbixRubyClient::Plugins.register('apt', ZabbixRubyClient::Plugins::Apt)
<commit_msg>fix apt plugin<commit_after>class ZabbixRubyClient
  module Plugins
    module Apt
      extend self

      def collect(*args)
        host = args[0]
        aptcheck = `/usr/lib/update-notifier/apt-check`
        if $?.to_i == 0
          security, pending = aptcheck.split(/;/).map(&:to_i)
        else
          logger.warn "Are you running on ubuntu ?"
          return []
        end
        time = Time.now.to_i
        back = []
        back << "#{host} apt[security] #{time} #{security}"
        back << "#{host} apt[pending] #{time} #{pending}"
        return back
      end

    end
  end
end

ZabbixRubyClient::Plugins.register('apt', ZabbixRubyClient::Plugins::Apt)

{'fraction_non_alphanumeric': 0.13288288288288289, 'fraction_numerical': 0.0022522522522522522, 'mean_word_length': 2.1, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 3, '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': '3089155', 'n_tokens_mistral': 439, 'n_tokens_neox': 414, 'n_words': 100}