microsoft / microsoft/copilot-for-eclipse
[Bug] TypeError: Cannot read properties of undefined (reading 'filter')
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 126
- Forks
- 60
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 5
Description
Environment
- OS: Windows
- Eclipse Version: 2026-06 (4.40.0)
- Plugin Version: 0.21.0.202608060743
Describe the bug
The following error occurs in the Agent mode when there is no project in the workspace:
!ENTRY org.eclipse.lsp4e 4 0 2026-08-26 07:45:09.023
!MESSAGE [LS:GitHub Copilot Language Server][Error] [chat] Error processing turn 72df12fd-e941-4394-adb4-2b5917d14ed7 TypeError: Cannot read properties of undefined (reading 'filter') (at tsx element AgentPrompt > UserMessage > SubagentListPrompt)
at y0.collect (C:\snapshot\copilot-language-server-internal\dist\main.js:2411:12762)
at t.listCustomAgents (C:\snapshot\copilot-language-server-internal\dist\main.js:2411:23507)
at async $de.getAgents (C:\snapshot\copilot-language-server-internal\dist\main.js:3333:954)
at async $de.getAgentsForModelDispatch (C:\snapshot\copilot-language-server-internal\dist\main.js:3333:1202)
at async Itt.renderCopilot (C:\snapshot\copilot-language-server-internal\dist\main.js:3333:3037)
at async annotateError (C:\snapshot\copilot-language-server-internal\dist\main.js:69:4311)
at async C:\snapshot\copilot-language-server-internal\dist\main.js:67:29695
at async Promise.all (index 0)
at async jZe._processPromptPieces (C:\snapshot\copilot-language-server-internal\dist\main.js:67:29606)
at async jZe._processPromptRenderPiece (C:\snapshot\copilot-language-server-internal\dist\main.js:67:30200)
!ENTRY org.eclipse.lsp4e 4 0 2026-08-26 07:45:09.024
!MESSAGE [LS:GitHub Copilot Language Server][Error] [agenticTurnProcessor] Error in processing turn 72df12fd-e941-4394-adb4-2b5917d14ed7 TypeError: Cannot read properties of undefined (reading 'filter') (at tsx element AgentPrompt > UserMessage > SubagentListPrompt)
at y0.collect (C:\snapshot\copilot-language-server-internal\dist\main.js:2411:12762)
at t.listCustomAgents (C:\snapshot\copilot-language-server-internal\dist\main.js:2411:23507)
at async $de.getAgents (C:\snapshot\copilot-language-server-internal\dist\main.js:3333:954)
at async $de.getAgentsForModelDispatch (C:\snapshot\copilot-language-server-internal\dist\main.js:3333:1202)
at async Itt.renderCopilot (C:\snapshot\copilot-language-server-internal\dist\main.js:3333:3037)
at async annotateError (C:\snapshot\copilot-language-server-internal\dist\main.js:69:4311)
at async C:\snapshot\copilot-language-server-internal\dist\main.js:67:29695
at async Promise.all (index 0)
at async jZe._processPromptPieces (C:\snapshot\copilot-language-server-internal\dist\main.js:67:29606)
at async jZe._processPromptRenderPiece (C:\snapshot\copilot-language-server-internal\dist\main.js:67:30200)
To Reproduce
Steps to reproduce the behavior:
- Open a new empty workspace with no project imported into it
- Ensure on the Chat window Agent mode is selected
- Ask a question to Copilot e.g: "What day is today?"
- See error
Expected behavior
No error should appear
Screenshots
Additional context
The problem does not occur if Ask mode is selected
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure in an empty Eclipse workspace with Chat in Agent mode, then start at the AgentPrompt > UserMessage > SubagentListPrompt path and the listCustomAgents/getAgents entry points named in the trace. Done means asking a question produces no TypeError when no project is present, while Ask mode continues to work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- developer-experience, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100