<commit_before>module MonkeyParty
  class Base
    include HTTParty
    base_uri 'http://api.mailchimp.com/1.1/'
    default_params :output => "xml"

    def initialize(attrs = {})
      attrs.each{ |key, value| self.send("#{key}=", value) }
    end
  end
end
<commit_msg>mail chimp doesn't pass the proper header<commit_after>require "ruby-debug"
module MonkeyParty
  class Base
    include HTTParty
    base_uri 'http://api.mailchimp.com/1.1/'
    default_params :output => "xml"

    def initialize(attrs = {})
      attrs.each{ |key, value| self.send("#{key}=", value) }
    end

    class << self
      def get(path, options = {})
        #fix the format because Mail Chimp doesn't pass the proper header
        options[:format] = :xml
        super
      end
    end
  end
end

{'fraction_non_alphanumeric': 0.12372448979591837, 'fraction_numerical': 0.00510204081632653, 'mean_word_length': 2.738095238095238, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 3}, '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': '4406207', 'n_tokens_mistral': 257, 'n_tokens_neox': 253, 'n_words': 71}