continuedev / continue

⏩ Continue is the leading open-source AI code assistant. You can connect any models and any context to build custom autocomplete and chat experiences inside VS Code and JetBrains
https://docs.continue.dev/
Apache License 2.0
13.76k stars 972 forks source link

Hang when opening tab in large codebase #1395

Open andaag opened 1 month ago

andaag commented 1 month ago

Before submitting your bug report

Relevant environment info

- OS: Fedora 40
- Continue:0.9.147 & pre release
- IDE: VSCode 1.89.1

Description

Opening it in a clean workspace I can use it, and it's very cool!

Opening it in the main codebase I work in I just get a progress bar - forever. There is no extra output in the developer console log other than:

An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing.

And there's no output in the extension host window either.

If I trigger reload window I do get it up. But then it gets stuck on Indexing 25%.

Output from developer tools during this:

 INFO Started local extension host with pid 1856937.
log.ts:439   ERR Extension 'github.copilot-chat' appears in product.json but enables LESS API proposals than the extension wants.
package.json (LOSES): extensionsAny, newSymbolNamesProvider, interactive, chatProvider, codeActionAI, findTextInFiles, findFiles2, textSearchProvider, terminalDataWriteEvent, terminalExecuteCommandEvent, terminalSelection, terminalQuickFixProvider, mappedEditsProvider, aiRelatedInformation, chatParticipant, chatParticipantAdditions, defaultChatParticipant, chatVariableResolver, contribSourceControlInputBoxMenu, authLearnMore, testObserver, aiTextSearchProvider
product.json (WINS): interactive, terminalDataWriteEvent, terminalExecuteCommandEvent, terminalSelection, terminalQuickFixProvider, chatParticipant, chatParticipantAdditions, defaultChatParticipant, chatVariableResolver, chatProvider, mappedEditsProvider, aiRelatedInformation, codeActionAI, findTextInFiles, textSearchProvider, contribSourceControlInputBoxMenu, newSymbolNamesProvider, findFiles2, extensionsAny, authLearnMore, testObserver
webviewElement.ts:482 An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing.
mountTo @ webviewElement.ts:482
P @ overlayWebview.ts:249
claim @ overlayWebview.ts:135
mc @ webviewViewPane.ts:165
(anonymous) @ webviewViewPane.ts:96
y @ event.ts:1156
z @ event.ts:1167
fire @ event.ts:1191
setVisible @ viewPane.ts:412
(anonymous) @ viewPaneContainer.ts:687
setVisible @ viewPaneContainer.ts:687
setVisible @ panecomposite.ts:53
Eb @ compositePart.ts:280
Eb @ paneCompositePart.ts:230
Cb @ compositePart.ts:158
Bb @ compositePart.ts:122
Bc @ paneCompositePart.ts:483
openPaneComposite @ paneCompositePart.ts:463
await in openPaneComposite (async)
openPaneComposite @ paneCompositePartService.ts:49
(anonymous) @ layout.ts:1026
await in (anonymous) (async)
Kb @ layout.ts:1032
sc @ workbench.ts:429
(anonymous) @ workbench.ts:191
invokeFunction @ instantiationService.ts:106
startup @ workbench.ts:154
open @ desktop.main.ts:131
await in open (async)
ne @ desktop.main.ts:403
d.load.configureDeveloperSettings @ workbench.js:2728
(anonymous) @ workbench.js:2600
_invokeFactory @ workbench.js:1395
complete @ workbench.js:1405
_onModuleComplete @ workbench.js:2021
_onModuleComplete @ workbench.js:2033
_resolve @ workbench.js:1979
defineModule @ workbench.js:1629
f @ workbench.js:2070
(anonymous) @ workbench.common.main.ts:163
(anonymous) @ fake:1
console.ts:137 [Extension Host] Found server at /home/neuron/.vscode/extensions/hashicorp.terraform-2.30.1-linux-x64/bin/terraform-ls
3console.ts:137 [Extension Host] Error calling Ollama /api/show endpoint: Error: Failed to connect to local Ollama instance. To start Ollama, first download it at https://ollama.ai.
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
log.ts:429  WARN [remote-ssh]: Couldn't find message for key setting.usseExecServer.description.
log.ts:419  INFO [perf] Render performance baseline is 18ms
log.ts:419  INFO Extension host (LocalProcess pid: 1856937) is unresponsive.

I just want the chat to work so I'd be fine with disabling indexing really, but I haven't seen that as an option.

To reproduce

Open in large python codebase

Log output

Continue - LLM Prompt output in vscode is completely empty.
andaag commented 1 month ago

I nuked $HOME/.continue folder and now I get far more interesting output.

Opening up the extension now I do see the chat interface. It still gets stuck at 25% though:

 INFO Started local extension host with pid 1891565.
