أحداث تتبع مرعبة 👻

هناك أشياء من النوع التالي لاحظتها منذ أشهر، لكنني لم أقم بتقديم تقرير عنها أبدًا، لأنني لم أستطع إعادة إنتاجها بشكل متسق. ولكن، أخيرًا، عن طريق الخطأ، التقطت واحدة على الكاميرا! (لذلك يرجى التسامح مع التوقف والارتباك المنعكسين في حركات المؤشر الخاص بي).

الأشياء التي يجب الانتباه إليها هي:

  1. أن قائمة “غير مقروء” فارغة
  2. عرض Contribute > Feature كـ “عادي” (رغم تتبعه، كما يظهر في تفضيلاتي) ويظهر فقط كـ “مُتتبع” عند التحديث
  3. ظهور موضوع غامض في قائمة غير المقروء (من أيام مضت، من فئة كيفية الاستخدام)

النقطة الثانية تشبه إلى حد ما خطأً شائعًا أراه (ولكنني لم أتمكن أبدًا من إعادة إنتاجه على الفيديو) حيث سأقوم بالنقر على موضوع من “جديد” في فئة أراقبها، لكن حالته الخاصة لن تظهر كمُتتبع إلا إذا قمت بتحديث الصفحة. (أتساءل إذا كان ذلك مرتبطًا بهذا.)

قبل تسجيل هذا الفيديو بقليل، كنت أحاول إعادة إنتاج ذلك الخطأ من خلال تتبع #contribute:bug، ثم النقر على أحد مواضيعه من علامة التبويب “غير مقروء”. لم أتمكن من ذلك، ولكن بعد إلغاء تتبع #contribute:bug، امتلأت علامة التبويب “غير مقروء” بحوالي 20 موضوعًا مغلقًا في Contribute > Bug من حوالي عام 2015، وهو ما يبدو أنه نفس الخطأ المذكور في النقطة 3.

لا أفهم سبب حدوث ذلك. :ghost:

إعجابَين (2)

What are the repro steps?

إعجاب واحد (1)

There are two bugs here.

I can’t consistently reproduce the first, where the correct notification level is only shown after a refresh (of a category, or a topic). It’s been happening to me for months, but whenever I try to reproduce it, it doesn’t happen.

The second, which I think is a bit more minor, but still a nuisance can be reproduced (for a limited time only) like so:

  1. Clear /unread
  2. Track a category currently set to ‘Normal’
  3. Go back to /unread and observe posts not previously in it

I’ve been able to do this with a number of categories, but only once for each. Once I’ve dismissed the posts from unread, they never appear again.

Consistently reproducing it takes a little more work, so hold onto your hats, it’s gonna get a bit crazy:

  • Go to unread in a category of your choosing which has a notification level of “Normal”, observe nothing there:

  • List all the currently tracked topics in that category (and remember, or take a screenshot of them):

  • Enter a topic from that category not on that list:

  • Start tracking the category
  • Again list tracked topics in that category
  • Observe the topic you just opened in that list:

  • Go to unread, and again observe that topic in the list:


TL;DR

So, the bug here is that previously opened topics in a category become tracked, and appear in unread (unless previously dismissed), when the category is tracked, whereas nothing happens to old not-opened-before topics.

To me, what should happen is either:

  • Nothing changes about the notification status of old topics in a category when it becomes tracked, previously opened or not.

or

  • All old topics become tracked when the category is tracked, but are automatically dismissed, so only new activity appears in the unread tab.

I lean towards the second solution, provided explicitly set notification levels on topics are kept.

I haven’t investigated how this works with other notification levels, I imagine its the same, but I feel it would confuse things for the time being.

So in relation to

What part is considered as “not working as expected”?

إعجاب واحد (1)

جزآن:

الأول يتمثل في عدم تتبع المواضيع بشكل ضمني صحيح. لو كان التتبع الضمني يعمل بشكل صحيح، لظهرت جميع المواضيع من Community Building > Praise في هذه الخطوة:

يبدو أن هذه القائمة تعرض فقط المواضيع التي لديها سجل تتبع بحالة “تتبع” (tracked)، وهذا لا يعمل كما هو متوقع. والصحيح أن تكون القائمة تعرض جميع المواضيع التي لديها سجل تتبع بحالة “تتبع”، بالإضافة إلى جميع المواضيع الموجودة في فئة مُتتبعة. (والأمر نفسه ينطبق على المتابعة/المراقبة).

علاوة على ذلك، بينما يبدو هذا منطقياً:

يبدو أن نفس الوظيفة مفقودة عندما يقوم المستخدم بتتبع فئة. ألا ينبغي إنشاء سجل تتبع أيضاً عند وجود مشاركة جديدة في موضوع؟

الثاني يتمثل في ظهور مواضيع تبدو عشوائية وغير مقروءة عند تتبع فئة (أفترض أن ذلك نتيجة جانبية لتغيير حالة التتبع للمواضيع السابقة من “عادي” إلى “تتبع”)، ويمكن إصلاح ذلك عن طريق إخفاء تلك المواضيع تلقائياً من قائمة غير المقروءة.

What are your Preferences → Other
Consider topics new when
and
Automatically track topics I enter
settings?

I haven’t viewed them yet

never

إعجاب واحد (1)

