Wrong number of topics in categories in the hamburger-menu

I guess the number of topics in a category should be equal to the sum of topics in all its subcategories. but in the hamburger menu, it isn’t:

Untitled

the strange minus topic number happened at some time point where we added some sub-categories to the category and moved all topics from the main category to its’ subsequent sub-category.

1 Like

About this:

This is not the case on the other category selector either.

Though I can’t find anything from the search I’m pretty sure this has been discussed a few times (or more) and it would have been changed if they had no good reason to keep it this way.

That said I don’t really like this either as it can be somewhat confusing.
For example, I have an archive category which has 0 message:
image
This is confusing because it tells me at first glance that there is nothing to see in it. But it’s wrong!
If we click it anyway, we can notice that it is not empty and has some subcategories with messages:
image

1 Like

Hamburger shows the count of new+unread you have for the category, not the total.

The negative sign there does look strange, what is the new/unread count you see when you visit the category.

2 Likes

you are right, in fact my concern was about first-visit or not-logged in users, and the screenshots are also for anonymous user.

e.g. in meta, for not logged in user, you’ll see 21 topics in howto category, while there are lots more topics in its subcategories.

it’d be awkward if the number shows zero, as it gives the feeling that the category is empty. no number for not-logged in users would be much better.

1 Like

It is not counting sub-categories at the moment, I guess this is a fair comment it probably should in this context cause it is confusing otherwise.

3 Likes

OK fixed per:

https://github.com/discourse/discourse/commit/d9a9682f7219f1cf3b8cc5555f8a3157803ab7b0

5 Likes

just noted that for logged in user, the numbers in front of categories are different in hamburger and drop down:

should it be?

p.s.: maybe one shows total number of topics and the other is for unread. as a user I just got confused.

3 Likes

This is confusing, it does not show up like that for me… I will try to repro…

The hamburger is showing unread / new counts, the category drop down is showing raw counts. These are different things, @Pad_Pors is confused.

Note that for logged out users we have no concept of unread / new because the whole site is one big ball of new to you, the unlogged in user…

3 Likes

Oh… I totally missed that @Pad_Pors had 404 unread for some reason I only read the 27 number there.

@Pad_Pors yes the numbers are there by design and working as expected

2 Likes

Note, it is worth mentioning how much better this is on anonymous now:

You can properly tell the scale of the various categories, previously only counting top level totally skewed how useful the numbers were.

4 Likes