mirror of
https://github.com/chatmail/core.git
synced 2026-05-19 23:06:32 +03:00
add more debugging
This commit is contained in:
@@ -569,6 +569,7 @@ impl Imap {
|
|||||||
info!(context, "No new emails in folder {folder:?}.");
|
info!(context, "No new emails in folder {folder:?}.");
|
||||||
return Ok(false);
|
return Ok(false);
|
||||||
}
|
}
|
||||||
|
info!(context, "Setting new_mail to False");
|
||||||
session.new_mail = false;
|
session.new_mail = false;
|
||||||
|
|
||||||
let mut read_cnt = 0;
|
let mut read_cnt = 0;
|
||||||
@@ -1237,6 +1238,7 @@ impl Session {
|
|||||||
// have been modified while our request was in progress.
|
// have been modified while our request was in progress.
|
||||||
// We may or may not have these new flags as a part of the response,
|
// We may or may not have these new flags as a part of the response,
|
||||||
// so better skip next IDLE and do another round of flag synchronization.
|
// so better skip next IDLE and do another round of flag synchronization.
|
||||||
|
info!(context, "got unsolicited fetch in folder");
|
||||||
self.new_mail = true;
|
self.new_mail = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -30,13 +30,17 @@ impl Session {
|
|||||||
self.select_with_uidvalidity(context, folder).await?;
|
self.select_with_uidvalidity(context, folder).await?;
|
||||||
|
|
||||||
if self.drain_unsolicited_responses(context)? {
|
if self.drain_unsolicited_responses(context)? {
|
||||||
|
info!(
|
||||||
|
context,
|
||||||
|
"Setting new_mail to True"
|
||||||
|
);
|
||||||
self.new_mail = true;
|
self.new_mail = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.new_mail {
|
if self.new_mail {
|
||||||
info!(
|
info!(
|
||||||
context,
|
context,
|
||||||
"Skipping IDLE in {folder:?} because there may be new mail."
|
"YES YES YES Skipping IDLE in {folder:?} because there may be new mail."
|
||||||
);
|
);
|
||||||
return Ok(self);
|
return Ok(self);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user