FossifyOrg / Calendar

A simple calendar with events, customizable widgets and no ads.

Home Page:https://www.fossify.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Caldav sync never ends if there is nothing new

pudup opened this issue · comments

Checklist

  • I can reproduce the bug with the latest version given here.
  • I made sure that there are no existing issues - open or closed - to which I could contribute my information.
  • I made sure that there are no existing discussions - open or closed - to which I could contribute my information.
  • I have read the FAQs inside the app (Menu -> About -> FAQs) and my problem isn't listed.
  • I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • This issue contains only one bug.
  • I have read and understood the contribution guidelines.

Affected app version

1.0.3

Affected Android/Custom ROM version

Android 13

Affected device model

Moto G

How did you install the app?

F-Droid / IzzyOnDroid

Steps to reproduce the bug

  1. Have pull to refresh caldav enabled. (And maybe also enabled caldav providers)
  2. Pull down to refresh on any calendar screen

Expected behavior

Caldav refreshes and animations ends after it's done

Actual behavior

IF there is nothing new to be added from sync, the refresh animation never ends. The refresh itself may or may not end, I don't know. A refresh completed toast never fires.
Changing to another view type, like daily from weekly, and back ends the animation

The new events needs to be external. Newly made local events do not succesfully end a refresh.

Screenshots/Screen recordings

No response

Additional information

It may not be an animation issue since it succesfully ends if there is new data to be synced

This is with local Decsync caldav. Edit: Also with other sources like google calendar

Also affects the latest version of SMTCalendar so it was not introduced by new changes.

commented

Having the same issue.
Refresh animation does not clear after pull to refresh. Selecting refresh from the menu or trying to pull to refresh again does nothing. Using DAVx5.

Screenshot_20240411_121621_Calendar

I can reproduce the issue on the master branch, I am going to try and fix it.

@pudup @S-360 I am fixing the issue but I started using CalDAV with DAVx5 recently so I am not sure what to expect here.

When my calendar is already synced, and I swipe, I reproduce the problem.
If my calendar has changed (from another device) and I launched a sync from DAVx5 first, when I swap, the calendar is refreshed with my new event and the issue does not appear.

There is a corner case : when my calendar was modified from another device, but I have not synced from DAVx5, I reproduce the issue and the calendar is not synced at all.
Is that normal ?
II think it is a different problem that must be fixed separately.

Edit : I can also edit my calendar from another device, swipe to trigger the endless refresh animation, switch to the DAVx5 app and launch a sync, come back to the Fossify-calendar : the refresh animation stops and the new event appears.
So the sync that is supposed to be launched from the app doesn't seem to work in my case. But again, another issue

commented

@florian-s-code

There is a corner case : when my calendar was modified from another device, but I have not synced from DAVx5, I reproduce the issue and the calendar is not synced at all.
Is that normal ?

It is normal as far as I know. I haven't looked at the code myself but the calendar app can't request your davx5 app to sync and can only add to it or read from it as far as I can tell.

In my case, I use decsync with syncthing and it auto syncs independent of the calendar app.

It is normal as far as I know. I haven't looked at the code myself but the calendar app can't request your davx5 app to sync and can only add to it or read from it as far as I can tell.

No, https://manual.davx5.com/accounts_collections.html#synchronization states:

Immediate synchronization can be started through calendar apps (or other apps), which will initiate a sync over the sync framework, noticed by DAVx⁵.

We do request a Sync, but it seems we may have an issue.
But it's not 100% related to this issue.
It makes it harder to test a successful sync but we should be able to fix the endless refreshing animation anyway in the case of a non-successful sync (no new data).

commented

It is normal as far as I know. I haven't looked at the code myself but the calendar app can't request your davx5 app to sync and can only add to it or read from it as far as I can tell.

No, https://manual.davx5.com/accounts_collections.html#synchronization states:

Immediate synchronization can be started through calendar apps (or other apps), which will initiate a sync over the sync framework, noticed by DAVx⁵.

Thanks for the info. In that case there's another issue to be opened as @florian-s-code suggests.