All calendars and events appear twice

REPRODUCIBILITY: 100%
OS VERSION: 5.2.0.18
HARDWARE: Jolla Phone 2026
UI LANGUAGE: English
REGRESSION: Don’t know

DESCRIPTION:

<!-- Please describe what is not working -->

All calendars synced from Nextcloud appear double in the Calendar app, including all events from the calendars. I have two NC accounts with calendars, and two without.

It appears only one calendar of each pair synchronises. If I create an event elsewhere, it only appears once, in one of the two calendars.

They do not appear double in the Settings | Accounts area.

PRECONDITIONS:

<!-- Give some context information, e.g. "an email account is needed" -->

One or more NC accounts with synced calendars configured in the Settings app.

I have four NC accounts configured, two of which sync calendars.

The NC version in question is 27, installed as part of a Mail-in-a-box mail-server setup (v77). The two accounts are private/work from the same server. They are only for contacts/calendars as part of the mail-server setup.

Files are on another NC35 server, two accounts, which don’t sync calendars or contacts.

STEPS TO REPRODUCE:

<!-- Please provide as much information as you have to reproduce the behavior -->
  1. I do not know. Initially, they were not doubled, then they were. It doesn’t seem to correlate with updates of Mail-in-a-box.

EXPECTED RESULT:

<!-- What outcome did you expect? E.g. "An error notification", "The new message is shown" -->

That each NC calendar appears once and each event is displayed once.

ACTUAL RESULT:

<!-- What was the outcome? E.g. "The app closed" or "The message was not shown" -->

All NC calendars and all events in NC calendars are displayed double, even if only one appears to sync.

MODIFICATIONS:

<!-- Note any custom changes, patches, repositories, installed package (like WayDroid) etc. on your device -->

I’m a Linux and Unix old-timer (40+ years), but new to SFOS. I used Maemo on two Nokia internet tables twenty years ago.

I have Jolla Store, Chum and Storeman configured, and apps from all three, but use the standard calendar app exclusively, and have not had other calendar related apps installed.

ADDITIONAL INFORMATION:

<!-- Please ALWAYS attach relevant data such as logs, screenshots, etc... -->

I am accustomed to the CLI, and have SSH access enabled. If you want anything specific from the phone, send me the commands to run, and I’ll send you the output.

I have figured out devel-su, but only used it to read log-files when NC contact sync didn’t work initially.

Hi!
Thank you for your bug report. Could you please use the default template provided when selecting the bug report category?
With a default template, it’s ease a lot the understanding and you don’t need to dig all the bug report to search relevant information.
Thank you in advance

Not sure if it’s the same case but I had 1 type of event appearing twice which ended up perfectly explained : the birthdays.

  • Contacts sync’d with NextCloud.
  • Both SailfishOS and NextCloud generate an automatic calendar for birthdays.
  • NextCloud calendar sync’d as well resulting in both.

I ended up disabling the Sailfish one because NextCloud adds the year which can be useful.

If it’s not your case, maybe this answer can help others…

1 Like

My apologies. I’ve updated the post with the template. Should I remove the comments?

All my NC calendars are doubled.

Maybe the calendars were duplicated during a sync, because it was not able to associate the existing one with the account… No idea how that can be though.

Can you look at how the calendars are defined in the database on device ?

  1. install sqlite with pkcon install sqlite, if not already present.
  2. open the database with devel-su -p sqlite3 ~/.local/share/system/privileged/Calendar/mkcal/db
  3. list the calendars and their properties with select CalendarId,name,pluginName,account,syncProfile from calendars;
  4. list the calendar special properties with select * from Calendarproperties;

In particular, have your duplicated calendars different remoteCalendarPath special properties ? That may explain the duplication since this value (and the account number) is used to match a calendar with what the server is listing as available calendars. In case the path changed on the server (but not the calendar label for instance), the calendar may get duplicated on the device as a new calendar.

EDIT : added missing devel-su -p command to open the database from a restricted directory…

4 Likes

Thanks for the help.

I’m not sure what has happened, but each calendar had one instance with a /dav/ in the path, and another with /caldav/.

Just to see what would happen, I moved to the db and db.changed files to somewhere else, and restarted the calendar app, and it restored the calendars without dublets.

So the specific problem is solved.

I don’t remember having changed this path in Settings | Accounts | Account | pulley | Advanced settings, but such a change might have caused the Calendar app to see new calendars, without removing the old.

Ok, so the change in calendar path on the server looks like a good culprit.

So the bug should be that the calendar related to the “old” path has not been deleted when the one with the new path was created. I’ll look into this possibility in the code (not sure I can reproduce the change in path on mailbox.org for instance).

1 Like

Ok, so there was a bug that remotely deleted calendars were not locally deleted on device. See this PR for a fix : Delete a local calendar if not listed on server. by dcaliste · Pull Request #45 · sailfishos/buteo-sync-plugin-caldav · GitHub

Thank you for your report and your help.

1 Like