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

fix(scheduler): clear buried questions on new day #1199

Merged
merged 1 commit into from
Feb 2, 2025

Conversation

mparq
Copy link
Contributor

@mparq mparq commented Jan 6, 2025

the logic here seemed to be half-there but maybe missed in a refactor?
the method clearIfNewDay was already implemented but not used anywhere in the codebase. the method is now called and
questionPostponementList.write now sets buryDate to the current date when called.

the logic here seemed to be half-there but maybe missed in a
refactor?
the method clearIfNewDay was already implemented but not used anywhere
in the codebase. the method is now called and
questionPostponementList.write now sets `buryDate` to the current date
when called.
@mparq
Copy link
Contributor Author

mparq commented Jan 6, 2025

I'm not sure, but maybe fixes #1175 and #1192 (possibly others). @st3v3nmw let me know if this looks right. I am new to the codebase and it is pretty complex but the change is hopefully isolated. I just tried to solve this because I had the issue where my flashcards would never show up for review. This fix seems to fix the problem I was seeing but the nature of the fix seems to suggest that this would be broken for everybody using the bury sibling cards option?

@st3v3nmw st3v3nmw requested a review from ronzulu January 6, 2025 04:42
@st3v3nmw st3v3nmw self-requested a review February 2, 2025 13:35
Copy link
Owner

@st3v3nmw st3v3nmw left a comment

Choose a reason for hiding this comment

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

The fix overall makes sense but I'll update the function so that we can modify this.plugin.data directly instead of passing it.

P.S. I think we don't need the extra change in write since clearIfNewDay will already write data.buryDate.

@st3v3nmw st3v3nmw merged commit bcbe969 into st3v3nmw:master Feb 2, 2025
1 check passed
@mparq
Copy link
Contributor Author

mparq commented Feb 3, 2025

Thanks @st3v3nmw! That makes sense. I actually don't remember why, but I was seeing that the buryDate was never changing from null without updating this.plugin.data in write... but now that I'm looking at the code again I can't figure out why that would be. Feel free to remove it, it could have just been something with how I was testing the change.

KyleKlus pushed a commit to KyleKlus/obsidian-spaced-repetition that referenced this pull request Feb 3, 2025
st3v3nmw pushed a commit that referenced this pull request Feb 4, 2025
* FIX: Fixes any visual issues with the landscape mode of mobile devices

* ADD: Added documentation on how to change the ui and how to test these changes

* FIX: Redone session progress section & updated test for deck stats

* ADD: Added an explanation of how to switch between mobile emulation to the contributing docs

* ADD: Added link to pr in changelog

* ADD: Added test for multi level deck stats

* FIX: Fixed that spacing of info bar looks sometimes a bit off

* UPDATE: Made the deck info section bold & removed sub deck count from the chosen deck, if it is only one deck

* UPDATE: Adjustment of the icon stroke width such that the icons look just like the bold text

* UPDATE: Moved context trail permanently onto a separate line

* FIX: Formatted code

* Revert "FIX: Formatted code"

This reverts commit 5e84528.

* FIX: Another try of fixing the formatting

* Revert "FIX: Another try of fixing the formatting"

This reverts commit 6486c10.

* Revert "Merge branch 'master' into mobile-screen-rotation-fix"

This reverts commit b5e80ed, reversing
changes made to a015ce7.

* feat: add Ukrainian language support (#1215)

* fix: Change Decks list card count box size (#1211)

Change Decks list card count box size

Changed the minimum width of the boxes, that there will fit for numbers up to 9999. Currently there only will fit if the numbers are below 999 what in my case and certainly for others too is not enough.

* chore: update turkish translation (#1198)

* Update tr.ts

Türkçe yeni çeviriler eklendi ve bazıları güncellendi.

* Update tr.ts

* Update tr.ts

düzeltmeler ve güncelemeler yapıldı

* chore: update dependencies (#1216)

* chore: update dependencies (#1225)

* fix(scheduler): clear buried questions on new day (#1199)

* refactor: clearIfNewDay (#1226)

* FIX: Formatted code

* Revert "FIX: Formatted code"

This reverts commit 5e84528.

* FIX: Another try of fixing the formatting

* Revert "FIX: Another try of fixing the formatting"

This reverts commit 6486c10.

* Revert "Merge branch 'master' into mobile-screen-rotation-fix"

This reverts commit b5e80ed, reversing
changes made to a015ce7.

---------

Co-authored-by: Kyle Klus <[email protected]>
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.

2 participants