هذا شيء وجدته منذ فترة، ويمكن العثور على موضوع حولها هنا (لست متأكدًا تمامًا لماذا تم نقله من Contribute > Bug إلى Contribute > Feature).

الموضوع محير بعض الشيء لأنني اعتقدت في البداية أن المشكلة ناتجة عن الاستيراد الأولي من phpBB. لذا، إليك محاولة لتلخيص الأمر:

الأمر يتعلق بحقيقة أن الموضوع لا يمكن أن يكون “جديدًا” و"غير مقروء" في نفس الوقت:

  • على الرغم من أنه مُتتبع ضمنيًا، إلا أن الموضوع لا يظهر في “غير مقروء” لأن المستخدم لم يشاهده من قبل
  • الموضوع لا يظهر في “جديد” لأنه يتجاوز الحد الزمني لإعدادك “اعتبار المواضيع جديدة عندما”

هذه مشكلة صعبة الحل، لأن ظهور كل موضوع قديم في فئة معينة في علامة التبويب “غير مقروء” ليس تجربة مستخدم جيدة حقًا.

“التجاهل التلقائي” لها مكلف جدًا من الناحية قاعدة البيانات (سيكون من الضروري إنشاء سجل TopicUser جديد لكل موضوع في الفئة التي قمت بتتبعها للتو).

لم نأتِ بفكرة أنيقة لحل المشكلة، وانتهى النقاش نوعًا ما. أحد الخيارات التي طرحها @sam كان:

في ذلك الوقت، اعتقدت أن هذه قد تكون فكرة جيدة:

ولكن

ملخص سريع: لا أملك حلاً، ولكن آمل أن يجعل هذا المشكلة أكثر وضوحًا :wink:

3 إعجابات

And for the other issue in this thread:

I can reproduce this consistently here on meta for categories. Repro steps:

  1. Go to your user preferences, remove all tracked categories
  2. Go to a category page, e.g. #meta, and observe that the ‘notification level’ indicator is “normal”
  3. Go immediately to your user preferences, by clicking your avatar in the top right, then the cog
  4. Add the category you just visited, e.g. #meta, to your “tracking” categories
  5. Press “save changes”
  6. Press the back button in your browser to return to #meta, and observe that the ‘notification level’ indicator is still “normal”
  7. Refresh the page, and observe that the ‘notification level’ is now “tracked”

If you replace step 6 with visiting the category page by some other route, the tracking status appears correctly.

5 إعجابات

From a practical perspective, that doesn’t make sense to me. If I buy a book and put it on my shelf having not opened it, it is both new and unread.

Wouldn’t it be possible to have an old topic (with no tracking record) only appear in unread when there’s new activity on it?

So, just as a tracking record is created on new activity for topics in watched categories, a tracking record would be created on new activity for topics in tracked categories.

Combined with the above, couldn’t we just dismiss topics where the tracking record has been changed to “tracking” as a result of tracking the category, which would mean the same user experience, without any additional database writes? (If I understand how tracking records, dismissing and TopicUser relate.)

This way, it seems to me, we could have a mailing list experience for tracking too! :smile:

Sure, I agree. I was talking purely about how it currently works in discourse.

I believe @sam thought this would have major performance issues

I’m 99% sure a new record isn’t created for tracked topics - @sam said “created when we notify users”, and tracking doesn’t cause notifications. Maybe fixing this is the solution :slight_smile:

إعجاب واحد (1)

Do you know if there’s an architectural issue which means the new/unread either/or has to be the case?

Indeed, I was proposing this as a solution which seems to not have any major performance issues.

إعجاب واحد (1)

I assume it’s by design - having a topic listed on the new tab and the unread tab would be a bit weird.

Taking your book analogy, while it can be both unread and new, you can’t put it on your “new” shelf and your “unread” shelf simultaneously :wink:

4 إعجابات

Ok… I’ve done some testing in my dev environment. As a simplest possible repro:

  1. Set previous visit timeout hours site setting to 0, to make testing quicker
  • User A sets “Consider topics new when” to “created since I was last here”
  • User A sets Category1 to tracked
  • User B posts in Category1
  • User A observes the topic in ‘new’, but does not open it
  • User A leaves the site
  • User A comes back to the site later, and User B’s post is gone from the ‘new’ tab
  • User B posts again in the same topic
  • The topic does not appear in either ‘new’ or ‘unread’ for User A, even though they are tracking the topic

That same repro works for ‘watching’ a category as well. A notification is sent, but no TopicUser row is created (checked on the rails console). It seems that this:

is not happening for some reason, both for watched and tracked categories.

إعجاب واحد (1)

Would it though? We already have topics listed in the latest tab and the new/unread tabs simultaneously. And the two (new and unread) are for different purposes: new is “show me the newest topics on this site” and unread is “show me topics I’ve expressed an interest in, but haven’t (finished) read(ing)”. For new to achieve its purpose it has to have unread topics in it which are new, and for unread to achieve its purpose it needs to have new topics in it which are unread.

Currently the unread tab is rather dysfunctional.

Interesting, thanks for doing all this investigation! So it would seem like if this did actually happen (or more specifically, a TopicUser row was created on topic update, rather than notification, to include tracked categories), then our problems here would be solved. @sam thoughts?

I am fine to change the semantics of “tracked category” so it means, if a category is tracked it will unconditionally show up in new regardless of your new duration, it does not mean this now.

4 إعجابات