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

maxStreak() doesn't work with frontmatter #299

Closed
JulianVJacobs opened this issue Jan 15, 2024 · 4 comments
Closed

maxStreak() doesn't work with frontmatter #299

JulianVJacobs opened this issue Jan 15, 2024 · 4 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@JulianVJacobs
Copy link

When doing a summary to find the maxStreak(), it seems to count the existence of the variable and not the value. I have tried different types: a checkbox, text with 1 and 0, number with 1 and 0. it always counts the instances even if they're all false or if they're a mixture of true and false. the sum() does work as expected, however.

Expected Behavior

It's expected to find the longest streak of true values.

Current Behavior

It seems to count the pages that have the searchTarget, whether they're true or false.

Steps to Reproduce (for bugs)

  1. Create a summary type report
  2. Set it to report the maxStreak() of a checkbox type
  3. Create a set of broken streaks
@lazyguru lazyguru added bug Something isn't working help wanted Extra attention is needed labels Jan 15, 2024
@lazyguru
Copy link
Collaborator

@JulianVJacobs could you please provide an example file or two along with the dataview query?

@JulianVJacobs
Copy link
Author

2024-01-01.md
2024-01-02.md
2024-01-03.md
2024-01-04.md
2024-01-05.md
2024-01-06.md
2024-01-07.md
2024-01-08.md
2024-01-09.md
2024-01-10.md
2024-01-11.md
tracker.md

None of the checkboxes are set to true, but somehow the streak is 11 days(s)

@JulianVJacobs
Copy link
Author

image

This is how the tracker looks for me regardless of the truth value of the checkboxes

@lazyguru
Copy link
Collaborator

1.13.2 has been released and this should now be fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants