Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ui/desktop/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ src/bin/goose-npm/
/playwright-report/
/test-results/
/src/bin/temporal-service
src/bin/temporal.db
15 changes: 4 additions & 11 deletions ui/desktop/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@ const getInitialView = (): ViewConfig => {
export default function App() {
const [fatalError, setFatalError] = useState<string | null>(null);
const [modalVisible, setModalVisible] = useState(false);
const [appInitialized, setAppInitialized] = useState(false);
const [pendingLink, setPendingLink] = useState<string | null>(null);
const [modalMessage, setModalMessage] = useState<string>('');
const [extensionConfirmLabel, setExtensionConfirmLabel] = useState<string>('');
Expand Down Expand Up @@ -207,15 +206,10 @@ export default function App() {
toastService.configure({ silent: false });
};

(async () => {
try {
await initializeApp();
setAppInitialized(true);
} catch (error) {
console.error('Unhandled error in initialization:', error);
setFatalError(`${error instanceof Error ? error.message : 'Unknown error'}`);
}
})();
initializeApp().catch((error) => {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just reverting to the original implementation as setAppInitialized is not used anymore

console.error('Unhandled error in initialization:', error);
setFatalError(`${error instanceof Error ? error.message : 'Unknown error'}`);
});
}, [read, getExtensions, addExtension]);

const [isGoosehintsModalOpen, setIsGoosehintsModalOpen] = useState(false);
Expand Down Expand Up @@ -507,7 +501,6 @@ export default function App() {
)}
{view === 'chat' && !isLoadingSession && (
<ChatView
readyForAutoUserPrompt={appInitialized}
chat={chat}
setChat={setChat}
setView={setView}
Expand Down
6 changes: 1 addition & 5 deletions ui/desktop/src/components/ChatView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,11 @@ const isUserMessage = (message: Message): boolean => {
};

export default function ChatView({
readyForAutoUserPrompt,
chat,
setChat,
setView,
setIsGoosehintsModalOpen,
}: {
readyForAutoUserPrompt: boolean;
chat: ChatType;
setChat: (chat: ChatType) => void;
setView: (view: View, viewOptions?: ViewOptions) => void;
Expand All @@ -71,7 +69,6 @@ export default function ChatView({
return (
<ChatContextManagerProvider>
<ChatContent
readyForAutoUserPrompt={readyForAutoUserPrompt}
chat={chat}
setChat={setChat}
setView={setView}
Expand All @@ -87,7 +84,6 @@ function ChatContent({
setView,
setIsGoosehintsModalOpen,
}: {
readyForAutoUserPrompt: boolean;
chat: ChatType;
setChat: (chat: ChatType) => void;
setView: (view: View, viewOptions?: ViewOptions) => void;
Expand Down Expand Up @@ -627,7 +623,7 @@ function ChatContent({
isLoading={isLoading}
onStop={onStopGoose}
commandHistory={commandHistory}
initialValue={_input || initialPrompt}
initialValue={_input || (hasMessages ? _input : initialPrompt)}
setView={setView}
hasMessages={hasMessages}
numTokens={sessionTokenCount}
Expand Down
Loading