Conversation
…oration features - Added an `args` parameter to the `execute_code` function, allowing users to pass command line arguments to the executed code. - Introduced `restore_state` field in the `RequestFile` model to facilitate state restoration from previously used files. - Updated `ExecuteCodeRequest` model to include `args` for better flexibility in code execution. - Enhanced `FileInfo` model with state-related fields (`execution_id`, `state_hash`, `last_used_at`) for improved state management. - Implemented state hash storage and retrieval in `StateService` for linking files to specific execution states. - Added integration tests to validate new features and ensure correct functionality across models and services.
- Introduced a new test class `TestUploadedFileStateRestoration` to validate the behavior of uploaded files regarding state management. - Added tests to ensure uploaded files start without a state hash, receive a state hash after execution, and correctly handle state restoration. - Verified that the `update_file_state_hash` function works as expected for uploaded files, including proper interaction with Redis. - Documented expected behavior for state restoration when state hashes are not set.
- Added `update_file_content` method to `FileService` for updating existing file content in MinIO and updating metadata in Redis. - Introduced `_update_mounted_files_content` method in `ExecutionOrchestrator` to handle in-place edits to mounted files after execution. - Created integration tests in `test_mounted_file_edits.py` to verify persistence of edits to mounted files. - Developed unit tests in `test_file_service.py` to ensure correct behavior of the `update_file_content` method, including success and error scenarios.
- Updated the `upload_file` function to create sessions for file uploads, enabling session reuse for referenced files. - Introduced `is_agent_file` flag to distinguish between user-uploaded files and agent-assigned files, enforcing read-only restrictions on agent files. - Modified `FileService` to handle the `is_agent_file` attribute in file metadata, ensuring proper storage and retrieval. - Enhanced `ExecutionOrchestrator` to prevent modifications to files associated with different sessions and agent files. - Added integration tests to verify the read-only behavior of agent files and the editability of user files.
…trator - Added optional `session_id` field to `FileRef` model for cross-message file persistence. - Updated `_mount_files` method to support auto-mounting of all session files when no explicit files are provided. - Introduced `_auto_mount_session_files` method to handle session file retrieval and ensure security through session isolation. - Enhanced integration tests to validate new file mounting behavior and session management features.
…ple files - Added missing commas in field descriptions within `exec.py`, `files.py`, and `state_archival.py` to ensure proper syntax. - Reformatted multi-line expressions in `file.py`, `orchestrator.py`, and `runner.py` for better readability. - Updated test functions in `test_exec_languages.py`, `test_exec_workflow.py`, and `test_files.py` to follow consistent formatting practices. - Cleaned up unnecessary blank lines and improved alignment in various test files to enhance overall code clarity.
- Updated environment variable assignments in `conftest.py` to use `os.environ.setdefault`, allowing for overrides by existing environment variables. - This change enhances flexibility in test configurations while maintaining default values for local testing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test Plan