<commit_before>module Syncro
  class Session
    class << self
      def records
        @records ||= []
      end
      
      def find(id)
        records.find {|r| r.id == id }
      end
      
      def for_client(client)
        records.select {|r| r.client == client }
      end
    end
    
    delegate :synced?, :to => :client
    delegate :sync, :add_scribe, :rpc, :to => :app
    
    attr_reader   :connection
    attr_accessor :client
    
    def initialize(connection, client = nil)
      @connection = connection
      self.client = client
      self.class.records << self<commit_msg>Only integer session IDs<commit_after>module Syncro
  class Session
    class << self
      def records
        @records ||= []
      end
      
      def find(id)
        id = Integer(id) # Only integer IDs
        records.find {|r| r.id == id }
      end
      
      def for_client(client)
        records.select {|r| r.client == client }
      end
    end
    
    delegate :synced?, :to => :client
    delegate :sync, :add_scribe, :rpc, :to => :app
    
    attr_reader   :connection
    attr_accessor :client
    
    def initialize(connection, client = nil)
      @connection = connection
      self.client = client
      self.class.records << self
{'fraction_non_alphanumeric': 0.10199203187250996, 'fraction_numerical': 0.0, 'mean_word_length': 1.9006928406466512, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 7, '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': '4853796', 'n_tokens_mistral': 378, 'n_tokens_neox': 375, 'n_words': 105}