Giter Club home page Giter Club logo

Comments (11)

my4paws avatar my4paws commented on July 21, 2024 1

From what I've been able to find, it looks like you're being returned the .occuranceDate instead of the .startDate for a recurring event. But nowhere in your code do you ask for that. (that I could see).
Also if it helps, the issue is confined to future events only. In my own app I also retrieve past events & the same recurring events are reported correctly with .startDate once they are "before" current Date()
I just pray there's a solution for SwiftUI / eventKit version as my personal app needs this to work :)

from ekeventkit.example.

nemecek-filip avatar nemecek-filip commented on July 21, 2024

Hi, this happens using my example or in your app? I haven't tried recurring events much but I guess it isn't EventKit bug since this frameworks has been there for years and I believe such serious issue would have been fixed by now :)

from ekeventkit.example.

my4paws avatar my4paws commented on July 21, 2024

Hi

It will happen in both my app ( which is adapted from your example ) AND with your clean Swiftui example downloaded directly from GitHub and run on the simulator (IOS 14).

PS: the recurring event doesn't have to have been created from your code. So has nothing to do with the way the event was created. A recurring event made with IOS calendar app will produce the same result.

from ekeventkit.example.

my4paws avatar my4paws commented on July 21, 2024

just wanted to add because I think it provides hope that the issue is fixable. This problem with recurring events is confined to your SwiftUI example. There's no such problem with the UIKit example you provide.
I hope you are able to pin it down. ;)

from ekeventkit.example.

nemecek-filip avatar nemecek-filip commented on July 21, 2024

Thanks for the info. I briefly checked UIKit version yesterday but did not find the issue you described. Interesting that it only happens with SwiftUI version.

from ekeventkit.example.

nemecek-filip avatar nemecek-filip commented on July 21, 2024

I checked the relevant code and it seems to same to me. The occurrenceDate should be the date of the first event in the series, see - https://developer.apple.com/documentation/eventkit/ekevent/1507244-occurrencedate

from ekeventkit.example.

my4paws avatar my4paws commented on July 21, 2024

Oh no that's tragic 😭... do you now believe this to be a bug in IOS/ Eventkit rather than an issue with your example code? Will you be able to report it to Apple maybe?

from ekeventkit.example.

nemecek-filip avatar nemecek-filip commented on July 21, 2024

I did another check and this time created daily repeat event and checked it in both project. You are right, SwiftUI shows exactly the same relative time for all events. I am pretty sure this is some dumb mistake that I made.

from ekeventkit.example.

nemecek-filip avatar nemecek-filip commented on July 21, 2024

Okay, it is fixed. The issue was in the EKEvent extension to make it conform to Identifiable. I removed it, added manual id to ForEach and not it works exactly as UIKit version. @my4paws

from ekeventkit.example.

my4paws avatar my4paws commented on July 21, 2024

Confirmed it's fixed.
Awesome work. Thank you so much!

from ekeventkit.example.

nemecek-filip avatar nemecek-filip commented on July 21, 2024

Great`

from ekeventkit.example.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.