log.ts:439   ERR Extension 'github.copilot-chat' appears in product.json but enables LESS API proposals than the extension wants.
package.json (LOSES): extensionsAny, newSymbolNamesProvider, interactive, chatProvider, codeActionAI, findTextInFiles, findFiles2, textSearchProvider, terminalDataWriteEvent, terminalExecuteCommandEvent, terminalSelection, terminalQuickFixProvider, mappedEditsProvider, aiRelatedInformation, chatParticipant, chatParticipantAdditions, defaultChatParticipant, chatVariableResolver, contribSourceControlInputBoxMenu, authLearnMore, testObserver, aiTextSearchProvider
product.json (WINS): interactive, terminalDataWriteEvent, terminalExecuteCommandEvent, terminalSelection, terminalQuickFixProvider, chatParticipant, chatParticipantAdditions, defaultChatParticipant, chatVariableResolver, chatProvider, mappedEditsProvider, aiRelatedInformation, codeActionAI, findTextInFiles, textSearchProvider, contribSourceControlInputBoxMenu, newSymbolNamesProvider, findFiles2, extensionsAny, authLearnMore, testObserver
console.ts:137 [Extension Host] Found server at /home/neuron/.vscode/extensions/hashicorp.terraform-2.30.1-linux-x64/bin/terraform-ls
3console.ts:137 [Extension Host] Error calling Ollama /api/show endpoint: Error: Failed to connect to local Ollama instance. To start Ollama, first download it at https://ollama.ai.
w @ console.ts:137
log.ts:439   ERR [Extension Host] [chat] Registration of interactive providers failed: Error: Extension 'GitHub.copilot-chat' CANNOT use API proposal: aiTextSearchProvider.
Its package.json#enabledApiProposals-property declares: interactive, terminalDataWriteEvent, terminalExecuteCommandEvent, terminalSelection, terminalQuickFixProvider, chatParticipant, chatParticipantAdditions, defaultChatParticipant, chatVariableResolver, chatProvider, mappedEditsProvider, aiRelatedInformation, codeActionAI, findTextInFiles, textSearchProvider, contribSourceControlInputBoxMenu, newSymbolNamesProvider, findFiles2, extensionsAny, authLearnMore, testObserver but NOT aiTextSearchProvider.
 The missing proposal MUST be added and you must start in extension development mode or use the following command line switch: --enable-proposed-api GitHub.copilot-chat
console.ts:137 [Extension Host] [chat] Registration of interactive providers failed: Error: Extension 'GitHub.copilot-chat' CANNOT use API proposal: aiTextSearchProvider.
Its package.json#enabledApiProposals-property declares: interactive, terminalDataWriteEvent, terminalExecuteCommandEvent, terminalSelection, terminalQuickFixProvider, chatParticipant, chatParticipantAdditions, defaultChatParticipant, chatVariableResolver, chatProvider, mappedEditsProvider, aiRelatedInformation, codeActionAI, findTextInFiles, textSearchProvider, contribSourceControlInputBoxMenu, newSymbolNamesProvider, findFiles2, extensionsAny, authLearnMore, testObserver but NOT aiTextSearchProvider.
 The missing proposal MUST be added and you must start in extension development mode or use the following command line switch: --enable-proposed-api GitHub.copilot-chat
w @ console.ts:137
log.ts:419  INFO [perf] Render performance baseline is 25ms
log.ts:429  WARN [remote-ssh]: Couldn't find message for key setting.usseExecServer.description.
webviewElement.ts:482 An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing.
mountTo @ webviewElement.ts:482
P @ overlayWebview.ts:249
claim @ overlayWebview.ts:135
mc @ webviewViewPane.ts:165
(anonymous) @ webviewViewPane.ts:96
y @ event.ts:1156
z @ event.ts:1167
fire @ event.ts:1191
setVisible @ viewPane.ts:412
(anonymous) @ viewPaneContainer.ts:687
setVisible @ viewPaneContainer.ts:687
setVisible @ panecomposite.ts:53
Eb @ compositePart.ts:280
Eb @ paneCompositePart.ts:230
Cb @ compositePart.ts:158
Bb @ compositePart.ts:122
Bc @ paneCompositePart.ts:483
openPaneComposite @ paneCompositePart.ts:457
run @ paneCompositeBar.ts:772
u @ actions.ts:194
run @ actions.ts:185
onClick @ actionViewItems.ts:172
(anonymous) @ actionViewItems.ts:152
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/common/clickhouse.py 903
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/common/json_rpc.py 2335
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/common/json_rpc_downloader.py 3722
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/common/storage_downloader.py 696
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/data_quality/data_quality_checker.py 609
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/legacystreamer/base.py 1046
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/listener/evm.py 797
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/listener/generic.py 3175
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/listener/solana.py 539
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/sink/base.py 1607
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/sink/batch_queue.py 740
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
console.ts:137 [Extension Host] Chunk with more than 500 tokens constructed:  /home/neuron/src/nansen/nansen-raw-data/modules/sink/downloader/nodes/generic_evm.py 1035
w @ console.ts:137
$logExtensionHostMessage @ mainThreadConsole.ts:39
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
y @ event.ts:1156
fire @ event.ts:1187
fire @ ipc.net.ts:650
H.onmessage @ localProcessExtensionHost.ts:378
log.ts:419  INFO Extension host (LocalProcess pid: 1891565) is unresponsive.
localProcessExtensionHost.ts:275 Extension Host
localProcessExtensionHost.ts:276 Debugger attached.
log.ts:419  INFO UNRESPONSIVE extension host: starting to profile NOW
log.ts:419  INFO Extension host (LocalProcess pid: 1891565) is responsive.
log.ts:419  INFO UNRESPONSIVE extension host: received responsive event and cancelling profiling session
log.ts:429  WARN UNRESPONSIVE extension host: 'continue.continue' took 84.71342843339183% of 133.261ms, saved PROFILE here: 'file:///tmp/exthost-4d1827.cpuprofile'
log.ts:419  INFO Extension host (LocalProcess pid: 1891565) is unresponsive.
localProcessExtensionHost.ts:275 Extension Host
localProcessExtensionHost.ts:276 Debugger attached.
andaag commented 1 month ago

I was able to find this setting on discord:

"disableIndexing": true

With this it works fine!