Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delay immediate sync following system resume #1850

Closed
phw198 opened this issue Apr 27, 2024 · 7 comments
Closed

Delay immediate sync following system resume #1850

phw198 opened this issue Apr 27, 2024 · 7 comments
Assignees
Labels
enhancement New feature resolved Working hotfix available
Milestone

Comments

@phw198
Copy link
Owner

phw198 commented Apr 27, 2024

Is your feature request related to a problem? Please describe.
As per #1836 (comment), when a system resumes from suspend/hibernate, often OGCS can attempt to sync before the networking is available.

Describe the solution you'd like
For OGCS to detect the resume event and delay syncs to give the networking a chance to become usable.

@phw198 phw198 added the enhancement New feature label Apr 27, 2024
@phw198 phw198 self-assigned this Apr 27, 2024
@phw198 phw198 added this to Under Development in Enhancement Pipeline Apr 27, 2024
@phw198
Copy link
Owner Author

phw198 commented Apr 27, 2024

@kuraikaze OGCS already detected a system time change, which is a side effect of resuming from suspend and logged at INFO with "Detected system timezone change" - so I think we can piggyback this.

📦 Delay by a minute should now happen with hotfix v2.10.4.5.zip (see instructions for applying).
      CRCs: Zip = 103B3E7D Exe = A53EF75B

Let me know how it goes.

@phw198 phw198 moved this from Under Development to User Acceptance Testing in Enhancement Pipeline Apr 27, 2024
@phw198 phw198 added the waiting fix confirmation Hotfix available for testing label Apr 27, 2024
@kuraikaze
Copy link

Ah, 'k - that would explain why OGCS only displayed the error behaviour if the system had slept for more than one hour.
Hotfix applied - I'll let you know in an hour or two how it went :)

@kuraikaze
Copy link

kuraikaze commented Apr 28, 2024

Nearly there ...

Got an OGCS popup with a different error this time:-

Calendar Folders.
A problem was encountered when searching for Outlook calendar folders.
COM object that has been separated from its underlying RCW cannot be used.

Then the same Windows Notification error triggered:-

OutookGoogleCalendarSync

Outook Google Calendar Sync
Issue encountered.
Please review the output on the main `Sync` tab"

However - a successful sync triggered 60 seconds afterwards, so that bit worked nicely. 👍

Of course I forgot to turn back on detailed logging when I applied the hotfix sigh
Logging set now - I'll gist a debug log once I have one that says anything worthwhile.

@kuraikaze
Copy link

kuraikaze commented Apr 28, 2024

Hrmmm - no OGCS popup on next sleep/resume cycle, but a Windows Notification "Issue encountered" was triggered.

The time zone change was detected and the next sync scheduled for 60 seconds later.
However ... OGCS started a sync attempt immediately, which failed.
Then the schedule-delayed sync a minute later triggered and completed successfully.

Resume event is at 2024-04-28 17:36:15,244: OGcalsync.log 2.10.4.5-hotfix

@phw198
Copy link
Owner Author

phw198 commented May 2, 2024

I think the scheduled syncs are still firing too quickly before being able to get in and delay them.

📦 I taken a slightly different approach with hotfix v2.10.4.8.zip so please let me know how that goes (see instructions for applying).
      CRCs: Zip = 8C1B1432 Exe = 7675A4D0

@kuraikaze
Copy link

kuraikaze commented May 3, 2024

This seems to work well for me - no popups or notifications generated, and sync completed successfully 60 seconds after resume event. Nice one 👍

2024-05-03 12:58:58,342 INFO  .NET SystemEvents OutlookGoogleCalendarSync.NotificationTray [49] -  Detected system timezone change.
2024-05-03 12:59:00,101 DEBUG  1 OutlookGoogleCalendarSync.Sync.SyncTimer [53] -  Scheduled sync triggered for profile: Default
2024-05-03 12:59:00,102 DEBUG  1 OutlookGoogleCalendarSync.Sync.SyncTimer [55] -  Too soon after system resume; delaying for 60 seconds...
2024-05-03 13:00:00,226 ULTRA-FINE  1 OutlookGoogleCalendarSync.Sync.PushSyncTimer [179] -  Push sync triggered.

Full OGcalsync.log uploaded for reference - Resume event at 024-05-03 12:58:58,342 : OGcalsync.log 2.10.4.8-hotfix

@phw198
Copy link
Owner Author

phw198 commented May 4, 2024

Perfect, that's great news! Thanks for confirming 👍🏻

@phw198 phw198 added resolved Working hotfix available and removed waiting fix confirmation Hotfix available for testing labels May 4, 2024
@phw198 phw198 moved this from User Acceptance Testing to Waiting Release in Enhancement Pipeline May 4, 2024
@phw198 phw198 added this to the v2.10.5 milestone May 4, 2024
@phw198 phw198 closed this as completed in f31c401 May 19, 2024
Enhancement Pipeline automation moved this from Waiting Release to Delivered May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature resolved Working hotfix available
Projects
Enhancement Pipeline
  
Delivered
Development

No branches or pull requests

2 participants