Gruntfuggly / todo-tree

Use ripgrep to find TODO tags and display the results in a tree view
Other
1.42k stars 137 forks source link

TODO Tree not showing anything after scan #641

Closed ZPHannesD closed 1 year ago

ZPHannesD commented 2 years ago

Hi @Gruntfuggly ,

i just installed TODO tree (v0.0.215) in VSCode and its not showing the "TODO" Tab in explorer and so not showing any TODOS somewhere. Highlighting options work fine. My Debug output is as follows:

14:44:59.068 Searching d:\Projekte\VSCode_workspace\satellitehost/application...
14:44:59.072 Writing pattern file:c:\Users\User Name\AppData\Roaming\Code\User\workspaceStorage\901aed3405d2310981e28e1118abd086\Gruntfuggly.todo-tree\8sintuxnk.txt
14:44:59.072 Pattern:(//|#|<!--|;|/\*|^|^[ \t]*(-|\d+.))\s*(\[x\]|\[ \]|XXX|TODO|HACK|FIXME|BUG)
14:44:59.073 Command: "D:\Programme\Microsoft VS Code\resources\app\node_modules.asar.unpacked\@vscode\ripgrep\bin\rg.exe" --no-messages --vimgrep -H --column --line-number --color never --max-columns=1000 --no-config  -f "c:\Users\User Name\AppData\Roaming\Code\User\workspaceStorage\901aed3405d2310981e28e1118abd086\Gruntfuggly.todo-tree\8sintuxnk.txt" -g "!**/node_modules" "d:\Projekte\VSCode_workspace\satellitehost/application"
14:44:59.252 Search results:
d:\Projekte\VSCode_workspace\satellitehost/application\src\zp_settings.c:73:9:        // TODO ip could also be hostname -> save as string
d:\Projekte\VSCode_workspace\satellitehost/application\src\zp_settings.c:101:90:    // uint8_t broker1_default[] = {10,6,0,19}, compare_ff[] = {0xFF, 0xFF, 0xFF, 0xFF}; // TODO replace with broker discovery
d:\Projekte\VSCode_workspace\satellitehost/application\src\rf.c:98:4:           //TODO: Check if default is ethernet and if it is really connected. It is just an example here...
d:\Projekte\VSCode_workspace\satellitehost/application\src\main.c:71:2: // TODO return value handling for start functions
d:\Projekte\VSCode_workspace\satellitehost/application\src\main.c:72:2: // TODO Do we name them start or init?
d:\Projekte\VSCode_workspace\satellitehost/application\src\http_handler.c:247:2:    // TODO mutex lock and make client global to use in response function
d:\Projekte\VSCode_workspace\satellitehost/application\src\eth_handler.c:75:43:        case BROKER_1_IP_ADDR:  return 0; // TODO
d:\Projekte\VSCode_workspace\satellitehost/application\src\eth_handler.c:76:43:        case BROKER_2_IP_ADDR:  return 0; // TODO

14:44:59.848  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\zp_settings.c","line":73,"column":9,"match":"        // TODO ip could also be hostname -> save as string","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/zp_settings.c","scheme":"file"}}
14:44:59.849  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\zp_settings.c","line":101,"column":90,"match":"    // uint8_t broker1_default[] = {10,6,0,19}, compare_ff[] = {0xFF, 0xFF, 0xFF, 0xFF}; // TODO replace with broker discovery","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/zp_settings.c","scheme":"file"}}
14:44:59.849  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\rf.c","line":98,"column":4,"match":"\t\t\t//TODO: Check if default is ethernet and if it is really connected. It is just an example here...","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/rf.c","scheme":"file"}}
14:44:59.850  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\main.c","line":71,"column":2,"match":"\t// TODO return value handling for start functions","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/main.c","scheme":"file"}}
14:44:59.850  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\main.c","line":72,"column":2,"match":"\t// TODO Do we name them start or init?","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/main.c","scheme":"file"}}
14:44:59.850  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\http_handler.c","line":247,"column":2,"match":"\t// TODO mutex lock and make client global to use in response function","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/http_handler.c","scheme":"file"}}
14:44:59.851  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\eth_handler.c","line":75,"column":43,"match":"        case BROKER_1_IP_ADDR:  return 0; // TODO","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/eth_handler.c","scheme":"file"}}
14:44:59.851  Match (File): {"fsPath":"d:\\Projekte\\VSCode_workspace\\satellitehost/application\\src\\eth_handler.c","line":76,"column":43,"match":"        case BROKER_2_IP_ADDR:  return 0; // TODO","uri":{"$mid":1,"path":"/d:/Projekte/VSCode_workspace/satellitehost/application/src/eth_handler.c","scheme":"file"}}
14:44:59.851 Found 8 items
14:44:59.852 Applying globs to 8 items...
14:44:59.855 Remaining items: 8

with my settings.json

{
    "workbench.colorTheme": "Default Dark+",
    "C_Cpp.updateChannel": "Insiders",
    "cmake.configureOnOpen": false,
    "cortex-debug.showRTOS": true,
    "workbench.colorCustomizations": {
        "editor.lineHighlightBackground": "#1073cf2d",
        "editor.lineHighlightBorder": "#9fced11f"
    },
    "editor.wordWrap": "off",
    "diffEditor.wordWrap": "off",
    "editor.guides.indentation": true,
    "editor.guides.bracketPairs": true,
    "editor.inlayHints.enabled": false,
    "files.autoSave": "afterDelay",
    "security.workspace.trust.untrustedFiles": "open",
    "bracket-pair-colorizer-2.depreciation-notice": false,
    "todo-tree.general.enableFileWatcher": true,
    "todo-tree.general.debug": true,
    "todo-tree.general.rootFolder": "${workspaceFolder}/application",
    "todo-tree.ripgrep.ripgrep": "D:\\Programme\\Microsoft VS Code\\resources\\app\\node_modules.asar.unpacked\\@vscode\\ripgrep\\bin\\rg.exe"
}

So I guess scanning files is working fine but why isn't it displaying the TODO tab in explorer?

Sincerely, HD

michidk commented 2 years ago

Same issue here. The plugin stopped working a few months ago.

Lupus590 commented 1 year ago

I fixed this on mine by editing the regex.

I would copy what you have and save it somewhere and then try the generic catchall regex to see if that works.

If the generic one works then you can either keep it or adapt what you had originally so that it recognises the comments of whatever language you are using.

https://github.com/Gruntfuggly/todo-tree/wiki/Configuration-Examples#generic-catchall

Gruntfuggly commented 1 year ago

I think it's more likely that the view has gone missing.

If you go to the "View" menu, then select "Open view...", you should find Todo Tree in the list. Hopefully clicking it will reveal the view. You can then drag it to the explorer pane or wherever else you want it.

Gruntfuggly commented 1 year ago

Closing due to lack of updates - if this is still an issue, please feel free to reopen.