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

Events are duplicated on the same day #11

Closed
arkangelx opened this issue Dec 4, 2015 · 6 comments
Closed

Events are duplicated on the same day #11

arkangelx opened this issue Dec 4, 2015 · 6 comments

Comments

@arkangelx
Copy link

Loading a json file with events that are on the same day but different in detail repeats those events multiple times. Events also don't appear on the right dates.
screenshot_2015-12-04-12-04-04 1

@arkangelx
Copy link
Author

@Tibolte
Copy link
Owner

Tibolte commented Dec 5, 2015

@arkangelx It's really hard to tell, but first thing I'd do when I see your event loading task in EventsFragment, place:
Calendar startTime = Calendar.getInstance();
Calendar endTime = Calendar.getInstance();
In the loop just below.
I remember having some problem when using one calendar instance for different event instances, I'd recommend creating a new Calendar instance for each event.
That might not solve it but I'd start there.

@arkangelx
Copy link
Author

Tried that...it didn't work then but will try again tho be sure
thanks....ps it loads past events...right?
On 5 Dec 2015 18:13, "Thibault Guégan" notifications@github.com wrote:

@arkangelx https://github.com/arkangelx It's really hard to tell, but
first thing I'd do when I see your event loading task, place:
Calendar startTime = Calendar.getInstance();
Calendar endTime = Calendar.getInstance();
In the loop just below.
I remember having some problem when using same calendar instances for
different instances, I'd recommend creating a new Calendar instance for
each event.
That might not solve it but I'd start there.


Reply to this email directly or view it on GitHub
#11 (comment)
.

@arkangelx
Copy link
Author

Strangely , it worked!!!! Thibault..i owe you a beer ...that's if you
drink!!!!! Wow thank you. The logic is simple and the only reason i can
think of is that because its a single initialized once (before loop),
changing its state somehow doesn't get retained in the list.. THANK
YOU!!!! I thought if i have 1000 events in a year would i want to create
so many references in memory, even though its a singleton. Thank you again

On Sat, Dec 5, 2015 at 6:16 PM, Samson Akisanya info@mobileparadigm.co.uk
wrote:

Tried that...it didn't work then but will try again tho be sure
thanks....ps it loads past events...right?
On 5 Dec 2015 18:13, "Thibault Guégan" notifications@github.com wrote:

@arkangelx https://github.com/arkangelx It's really hard to tell, but
first thing I'd do when I see your event loading task, place:
Calendar startTime = Calendar.getInstance();
Calendar endTime = Calendar.getInstance();
In the loop just below.
I remember having some problem when using same calendar instances for
different instances, I'd recommend creating a new Calendar instance for
each event.
That might not solve it but I'd start there.


Reply to this email directly or view it on GitHub
#11 (comment)
.

Innovate & Prevail

@Tibolte
Copy link
Owner

Tibolte commented Dec 5, 2015

That's good news!! I've been into this situation, happy to help. Thanks for the beer!!
p.s: If you think that's solved for you, I'm inviting you to close that issue.

@arkangelx
Copy link
Author

yeah..done

On 6 Dec 2015, at 00:16, Thibault Guégan notifications@github.com wrote:

That's good news!! I've been into this situation, happy to help. Thanks for the beer!!
p.s: If you think that's solved for you, I'm inviting you to close that issue.


Reply to this email directly or view it on GitHub #11 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants