todo-tree icon indicating copy to clipboard operation
todo-tree copied to clipboard

TODOs missing after appying `group by tag`

Open tigerinus opened this issue 1 year ago • 4 comments

before applying:

image

after applying:

image

version: v0.0.226

tigerinus avatar Apr 13 '23 14:04 tigerinus

same issue - now only shows "TODO" tags if in "tags only" view

julesgilson avatar Apr 19 '23 10:04 julesgilson

I'm having the same main issue ... but to complement on @julesgilson : when using "tags only" I also still get all of them (even with group by tag) ... but what happens to me when not in "tags only" ... I only get tags in one of the files (regardless of FIXME or TODO ...)

image

image

image

Hope this can help resolve the issue !!!

I LOVE that extension ... but that is ... really unfortunate since grouping by tags was one of my main feature of choice ! (but I also really always work with tree view ... )

kjorand avatar Jul 15 '23 22:07 kjorand

Saw a similar issue with the flat and tree views when Group By Tags is enabled. (BTW I am running a remote vscode session via SSH)

It seems like when changing configurations the scan mode switches to current file only mode for the tree and flat views as I am able to see the Tags show up when I change focus to the files in editor.

For my case the problem only occurs after making change to the Todo-Tree configuration , the issue resolves itself after restarting the extension host (sometimes) or the vscode application (always).

Hopefully some of this info might be helpful to fix the issue.

wznazir avatar Aug 31 '23 12:08 wznazir

I am able to recreate this issue, and found the cause.

Recreate

Setup

  • Default Todo Tree settings
  • open a new workspace in VS Code
  • TODOs view: Flat or Tree view, group-by-tags enabled

Steps

  1. Create a new file
  2. Add [ ] Test1 in the file
  3. Save the file in the workspace as file1.txt
  4. Create a new file
  5. Add [ ] Test2 in the file (do not save this file)

The TODOs view only shows Test2. image

Refresh does not fix it. Switching group-by-tags off, or changing to the tags only view, will display both todos correctly. However, switching back to either flat or tree view with Group-by-tags on will again cause todos to not be displayed.

Root Cause

I was able to pinpoint the issue to #660. Reverting this change fixes this issue, however it re-intorduces #562

Both this issue and #562 seem to be caused by the TreeNodeProvider.reset method defined in tree.js.

baincd avatar Mar 09 '24 15:03 baincd