Skip to content

Conversation

@williscool
Copy link
Owner

@williscool williscool commented Dec 25, 2025

image

refs #90 #89 and #87

  • feat: show next alert time
  • test: wip
  • fix: display string and roboelectric tests
  • fix: feature works plus test activity

Note

Cursor Bugbot is generating a summary for commit 100762a. Configure here.

@williscool williscool changed the title feat/show next alert time feat: show next alert time Dec 25, 2025
private const val CALENDAR_IS_HANDLED_KEY_PREFIX = "calendar_handled_"

private const val SNOOZE_PRESET_KEY = "pref_snooze_presets" //"15m, 1h, 4h, 1d"
private const val DISPLAY_NEXT_ALERT_TIME = "pref_display_next_alert_time" //false
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

alert or reminder?

.map { this.startTime - it.millisecondsBefore }
.filter { it > anchor }
return futureReminders.maxOrNull()
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function returns furthest reminder instead of soonest one

The getNextAlertTimeAfter function uses maxOrNull() which returns the furthest future reminder, but the name and intended use suggest it should return the soonest one. The existing getNextEventReminderTime function in CalendarProvider.kt correctly uses minOrNull() for the same purpose. When a notification shows "reminder in 1h45m" but there's actually a reminder in 1h, users will be surprised by the earlier notification. This function should use minOrNull() instead.

Fix in Cursor Fix in Web

// startActivity(
// Intent(Intent.ACTION_VIEW).setData(
// ContentUris.withAppendedId(
// )v_dfadsfadfadsf ContentUris.withAppendedId(
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Garbage text accidentally committed in comment

The line contains garbage text )v_dfadsfadfadsf that was accidentally inserted into an already-commented-out block. While this doesn't affect functionality since it's in a comment, it's unintended debris that should be removed.

Fix in Cursor Fix in Web

@github-actions
Copy link

Build artifacts for PR #132 (commit 9a9fcb8) are available:

You can download these artifacts from the "Artifacts" section of the workflow run.

@github-actions
Copy link

Code Coverage Report

Overall Project 33.89% -0.16% 🍏
Files changed 50.38%

Module Coverage
app 43.22% -0.01% 🍏
x8664Debug 24.7% -0.31%
Files
Module File Coverage
app EventFormatter.kt 75.97% -0.19% 🍏
Settings.kt 69.71% -0.47%
EventRecord.kt 48.63% -0.16% 🍏
x8664Debug EventFormatter.kt 71.23% -0.19% 🍏
EventRecord.kt 53.8% 🍏
Settings.kt 21.64% -0.47%
TestActivity.kt 0% -22.54%

@github-actions
Copy link

📊 Code Coverage Summary

Coverage Type Coverage
Overall 33.89
Changed Files 50.37

View detailed coverage report

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

Successfully merging this pull request may close these issues.

3 participants