mirror of
https://github.com/domainaware/parsedmarc.git
synced 2026-06-03 01:19:43 +00:00
Fix current_time format for MSGraphConnection (#708)
Should have caught this on previous fix for since. the current time is used on line 2145: connection.fetch_messages(reports_folder, since=current_time) if that code is called and it usually won't be depending upon configuration it will fail with the time format being wrong: yyyy-mm-ddThh:mm:ss.zzzzzz+00:00Z --- this removes the extra "Z" that is not needed since utc offset is already specified and becomes invalid.
This commit is contained in:
@@ -1956,7 +1956,7 @@ def get_dmarc_reports_from_mailbox(
|
||||
current_time = datetime.now(timezone.utc).strftime("%d-%b-%Y")
|
||||
elif isinstance(connection, MSGraphConnection):
|
||||
since = (datetime.now(timezone.utc) - timedelta(minutes=_since)).isoformat()
|
||||
current_time = datetime.now(timezone.utc).isoformat() + "Z"
|
||||
current_time = datetime.now(timezone.utc).isoformat()
|
||||
elif isinstance(connection, GmailConnection):
|
||||
since = (datetime.now(timezone.utc) - timedelta(minutes=_since)).strftime(
|
||||
"%s"
|
||||
|
||||
Reference in New Issue
Block a user