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

docs(cli): add warning if user counts are still being calculated #308

Merged
merged 2 commits into from
Jan 28, 2021

Conversation

xavdid
Copy link
Contributor

@xavdid xavdid commented Jan 27, 2021

Fixes PDE-1944

@xavdid xavdid requested a review from eliangcs January 27, 2021 19:47

if (versions[0].user_count === null) {
this.warn(
'User counts are still being calculated - run this command again in ~10 seconds (or longer if your integration has lots of users).'
Copy link
Member

Choose a reason for hiding this comment

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

The user count for each version is calculated independently, so it's possible that some versions have the count while some others don't.

So instead of only checking the first version, we should check all the versions. If there's any version having a null user_count. We should show this warning.

Also, I'd probably say "Some user counts are still being calculated" to avoid any confusion.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, fair point! Got lucky on an app having an exact test case:

Fixed in 9940fa6

Copy link
Member

@eliangcs eliangcs left a comment

Choose a reason for hiding this comment

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

Looks great, thanks!

@xavdid xavdid merged commit be47c23 into master Jan 28, 2021
@xavdid xavdid deleted the PDE-1944 branch January 28, 2021 17:35
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.

None yet

2 participants