fix: Do not wait 5s before adding extensions to agent (#785)

This commit is contained in:
Alex Hancock
2025-01-25 23:22:05 -05:00
committed by GitHub
parent 9e3b2d1edb
commit 4404eaf3ed

View File

@@ -78,14 +78,9 @@ export const initializeSystem = async (provider: string, model: string) => {
console.log('initializing agent with provider', provider, 'model', model);
await addAgent(provider.toLowerCase(), model);
// TODO - Needs to be replaced with something which can interface
// with the agent to tell when it is ready to add extensions
setTimeout(() => {
window.electron.logInfo('Loading and adding stored extension configs');
loadAndAddStoredExtensions().catch((error) => {
console.error('Failed to load and add stored extension configs:', error);
});
}, 5000);
loadAndAddStoredExtensions().catch((error) => {
console.error('Failed to load and add stored extension configs:', error);
});
} catch (error) {
console.error('Failed to initialize agent:', error);
throw error;