- Change temp subdirectory from 'devchat/context' to 'devchat/action'.
- Add check for tempFile existence before unlinking.
- Add new test cases for actionManager and customAction.
- Import CustomActions from '../action/customAction'.
- Load custom actions from the workflows directory.
- Save action instruction file to the .chat directory.
- Add compressText function to truncate long text.
- Wrap applyAction in try-catch block for error handling.
- Send error message to devchat if codeBlock type is 'command'.
- Extracted getSelectedSymbol function to improve code readability.
- Fixed the scope of refLocations variable to avoid reference error.
- Added error handling for vscode.executeReferenceProvider command.
- Refactored the way symbol references are retrieved and handled.
- Improved the logic for getting symbol definitions.
- Updated descriptions for 'symbol references' and 'symbol definitions' contexts for clarity.
- Added checks to return early if no text has been selected in both contexts.
- Removed unnecessary logging of selected text and files list.
- Added logic to handle cases where symbol kind is a variable.
- Removed redundant logging of reference URI and range.
- Created two new contexts for symbol references and definitions.
- Updated the handler in ChatContext interface to return an array of strings.
- Updated the processText method in ChatContextManager to return an array of strings.
- Registered the new contexts in loadContexts.ts.
- Updated the addContext function to handle multiple context strings.
- Added a check in deleteChatMessageBase to remove the message from the current topic if deletion is successful.
- Modified updateFirstMessageHashAndName in Topic class to accept undefined values.
- Added a new method deleteMessage in TopicManager to update the topic when a message is deleted.
- Updated the 'deleteChatMessage' handler to directly access the hash from the message object.
- Removed a debugger statement from the 'deleteMessage.fulfilled' case in chatSlice.
- Added version check for DevChat in checkDevChatDependency function.
- Updated configuration in both Global and Workspace scopes.
- Commented out the initial DevChat check in install.py and added --force flag to pip install command.
- Added condition to check if `action.payload.hasDone` is true, then update the hash of the last two messages in `state.messages`.
- Fixed the `splice` method in `deleteMessage.fulfilled` to correctly remove the message from `state.messages`.
- Updated `stopGenerating` dispatch in `ChatPanel.tsx` to include the message in the payload.
- Modified the delete message action in `MessageHeader.tsx` to handle the case when `item.hash` is not present.
- Un-commented and updated the delete method logic.
- Added logging for the devchat command execution.
- Added error handling for stderr, failure to delete prompt, and non-zero exit code.
- Changed the deleteChatMessageBase function call to be awaited.
- Adjusted the condition to send a 'deletedChatMessage' command only when the message is successfully deleted.
- Introduced a loop to iterate over the state.messages array in reverse order.
- The loop finds the last message with a non-empty hash and assigns it to lastNonEmptyHash.
- The parent_hash of the new message is now set to lastNonEmptyHash.
- Created a new file `InputContexts.tsx` and moved the `InputContexts` component from `InputMessage.tsx` to this new file.
- Imported `InputContexts` in `InputMessage.tsx` and removed the old `InputContexts` component definition.
- This change improves code organization and readability by separating concerns.
- Added a new `deleteMessage` function in `chatSlice.ts` to handle message deletion.
- Modified `MessageContainer.tsx` and `MessageHeader.tsx` to pass the entire message item instead of individual properties.
- Updated the `showDelete` prop in `MessageContainer.tsx` to only show the delete icon for the second last message.
- Dispatch the `deleteMessage` action when the delete icon is clicked in `MessageHeader.tsx`.
- Updated the message structure in `chatSlice.ts` to include `date` and `hash` properties.
- Added a case for `deleteMessage.fulfilled` in `chatSlice.ts` to remove the deleted message from the state.
- Imported IconTrash from "@tabler/icons-react" in MessageHeader.tsx.
- Added a new prop 'showDelete' to the MessageHeader component with a default value of true.
- Added a new Tooltip for the delete icon with the label "Delete message".
- The delete icon is conditionally rendered based on the 'showDelete' prop.
- Imported SimpleGrid and IconEdit from respective libraries in MessageHeader.tsx.
- Added a new prop 'showEdit' to MessageHeader component to conditionally show the edit icon.
- Wrapped the refill prompt and edit message icons in a Flex container for better alignment.
- Added a Tooltip and ActionIcon for the edit message functionality.
- Extracted MessageHeader from MessageContainer.tsx into its own file MessageHeader.tsx.
- Removed unused imports from MessageContainer.tsx.
- Added necessary imports to MessageHeader.tsx.
- Updated MessageContainer.tsx to import MessageHeader from the new file.
- Replaced the getParentHash function with direct access to message.parent_hash.
- Updated the handleTopic function to accept undefined parentHash.
- This simplifies the code and makes the parent hash handling more straightforward.
- Removed 'Cancel' option from topicDeleteCallback in commands.ts.
- Imported deleteChatMessage in loadHandlers.ts and registered it as a handler.
- Added deleteChatMessage function in sendMessage.ts to prompt user for confirmation before deleting a message.
- Added deleteChatMessageBase function in sendMessageBase.ts to delete a message from messageHistory and by devchat.
- Added delete function in devchat.ts to delete a message by hash.
- Added delete function in messageHistory.ts to remove a message from history by hash.
- Added pip_cmd_run and pip_cmd_with_retries functions in install.py to handle pip command execution and retries.
- Simplified the installation of devchat and virtualenv in install.py using the new functions.
- Removed unnecessary checks in statusBarViewBase.ts.
- Added a new optional parameter 'showError' in checkDevChatDependency function in commandsBase.ts.
- Updated the conditions for logging error messages in checkDevChatDependency function.
- Updated the call to checkDevChatDependency in dependencyCheck function in statusBarViewBase.ts to pass 'showError' parameter.
- Updated the condition for logging stderr in CommandRun class in commonUtil.ts.
- Increased the runStatus check interval from 20 to 60 in statusBarView.ts.
- Added a new import, CommandRun, in statusBarViewBase.ts.
- Updated the conditions for checking devchatStatus in dependencyCheck function.
- Replaced the terminal run command for DevChat installation with a new CommandRun instance.
- Added error handling for the installation process, updating devchatStatus accordingly.
- Imported path module for handling file paths.
- Added pipxBinPath variable to store the pipx environment path.
- Changed error logging level from error to warn.
- Updated the way DevChat command is run and its path is updated.
- Updated the locateCommand function to split the output of the 'where' and 'which' commands and return the first line.
- Modified the DevChat installation command to include the path in quotes to handle paths with spaces.
- Added a check in commands.ts to validate the API key when setting it.
- If the API key is invalid, an error message is displayed to the user.
- Added a function in install.py to ensure pip is installed.
- This function attempts to install and upgrade pip using the ensurepip module.
- The function is called at the beginning of the main function in install.py.
- Wrapped the version comparison logic in a try-catch block to handle potential exceptions.
- If an exception occurs, the isVersionChangeCompare flag is set to false.
- The version comparison is now only performed if the DevChat dependency check passes and the DevChat instance is not already initialized.
- Added a new configuration 'DevChat.PythonPath' in package.json.
- This configuration allows users to specify the location of the Python binary.
- Also added a new command 'DevChat.PythonPath' to the command palette.
- Updated commandsBase.ts to use the Python Path from the configuration.
- If the Python Path is not set in the configuration, it will use the default Python command.
- If the DevChat status is 'Missing required dependency: Python3', the status bar item will trigger the 'devchat.PythonPath' command.
- Added a new command 'devchat.PythonPath' in commands.ts.
- This command prompts the user to input a Python Path and updates the DevChat configuration with the provided path.
- The new command is registered in the extension.ts file.
- Added a new method updateConfiguration to the UiUtil interface.
- Implemented the updateConfiguration method in the UiUtilWrapper and UiUtilVscode classes.
- This method updates a given configuration key with a new value.
- Imported CopyButton and Icon360 from respective libraries for improved functionality.
- Replaced the refill prompt icon with a 360 icon for better user understanding.
- Added a copy message functionality for bot messages with a tooltip indicating the copy status.
- Changed the state variable name from 'refilled' to 'done' for better context understanding.
- Imported Container from "@mantine/core" for better layout control in CodeBlock.
- Wrapped the preformatted text in a Container to apply additional styles.
- Added 'whiteSpace: 'pre-wrap'' and 'wordBreak: 'break-word'' to preserve white spaces, line breaks and ensure long words do not overflow the container.
- Passed dynamic width from ChatPanel to CurrentMessage component.
- Imported Container from "@mantine/core" for better layout control in CurrentMessage.
- Added styling to the CurrentMessage component to handle dynamic width and improve text display.
- Added 'whiteSpace: 'break-spaces'' to preserve white spaces and line breaks in the preformatted text.
- Modified the stopGenerating action to accept a payload indicating if the task has been completed.
- Added a new state property 'hasDone' to track if a task has been completed.
- Updated the CurrentMessage component to handle the new 'hasDone' state and update the last message accordingly.
- Introduced a new action 'updateLastMessage' to update the last message in the state.
- Added a new state property 'lastMessage' to keep track of the last message.
- Refactored the CurrentMessage component to split the message into blocks for better rendering.
- Extracted current message handling logic into a new component, CurrentMessage.tsx.
- Removed redundant code and imports from ChatPanel.tsx.
- Removed MessageBlink component from MessageContainer.tsx as it's now part of CurrentMessage.tsx.
- Added import for CurrentMessage in ChatPanel.tsx.
- Removed unused selectors from ChatPanel.tsx.
- Simplified useEffect hooks in ChatPanel.tsx by moving some logic to CurrentMessage.tsx.