<commit_before>From 7d4d1b1becc87b8c1be7b38daf9344509ee0d9ed Mon Sep 17 00:00:00 2001
From: halogenOS Code Review <<EMAIL>>
Date: Sun, 29 Jan 2017 19:04:06 -0600
Subject: [PATCH 1/1] Remove log spam

---
 src/danog/MadelineProto/MTProtoTools/CallHandler.php     | 2 +-
 src/danog/MadelineProto/MTProtoTools/ResponseHandler.php | 1 -
 src/danog/MadelineProto/MTProtoTools/UpdateHandler.php   | 4 ++--
 3 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/danog/MadelineProto/MTProtoTools/CallHandler.php b/src/danog/MadelineProto/MTProtoTools/CallHandler.php
index 79477f4..1be98b5 100644
--- a/src/danog/MadelineProto/MTProtoTools/CallHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/CallHandler.php
@@ -52,7 +52,7 @@ trait CallHandler
         }
         for ($count = 1; $count <= $this->settings['max_tries']['query']; $count++) {
             try {
-                \danog\MadelineProto\Logger::log(['Calling method (try number '.$count.' for '.$method.')...'], \danog\MadelineProto\Logger::VERBOSE);
+                #\danog\MadelineProto\Logger::log(['Calling method (try number '.$count.' for '.$method.')...'], \danog\MadelineProto\Logger::VERBOSE);
 
                 $int_message_id = $this->send_message($serialized, $content_related, $aargs);
                 if ($method === 'http_wait' || (isset($aargs['noResponse']) && $aargs['noResponse'])) {
diff --git a/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php b/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php
index 94e86e1..99dd8cf 100644
--- a/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php
@@ -73,7 +73,6 @@ trait ResponseHandler
         $only_updates = true;
         foreach ($this->datacenter->sockets[$datacenter]->new_incoming as $current_msg_id) {
             $unset = false;
-            \danog\MadelineProto\Logger::log(['Received '.$this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['content']['_'].'.'], \danog\MadelineProto\Logger::VERBOSE);
 
             switch ($this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['content']['_']) {
                 case 'msgs_ack':
diff --git a/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php b/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php
index e03ed74..2bd1dd5 100644
--- a/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php
@@ -151,8 +151,8 @@ trait UpdateHandler
                 throw $e;
             }
         }
-        \danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         $this->get_channel_state($channel)['sync_loading'] = false;
+        #\danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         switch ($difference['_']) {
             case 'updates.channelDifferenceEmpty':
                 $this->set_channel_state($channel, $difference);
@@ -228,9 +228,9 @@ trait UpdateHandler
             $this->get_update_state()['pending_seq_updates'] = [];
         }
         $difference = $this->method_call('updates.getDifference', ['pts' => $this->get_update_state()['pts'], 'date' => $this->get_update_state()['date'], 'qts' => $this->get_update_state()['qts']], ['datacenter' => $this->datacenter->curdc]);
-        \danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         $this->get_update_state()['sync_loading'] = false;
 
+        #\danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         switch ($difference['_']) {
             case 'updates.differenceEmpty':
                 $this->set_update_state($difference);
-- 
2.7.4
<commit_msg>remove more spam<commit_after>From b159fd1389c715b48dca12d7ffbae89edd625be4 Mon Sep 17 00:00:00 2001
From: halogenOS Code Review <<EMAIL>>
Date: Sun, 29 Jan 2017 19:04:06 -0600
Subject: [PATCH 1/1] Remove log spam

---
 src/danog/MadelineProto/MTProtoTools/CallHandler.php     | 2 +-
 src/danog/MadelineProto/MTProtoTools/ResponseHandler.php | 1 -
 src/danog/MadelineProto/MTProtoTools/SeqNoHandler.php    | 1 -
 src/danog/MadelineProto/MTProtoTools/UpdateHandler.php   | 4 ++--
 4 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/src/danog/MadelineProto/MTProtoTools/CallHandler.php b/src/danog/MadelineProto/MTProtoTools/CallHandler.php
index 000d819..871ea9d 100644
--- a/src/danog/MadelineProto/MTProtoTools/CallHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/CallHandler.php
@@ -52,7 +52,7 @@ trait CallHandler
         }
         for ($count = 1; $count <= $this->settings['max_tries']['query']; $count++) {
             try {
-                \danog\MadelineProto\Logger::log(['Calling method (try number '.$count.' for '.$method.')...'], \danog\MadelineProto\Logger::VERBOSE);
+                #\danog\MadelineProto\Logger::log(['Calling method (try number '.$count.' for '.$method.')...'], \danog\MadelineProto\Logger::VERBOSE);
 
                 $int_message_id = $this->send_message($serialized, $content_related, $aargs);
                 if ($method === 'http_wait' || (isset($aargs['noResponse']) && $aargs['noResponse'])) {
diff --git a/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php b/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php
index a2e3f4b..0166183 100644
--- a/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/ResponseHandler.php
@@ -73,7 +73,6 @@ trait ResponseHandler
         $only_updates = true;
         foreach ($this->datacenter->sockets[$datacenter]->new_incoming as $current_msg_id) {
             $unset = false;
-            \danog\MadelineProto\Logger::log(['Received '.$this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['content']['_'].'.'], \danog\MadelineProto\Logger::VERBOSE);
 
             switch ($this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['content']['_']) {
                 case 'msgs_ack':
diff --git a/src/danog/MadelineProto/MTProtoTools/SeqNoHandler.php b/src/danog/MadelineProto/MTProtoTools/SeqNoHandler.php
index 8a8a5eb..0b5af67 100644
--- a/src/danog/MadelineProto/MTProtoTools/SeqNoHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/SeqNoHandler.php
@@ -29,7 +29,6 @@ trait SeqNoHandler
     public function check_in_seq_no($datacenter, $current_msg_id)
     {
         if (isset($this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['seq_no']) && ($seq_no = $this->generate_in_seq_no($datacenter, $this->content_related($this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['content']))) !== $this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['seq_no']) {
-            \danog\MadelineProto\Logger::log(['SECURITY WARNING: Seqno mismatch (should be '.$seq_no.', is '.$this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['seq_no'].', '.$this->datacenter->sockets[$datacenter]->incoming_messages[$current_msg_id]['content']['_'].')'], \danog\MadelineProto\Logger::ERROR);
         }
     }
 
diff --git a/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php b/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php
index 819de63..a1772ee 100644
--- a/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php
+++ b/src/danog/MadelineProto/MTProtoTools/UpdateHandler.php
@@ -158,8 +158,8 @@ trait UpdateHandler
             }
             throw $e;
         }
-        \danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         $this->get_channel_state($channel)['sync_loading'] = false;
+        #\danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         switch ($difference['_']) {
             case 'updates.channelDifferenceEmpty':
                 $this->set_channel_state($channel, $difference);
@@ -239,9 +239,9 @@ trait UpdateHandler
             $this->get_update_state()['pending_seq_updates'] = [];
         }
         $difference = $this->method_call('updates.getDifference', ['pts' => $this->get_update_state()['pts'], 'date' => $this->get_update_state()['date'], 'qts' => $this->get_update_state()['qts']], ['datacenter' => $this->datacenter->curdc]);
-        \danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         $this->get_update_state()['sync_loading'] = false;
 
+        #\danog\MadelineProto\Logger::log(['Got '.$difference['_']], \danog\MadelineProto\Logger::VERBOSE);
         switch ($difference['_']) {
             case 'updates.differenceEmpty':
                 $this->set_update_state($difference);
-- 
2.7.4

{'fraction_non_alphanumeric': 0.1758628519527702, 'fraction_numerical': 0.03258401453224342, 'mean_word_length': 3.853443526170799, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 76, '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': '504114', 'n_tokens_mistral': 3146, 'n_tokens_neox': 2911, 'n_words': 376}