# 게시물 하단에 "읽지 않은 항목이 1개 남았습니다"가 표시되지만 실제로는 읽지 않은 항목이 0개입니다

**URL:** https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817
**Category:** Bug
**Created:** [3월 12, 2022, 10:25오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817 "2022-03-12T22:25:39Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)
#### Post date: [3월 12, 2022, 10:25오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/1 "2022-03-12T22:25:39Z")

</div>

최근에 특정 토픽을 읽다가 토픽 하단까지 스크롤하면 "읽지 않은 항목이 1개 남았습니다"라는 메시지가 표시됩니다. 그런데 이 “1개” 링크를 클릭해 보면 실제로는 읽지 않은 항목이 하나도 남아 있지 않은 경우가 있습니다. 최근 [https://community.wanikani.com에서](https://community.wanikani.xn--com-k94n91q) 이 현상이 꽤 자주 일어나고 있는 것 같고, 이곳 메타 게시판에서도 한 번쯤 본 것 같습니다. 다만 이곳에서는 추적하는 토픽이 훨씬 적어서 문제가 나타날 기회가 적은 것 같습니다.

이번 최신 사례에서는 버그 리포트에 정확한 인용을 위해 해당 텍스트를 복사한 직후 "읽지 않은 항목이 1개 남았습니다"라는 문구가 사라지는 것을 확인했습니다. 따라서 읽지 않은 토픽 수를 업데이트하는 백그라운드 작업에 다소 긴 지연이 있는 것일 수도 있습니다. 아니면 다른 탭에서 카테고리 홈 페이지를 열었을 때 사라진 것일 수도 있고요. 이 추측들이 실제로 관련이 있는지 확신은 없지만, 혹시 모를 상황에 대비해 언급해 두었습니다.

---

<div class="post-metadata">

### Author: ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)
#### Post date: [3월 20, 2022, 2:17오전 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/2 "2022-03-20T02:17:53Z")

</div>

여전히 이 문제가 발생하고 있으며, 이제 토픽을 방문한 후 15초 이상 지나면 추가 게시물이 없는데도 해당 토픽이 실제로 읽지 않은 상태로 표시되는 경우도 보고되고 있습니다. 토픽을 읽은 시점과 시스템의 다른 부분에서 읽음으로 표시되는 시점 사이에 지연이 있는 것 같습니다.

---

<div class="post-metadata">

### Author: ![Slowhand](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/slowhand/32/57436_2.png) [@Slowhand](https://meta.discourse.org/u/Slowhand)
#### Post date: [3월 20, 2022, 12:40오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/3 "2022-03-20T12:40:24Z")

</div>

저희 포럼에서도 이 현상이 관찰되고 있습니다. 게시물을 올린 직후 “읽지 않은 메시지 1건” 알림이 뜨는데, 실제로는 새로운 내용이 없습니다(본인이 방금 게시물을 올린 사실만 제외하고는요).

---

<div class="post-metadata">

### Author: ![TheLOLxd2](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/thelolxd2/32/161563_2.png) [@TheLOLxd2](https://meta.discourse.org/u/TheLOLxd2)
#### Post date: [3월 22, 2022, 11:49오전 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/4 "2022-03-22T11:49:28Z")

</div>

며칠 전부터 [https://community.openstreetmap.org/에서](https://community.openstreetmap.org/%EC%97%90%EC%84%9C) 로그아웃 상태일 때 이 문제가 발생하고 있습니다. Discourse Meta에서는 로그인 상태든 로그아웃 상태든 이 문제가 발생하지 않습니다.  
~~방금 탭을 닫고 같은 브라우저 세션에서 새 탭을 열었습니다. 지금은 해결된 것 같습니다.~~  
[https://community.openstreetmap.org/t/proposal-new-categories-requirements-and-process/581에서](https://community.openstreetmap.org/t/proposal-new-categories-requirements-and-process/581%EC%97%90%EC%84%9C) 다시 이 문제가 발생했습니다.  
(세 번째 답글이 읽지 않음으로 표시된 것입니다.)

---

<div class="post-metadata">

### Author: ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)
#### Post date: [3월 28, 2022, 3:58오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/5 "2022-03-28T15:58:35Z")

</div>

팀에서 혹시 놓쳤을 수도 있어서 다시 한번 올립니다.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [3월 28, 2022, 10:43오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/6 "2022-03-28T22:43:33Z")

</div>

이 문제를 재현하지 못했지만, 명확한 재현 단계를 알아야 할 것 같습니다. 두 계정으로 재현해 볼 수 있을까요?

---

<div class="post-metadata">

### Author: ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)
#### Post date: [3월 29, 2022, 11:34오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/7 "2022-03-29T23:34:15Z")

</div>

**수정: 이 게시글은 자유롭게 읽으셔도 되지만, 아래 단계는 실제로는 정확하지 않습니다. 다음 게시글에 올바른 재현 단계를 담았습니다.**

> **잘못된 재현 단계를 포함한 원본 게시글**
>
> > [@sam](#):
> >
> > 명확한 재현 방법만 있으면 됩니다
> 
> 버그가 일관되지 않게 발생해서 정확한 재현 단계를 제시하기가 어렵습니다. 보통 이런 식으로 발생합니다:
> 
> - 홈 페이지의 링크에서 `/unread`로 이동합니다. 읽지 않은 토픽이 하나 있다고 가정해 보겠습니다.
> - 해당 읽지 않은 토픽을 열립니다.
> - 토픽을 읽은 후 페이지 하단으로 이동합니다.
> - 유일한 읽지 않은 토픽을 방금 열었는데도 페이지 하단에는 여전히 `읽지 않은 1건`이라고 표시됩니다.
> - `읽지 않은 1건` 링크를 클릭하여 `/unread`로 이동하면 읽지 않은 토픽이 아무것도 표시되지 않습니다.
> 
> > [@sam](#):
> >
> > 계정 2개를 만들어서 해보는 건 어떨까요?
> 
> 한 계정으로 토픽을 추적하고 다른 계정으로 해당 토픽에 게시글을 작성하는 것을 말씀하시는 거라면, 도움이 될 수 있겠네요. 버그가 충분히 자주 발생한다고 생각해서 몇 번만 시도하면 그 방식으로 재현할 수 있을 거라고 봅니다.
> 
> 이와 관련된 부분에서 지난 한 달 정도 사이에 변경된 점이 있나요? 정말로 갑자기 시작되었는데, [https://community.wanikani.com과](https://community.wanikani.xn--com-rg8l) 이곳 메타 포럼 모두에서 그랬습니다.

---

<div class="post-metadata">

### Author: ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)
#### Post date: [3월 29, 2022, 11:39오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/8 "2022-03-29T23:39:23Z")

</div>

우연히도, 위 단계를 게시하면서 _실제_ 재현 단계를 발견했을 수도 있습니다(아니면 단순히 또 다른 발생 방식일 뿐일 수도 있고, 확실치는 않습니다). 이전 게시글을 작성하던 중, 페이지 하단에 _올바르게_ `1개의 읽지 않은 항목`이 표시되어 있었습니다. 그러나 그 게시글을 제출하자마자 `2개의 읽지 않은 항목`으로 바뀌었는데, 이는 잘못된 것이었습니다. `2개의 읽지 않은 항목` 링크를 클릭하면 `/unread` 페이지로 이동하며, 실제로 읽지 않은 토픽이 하나뿐임을 확인했습니다. 내 게시글이었음에도 불구하고 읽지 않은 항목 수가 증가한 것처럼 보였는데, 이는 읽지 않은 항목 수에 영향을 주어서는 안 되는 상황이었습니다. 이 현상이 일관되게 발생한다면, 이전 단계보다 이 단계를 통해 버그를 재현하는 것이 더 유용할 것입니다.

수정: 과연, 이 게시글을 제출하자마자 다시 `2개의 읽지 않은 항목`으로 잘못 바뀌었습니다. 몇 초간 그 상태로 있다가 올바른 `1개의 읽지 않은 항목`으로 돌아왔습니다. 따라서 이 단계를 통해 재현이 가능할 것 같습니다. 🙂

수정 2: [https://community.wanikani.com에서](https://community.wanikani.xn--com-k94n91q) 제가 추적 중인 토픽에 게시글을 남겼는데, 이 경우에도 읽지 않은 항목 링크가 표시되지 않다가 `1개의 읽지 않은 항목`으로 잘못 표시되었습니다. 이번에는 페이지가 실제로 읽지 않은 토픽이 없다는 것을 인식하는 데 1분이나 걸렸고, 그때서야 링크가 다시 사라졌습니다. 이제 이 게시글의 단계를 통해 3번 연속으로 문제를 재현했으므로, 이 단계를 통해 일관되게 재현될 것이라고 생각합니다.

---

<div class="post-metadata">

### Author: ![Slowhand](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/slowhand/32/57436_2.png) [@Slowhand](https://meta.discourse.org/u/Slowhand)
#### Post date: [3월 30, 2022, 1:09오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/9 "2022-03-30T13:09:05Z")

</div>

@seanblue님의 재현 사례를 확인했는데, 우리의 상황은 다릅니다.

처음에는 읽지 않은 항목이 없다가, 새 게시글을 작성한 뒤 메인 페이지로 돌아가면 방금 작성한 게시글이 읽지 않은 항목 1건으로 표시되어 있습니다. 읽지 않은 항목 카테고리를 클릭해야 이를 해제할 수 있습니다.

---

<div class="post-metadata">

### Author: ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)
#### Post date: [3월 30, 2022, 4:14오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/10 "2022-03-30T16:14:51Z")

</div>

저는 그게 같은 현상이라고 생각합니다. 0에서 1로, 혹은 1에서 2로 읽지 않은 메시지가 증가하는 경우뿐 아니라, 토픽 하단이나 메인 페이지에 표시될 때도 마찬가지입니다. 위에서 언급했듯이, 제가 처음 제시한 재현 방법은 틀렸습니다. 이를 더 명확히 하기 위해 게시물을 추가로 수정하겠습니다.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [3월 31, 2022, 6:27오전 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/11 "2022-03-31T06:27:56Z")

</div>

훌륭하네요, Sean! 이번 주에 한번 확인해서 이 엣지 케이스를 해결할 수 있을지 알아보겠습니다. 저도 몇 주째 신경 쓰였던 문제라 재현 방법을 알려주셔서 감사합니다.

![image](https://global.discourse-cdn.com/meta/original/3X/d/7/d7e3e4618fd627b3ddbacdf457313d463dcaa280.png)

![image](https://sea3.discourse-cdn.com/meta/images/transparent.png)

🤯 😮

이 주제에 게시물을 작성하던 중 재현되었습니다. 읽지 않은 메시지 수가 305개에서 306개로 증가했습니다.

---

<div class="post-metadata">

### Author: ![Slowhand](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/slowhand/32/57436_2.png) [@Slowhand](https://meta.discourse.org/u/Slowhand)
#### Post date: [4월 13, 2022, 1:11오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/17 "2022-04-13T13:11:14Z")

</div>

이 부분에 대해 업데이트가 있나요?

---

<div class="post-metadata">

### Author: ![martin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/martin/32/491371_2.png) [@martin](https://meta.discourse.org/u/martin)
#### Post date: [4월 14, 2022, 5:28오전 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/19 "2022-04-14T05:28:25Z")

</div>

현재 이 문제를 포함해 읽지 않은 항목과 새 주제와 관련된 다른 문제들을 처리하고 있습니다. 부활절로 인해 이번 주 안에 수정이 완료되지 않을 가능성이 높지만, 다음 주에도 계속 조사하겠습니다.

---

<div class="post-metadata">

### Author: ![ganncamp](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ganncamp/32/106199_2.png) [@ganncamp](https://meta.discourse.org/u/ganncamp)
#### Post date: [4월 18, 2022, 1:19오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/20 "2022-04-18T13:19:25Z")

</div>

참고로, 내 경우 ‘읽지 않음’ 알림은 1분 후에도 사라지지 않습니다. 알림을 없애려면 페이지를 새로고침해야 합니다.

---

<div class="post-metadata">

### Author: ![martin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/martin/32/491371_2.png) [@martin](https://meta.discourse.org/u/martin)
#### Post date: [4월 20, 2022, 1:26오전 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/21 "2022-04-20T01:26:33Z")

</div>

최근 이 pull request를 병합했는데, 이로 인해 문제가 해결되었을 것입니다. 비슷한 문제가 여전히 발생하고 있다면 알려주세요:

> <https://github.com/discourse/discourse/pull/16474>
>
> This commit fixes two issues at play. The first was introduced
> in f6c852bf8e7f4…dea519425ba87a114f22f52a8f4 (or maybe not introduced
> but rather revealed). When a user posted a new message in a topic,
> they received the \`unread\` topic tracking state MessageBus message,
> and the Unread (X) indicator was incremented by one, because with the
> aforementioned perf commit we "guess" the correct last read post
> for the user, because we no longer calculate individual users' read
> status there. This meant that every time a user posted in a topic
> they tracked, the unread indicator was incremented. To get around
> this, we can just exclude the user who created the post from the
> target users of the \`unread\` state message.
> 
> The second issue was related to the private message topic tracking
> state, and was somewhat similar. Whenever a user created a new private
> message, the New (X) indicator was incremented, and could not be
> cleared until the page was refreshed. To solve this, we just don't
> update the topic state for the user when the \`new\_topic\` tracking state
> message comes through if the user who created the topic is the
> same as the current user.
> 
> cf. https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [4월 21, 2022, 8:57오전 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/22 "2022-04-21T08:57:25Z")

</div>



---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [4월 27, 2022, 2:41오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/23 "2022-04-27T14:41:51Z")

</div>



---

<div class="post-metadata">

### Author: ![ganncamp](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ganncamp/32/106199_2.png) [@ganncamp](https://meta.discourse.org/u/ganncamp)
#### Post date: [4월 27, 2022, 2:36오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/24 "2022-04-27T14:36:35Z")

</div>

메인 스레드에서 후속 내용을 남기고 싶은데, 스레드가 닫혀 있습니다:

> [@게시물 하단에 "읽지 않은 항목이 1개 남았습니다"가 표시되지만 실제로는 읽지 않은 항목이 0개입니다](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/21?u=ganncamp):
>
> I merged this pull request recently which should solve the issue, let me know if any similar issues are still occurring: [https://github.com/discourse/discourse/pull/16474](https://github.com/discourse/discourse/pull/16474)

현재 호스팅 인스턴스에서 간헐적으로 이 문제가 발생하고 있습니다:

 ![Selection_139](https://global.discourse-cdn.com/meta/original/4X/8/a/a/8aac70809cb0099de957c75adbb0ff74e342afed.png)

---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [4월 27, 2022, 2:43오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/25 "2022-04-27T14:43:01Z")

</div>

> [@ganncamp](#):
>
> 메인 스레드에서 후속 글을 남기고 싶지만, 스레드가 닫혀 있습니다:

다시 열었고, 글을 이동했습니다. 👍

---

<div class="post-metadata">

### Author: ![ganncamp](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ganncamp/32/106199_2.png) [@ganncamp](https://meta.discourse.org/u/ganncamp)
#### Post date: [5월 27, 2022, 12:28오후 UTC](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817/26 "2022-05-27T12:28:38Z")

</div>

기록을 위해 말씀드리면, 호스팅된 사이트에서 여전히 이 문제가 발생하고 있습니다.

 ![Selection_181](https://global.discourse-cdn.com/meta/original/4X/c/7/b/c7bd22bd7190285a8bea257e9187267db7ce9579.png)

수정: 사이트 내 탐색 중에 발생하는 것 같습니다.  
제 워크플로우:

- Latest(내 홈페이지)를 아래로 스크롤하고 관심 있는 스레드를 새 탭으로 엽니다.
- 탭을 닫고 다시 Latest 목록으로 돌아옵니다.
- 로고를 클릭하여 새로고침합니다. 추가 알림 없음
- New / Unread를 클릭합니다.
- 로고를 클릭하여 Latest로 돌아옵니다. 추가 알림 발생

수정2: 대안 워크플로우:

- 주말 전에 열려 있던 몇 개의 탭을 답변하고 Latest로 돌아옵니다: 추가 알림 없음
- 상단에 추가된 업데이트된 스레드를 보기 위해 링크를 클릭 → 제가 업데이트한 스레드이지만 추가 알림 없음
- 점진적 로딩이 시작될 정도로 충분히 아래로 스크롤하고, 필요에 따라 새 탭을 엽니다
- 위로 다시 스크롤 =\> 첫 번째 단계 전에 업데이트한 스레드에 추가 알림 발생

[다음 페이지](https://meta.discourse.org/t/bottom-of-topic-shows-there-is-1-unread-remaining-when-there-are-actually-0-unread-topics-remaining/220817.md?page=2)
