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

[Bug] OC says that a challenge ends in 4 days, but it has added 4 days ago #2418

Closed
3 tasks done
tschaffter opened this issue Dec 19, 2023 · 6 comments · Fixed by #2419 or #2489
Closed
3 tasks done

[Bug] OC says that a challenge ends in 4 days, but it has added 4 days ago #2418

tschaffter opened this issue Dec 19, 2023 · 6 comments · Fixed by #2419 or #2489
Assignees
Labels
bug Something isn't working data frontend Frontend development

Comments

@tschaffter
Copy link
Member

tschaffter commented Dec 19, 2023

Is there an existing issue for this?

  • I have searched the existing issues

What product(s) are you seeing the problem on?

OpenChallenges

Current behavior

Consider this challenge.

The card shows that the challenge is active ends in 4 days.

image

but the end date is "2023-12-15" (4 days ago).

Expected behavior

The challenge should be marked as complete and it should says that it has completed 4 days ago.

Anything else?

  • The status is out of date because it has changed since the last time the OC Data sheet was exported (more than 4 days ago).
  • One of the priorities of 2024 will be to update the status more frequently, e.g. using a scheduled job to update the status in the DB based on rules and start/end date.
  • The label "ends in 4 days" is probably because of a bug that should be fixed as part of this ticket.

Cc: @rrchai

Commit ID

dad6440

Are you developing inside the dev container?

  • I am using the dev container

Code of Conduct

  • I agree to follow this project's Code of Conduct
@tschaffter
Copy link
Member Author

@vpchung The proposed solution does not prevent the issue from happening again.

@rrchai @vpchung What are the solutions that you can think of that could solve this issue once for all?

@tschaffter tschaffter reopened this Jan 9, 2024
@tschaffter
Copy link
Member Author

Moved to Sprint 24.01

@rrchai
Copy link
Contributor

rrchai commented Jan 24, 2024

As we curate the DB and update the status of challenges weekly, there could be a 7-day window that exposes opportunities for mismatches (the actual dates & status shown on challenge card & time info "Started ... ago" etc.), which could potentially impact the user experience. Suggested proposals:

Proposal 1

  • We still manually update the challenge in DB weekly
  • Add dynamic validation to check if 'upcoming' challenges become 'active', and if 'active' challenges become 'completed'.
  • Display the most updated status.

Proposal 2

  1. Let challenge have two properties related to its status.
  2. Future: only developers can alter isCompleted - can choose a date (>=Now) or leave blank for endDate.
  3. Future: proposed start/end dates are required properties if not yet and organizers are responsible to update dates to reflect status.

I could also quickly do proposal 1 to solve the issues for any future potential mismatches (only 1 as of 1-24-2024).


Some stats with current challenges data:

  • challenges outdated: 1 ("Frost Hacks")
  • challenges without both dates: 117
  • challenges with start date, but no end date: 56
  • challenges with end date, but no start date: 58

@tschaffter
Copy link
Member Author

After giving this issue more though, I think the best strategy is to update the frequency of the data to daily.

@vpchung Could you create a CI workflow that update the OC data once a day?

@tschaffter
Copy link
Member Author

Thanks @rrchai for the suggested solution. As per our discussion, we will increase the frequency of the data updates. @vpchung is currently working the GH workflow that will automate the transformation from Google sheet to CSV.

@tschaffter
Copy link
Member Author

Added to Sprint 24.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working data frontend Frontend development
Projects
None yet
2 participants