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 NaN metrics bug #14

Merged
merged 5 commits into from
Jul 15, 2022

Conversation

NicksPatties
Copy link
Owner

Changes

  • Fixed behavior in event filtering and percentage calculation functions
  • Added Composable Previews and unit tests
  • Moved "No items" null check in AnalysisPage underneath TimeRangeSelector, allowing for navigation between different ranges
    • This prevents any weird behavior from occurring if a user has recorded events, but none during a specified date range, and then navigates to that AnalysisPane. Before these changes, the screen would say "No items" with no way to return to another screen.

Related issue

Fixes issue #11

Screenshots

Starting with no events
Event in progress
Finishing an event

Testing

  • Added unit tests to changed code
  • Added Preview composables to verify bug behavior and fixes
  • Manual testing

If there is an AnalysisRow in the list of analysisPageRows that has a time of 0, then that leads to NaN being printed on screen.
This occurs when an event has started, but has not completed, since the startTime and endTime is set to the same value.
…eText into its own file. Use NothingHereText if there are no rows to show.
@NicksPatties NicksPatties linked an issue Jul 14, 2022 that may be closed by this pull request
@NicksPatties
Copy link
Owner Author

New tests are being run in the new build. Hooray!

Previous build output: 21 tests run
Now: 23 tests run

@NicksPatties NicksPatties merged commit 9aead4b into master Jul 15, 2022
@NicksPatties NicksPatties deleted the 11-bug-metrics-screen-counting-incomplete-events branch July 15, 2022 21:21
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.

[BUG] Metrics screen counting incomplete events
1 participant