nextcloud / nextcloud/integration_davc

Parser extracts 1884 VTIMEZONE epoch instead of DTSTART, making events invisible

Open
#93 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
PHP
Stars
12
Forks
2
Avg merge
1d 21h
Merged PRs (30d)
16

Description

Steps to reproduce
  1. Configure a remote CalDAV server backend (e.g., Radicale) hosting an .ics calendar entity that contains a legacy, nested VTIMEZONE array carrying historical parameters (such as LMT-era transitions spanning back to 1884, common in legacy exports).
  2. Sync the collection using integration_davc configured in Cached operations mode by triggering php occ davc:harmonize <username>.
  3. Check the local cache table oc_davc_entities_calendars. The app successfully pulls the entry but miscalculates the database index timestamp column (startson), mapping a current event into a past rendering frame based on the nested timezone block transitions rather than the actual event DTSTART.
  4. Observe that the event does not appear in the current calendar UI because the local database has buried it in the year 1884 (or other displaced historical month).
Expected behaviour

The internal iCalendar parser should extract the actual event DTSTART to calculate the startson epoch, rather than erroneously extracting historical transition dates from the nested VTIMEZONE metadata array.

Actual behaviour

The integration_davc parser incorrectly grabs the oldest transition date from the VTIMEZONE block (e.g., 18840101) and sets that as the event's startson index in the oc_davc_entities_calendars table. Because the database index is completely displaced from the event's true schedule, the harmonization completes successfully, but the events are hidden from the Nextcloud Calendar interface.

Server configuration

Web server: Apache/2.4.67 (Debian)
Database: MariaDB 10.11.16
PHP version: 8.4.21
Nextcloud version: 33.0.3
DAVC version: 1.0.4

List of activated apps - integration_davc
- calendar
Nextcloud configuration ```json { "apps": { "integration_davc": { "enabled": "yes", "forbid_insecure_http": "0", "force_certificate_verification": "0", "harmonization_interval": "300", "installed_version": "1.0.4", "loglevel": "0", "types": "dav" } } } ```

Inspecting rows in oc_davc_entities_calendars during the failure window confirms that the parser overrides the true event scheduling parameters when handling legacy VTIMEZONE entries, corrupting the calculated index:

  • calculated_startson_epoch: {Displaced out of view window}

  • raw_ics_blob_line: DTSTART:18840101T000000 (Parsed incorrectly from inner legacy structural arrays)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the integration_davc davc:harmonize command and trace the iCalendar parser's handling of nested VTIMEZONE data versus the event DTSTART. Inspect the resulting startson value in oc_davc_entities_calendars and reproduce the legacy .ics case; done means the event's actual DTSTART determines the epoch and the event appears in the current calendar view.

Written by the indexing model from the issue text.

Assessment

Tech stack
mariadb, php
Domain
backend, database
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.