Commit graph

1950 commits

Author SHA1 Message Date
Joe
01110fc916 Complete comprehensive plugin tests and add new stress test files
- Marked all todos in the comprehensive_plugin_tests plan as completed, indicating that all planned tests have been implemented.
- Introduced new stress test files for InstanceMap, PatchSet, and encoding functionalities, covering various scenarios including large batch operations, conflict resolution, and deep/wide hierarchies.
- Enhanced the testing framework to ensure thorough validation of plugin functionalities and edge cases.
2026-02-01 22:05:27 -06:00
Joe
180e1f9078 Update zmij package version to 1.0.19 in Cargo.lock 2026-02-01 21:15:54 -06:00
Joe
bb423312aa Refine testing philosophy and success criteria in comprehensive_plugin_tests plan
- Updated the testing philosophy to emphasize investigation of failing tests, clarifying that failures may indicate either code bugs or invalid tests.
- Revised success criteria to focus on analyzing failing tests rather than skipping them, ensuring a thorough understanding of test outcomes.
- Enhanced documentation on failure triage and anti-patterns to avoid, promoting a more robust approach to quality assurance in testing.
2026-02-01 21:13:52 -06:00
Joe
5298664bad Remove NetworkClient from visibleServices in multiple snapshot test files 2026-02-01 21:05:00 -06:00
Joe
76e4bc4f25 Add Int64 conversion functions to EncodedValue.lua and enhance script middleware selection in project.rs
- Implemented int64FromPod and int64ToPod functions for converting between Lua numbers and msgpack Int64 representation, addressing precision concerns for large integers.
- Updated the middleware_for_script function to determine the correct script directory based on the RunContext property, improving middleware selection for Script instances.
- Adjusted syncback logic to utilize the new middleware selection for Scripts, ensuring accurate handling of different script types during project synchronization.
2026-02-01 20:51:13 -06:00
Joe
04cf9ac91d Remove NetworkClient from VISIBLE_SERVICES in syncback module 2026-02-01 20:22:57 -06:00
Joe
44344f4014 Refactor syncback logic for camera removal handling
- Simplified the logic for removing the current camera by using a default value for sync_current_camera, improving code readability.
- Enhanced the handling of camera references within the syncback loop, ensuring that the camera is only removed when explicitly set to do so.
- Updated comments for clarity on the default behavior regarding camera removal in the syncback process.
2026-02-01 20:21:24 -06:00
Joe
fe2bf358e7 Enhance syncback logic for orphan file handling and improve test coverage
- Updated the syncback process to prevent scanning the project root folder, ensuring that unrelated files like .gitignore and README.md are not deleted.
- Introduced functionality to collect alternate file representations for paths, allowing orphan files to be identified and removed correctly.
- Enhanced the logic for handling ignored paths, particularly for directories, to improve accuracy in clean mode operations.
- Updated tests to reflect changes in orphan file handling, ensuring that only orphans within $path directories are removed, and clarified documentation regarding clean mode behavior.
2026-02-01 20:18:45 -06:00
Joe
411f79ee81 Enhance syncback functionality and improve code readability
- Refactored the syncback process to streamline directory management and improve handling of class transitions in clean mode.
- Updated the `clone_tree_filtered` function to accept a tuple of compiled Globs and original pattern strings, enhancing flexibility in ignore pattern handling.
- Simplified logic for checking if paths are inside removed directories, improving code clarity.
- Added detailed comments to clarify the purpose of new logic for handling script directory transitions, ensuring better maintainability.
- Improved logging for better traceability during syncback operations.
2026-02-01 20:10:11 -06:00
Joe
1534a54808 Refactor syncback process to improve clean mode handling and directory management
- Removed the ensure_project_paths_exist function, streamlining the syncback process by directly managing directory creation and cleanup within the syncback command.
- Enhanced error handling for sourcemap generation, logging warnings when clean mode removes directories that only contain meta files.
- Updated the logic for middleware selection in clean mode to better handle directory and script transitions based on the filesystem structure.
- Added utility functions to ensure base project directories exist before syncback, addressing the need for directory structure in clean mode.
- Improved test coverage for clean mode scenarios, ensuring that directory existence checks are performed and documented.
2026-02-01 19:55:54 -06:00
Joe
1f476d6cc9 Enhance syncback documentation and optimize clean mode functionality
- Added detailed explanations of clean mode, its purpose, and benefits, clarifying its role in achieving an accurate filesystem state.
- Updated the syncback process to include scanning of the project folder for orphan removal, ensuring comprehensive path collection.
- Emphasized the importance of understanding expected outputs before modifying code in response to failing tests, reinforcing testing philosophy.
2026-02-01 19:29:42 -06:00
Joe
2e6f909a71 Fix syncback process to handle directory paths and class transitions in clean mode
- Resolved an issue where syncback failed for projects with `$path` pointing to single files by ensuring only directory paths are scanned for orphans.
- Implemented a function to create missing directories in clean mode, allowing restoration of deleted directories.
- Enhanced class transition handling in clean mode to allow recoverable transitions between Folder and Script types.
- Updated logging and error handling to improve clarity during the syncback process.
2026-02-01 19:27:53 -06:00
Joe
fe1ac1dd95 Fix bugs in syncback process and enhance error handling
- Resolved issues with nested orphan file removal, ensuring that both top-level and nested orphan files are correctly handled.
- Improved directory removal logic to gracefully handle cases where directories may have already been removed, preventing crashes.
- Enhanced the path scanning algorithm to accurately collect all source directories defined in the project, addressing missing paths in the syncback process.
- Updated logging to provide clearer debug information during directory scanning and error handling in the syncback operations.
2026-02-01 19:14:12 -06:00
Joe
4a66eff938 Add comprehensive syncback roundtrip and clean mode stress tests
- Completed the implementation of roundtrip tests to validate the syncback process, ensuring that building a project, syncing back, and rebuilding produces semantically identical outputs.
- Created a new utility module for roundtrip testing, including functions for running builds and asserting directory equality.
- Developed clean mode stress tests to verify that syncing back to a dirty directory yields identical results to syncing back to a fresh directory, covering various mutation scenarios.
- Updated existing test modules to incorporate new test cases and ensure consistency in handling standalone scripts transitioning to directory format when children are added.
2026-02-01 19:01:42 -06:00
Joe
17d250f26a Add comprehensive Lua plugin stress testing plan
- Introduced a new testing plan for comprehensive Lua plugin stress tests, covering edge cases, large-scale scenarios, and abuse testing.
- Detailed todos for creating various test modules, including diff, apply, reify, property handling, encoding, and integration tests.
- Emphasized the importance of testing for concurrent workflows and error recovery in the plugin architecture.
2026-02-01 18:43:45 -06:00
Joe
b95b28179f Update LocalScript references in syncback format transition tests
- Changed references from `init.client.luau` to `init.local.luau` in the test for directory LocalScript to accurately reflect the script type being tested.
- Updated assertions to match the new file naming convention, ensuring consistency in the test's expectations for standalone files.
2026-02-01 18:35:22 -06:00
Joe
c08f701f0e Add syncback roundtrip and clean mode stress tests
- Introduced a new testing plan for comprehensive build-syncback roundtrip tests and mutation stress tests to ensure clean mode produces consistent results.
- Created utility functions for running builds and syncbacks, and for asserting directory equality.
- Updated existing tests to reflect changes in behavior when standalone scripts receive children, ensuring they convert to directory format.
- Added new test cases to validate the conversion of standalone scripts and modules when children are added, enhancing coverage of syncback functionality.
2026-02-01 18:34:02 -06:00
Joe
0eb135ee15 Enhance service visibility configuration in snapshot tests
- Added `ignoreHiddenServices: true` and a comprehensive list of `visibleServices` to multiple snapshot test files to improve service visibility management during testing.
- Refactored logging in the `diff.lua` file to streamline the trace output for hidden services, enhancing clarity in the sync process.
2026-02-01 18:28:31 -06:00
Joe
b368eb2401 Add CI pipeline documentation and enhance syncback architecture
- Introduced a new CI pipeline documentation file outlining steps for auto-fixing formatting, running linters, building, and testing.
- Documented the Rojo syncback architecture, detailing improvements to prevent duplicate file creation and format mismatches.
- Updated syncback logic to ensure existing instances are updated instead of creating duplicates, enhancing project file management.
- Added tests for encoding instances and handling nested children to improve reliability in syncback operations.
2026-02-01 18:18:31 -06:00
Joe
edc09741bf Update plugin references from Rojo to Atlas
- Changed all instances of "Rojo" to "Atlas" in error messages, UI titles, and connection actions for consistent branding.
- Updated the sound player widget and patch history recording to reflect the new name.
- Enhanced logging in the hydration process to provide better diagnostics for missing virtual instances.
2026-02-01 11:57:00 -06:00
Joe
9ab1369444 Update asset IDs and improve header component styling
- Changed asset IDs for the logo and plugin button to new values for updated branding.
- Updated the header component to use a fixed white color for the logo and adjusted its size for better visibility.
- Modified the fullscreen notification component to reflect the same logo styling changes.
- Updated the brand color in the theme for a consistent visual identity.
2026-02-01 11:51:49 -06:00
Joe
60518c2ad6 Update asset IDs for logo and plugin button in Assets.lua
- Changed the asset ID for the logo to a new value for updated branding.
- Updated the plugin button asset ID to reflect the latest design changes.
2026-02-01 11:21:01 -06:00
Joe
5197ca720d Refactor comment formatting in DomLabel component
- Cleaned up comment formatting in the DomLabel component for improved readability and consistency.
- Ensured that the button remains active for input events, maintaining user interaction functionality.
2026-02-01 10:52:45 -06:00
Joe
9f8ff3b57e Implement path canonicalization for non-existent files in syncback loop
- Added a helper function to canonicalize paths that may not exist, ensuring accurate path resolution by falling back to the nearest existing ancestor.
- Updated the handling of added paths in the syncback loop to utilize the new canonicalization logic, improving consistency in path comparisons.
2026-02-01 10:50:42 -06:00
Joe
df70dc1ff4 Refactor transparency logic and improve button interaction in PatchVisualizer
- Simplified transparency handling in the SelectionOption component to enhance hover effects for parent-only and normal nodes.
- Updated the DomLabel component to ensure the button is active for input events, improving user interaction.
- Cleaned up comments for clarity and maintainability.
2026-02-01 10:42:02 -06:00
Joe
b2ce199a37 Update dependencies and improve build script
- Updated `embed-resource` version in `Cargo.toml` and `Cargo.lock` to 3.0.6 for enhanced functionality.
- Upgraded several dependencies including `dirs`, `dirs-sys`, `float-cmp`, and `hashbrown` to their latest versions for better performance and security.
- Modified the build script to handle resource compilation more gracefully by using `embed_resource::NONE`.
2026-02-01 10:24:47 -06:00
Joe
e342f00306 Enhance syncback logic to preserve nested project files
- Updated the syncback loop to skip removal of nested project files, ensuring project structure is maintained.
- Added logging to indicate when nested project files are being skipped during the syncback process.
2026-02-01 10:13:24 -06:00
Joe
a8752b6b8d Refactor DomLabel and SelectionOption components for improved readability
- Simplified conditional logic for caret visibility in the SelectionOption component.
- Enhanced the rendering logic in the ConfirmingPage to improve clarity and maintainability.
- Updated the Abort button rendering to use a more concise syntax for conditional display.
2026-02-01 10:10:38 -06:00
Joe
af65056c44 Update default settings and enhance ConfirmingPage logic
- Changed default settings to enable two-way and one-shot sync, disable notifications and sync fallback, and adjust confirmation behavior.
- Improved ConfirmingPage to conditionally display the Abort button and update the Accept button text based on the presence of changes in the patch tree.
- Updated logging level in SyncbackStats to warn for better visibility on debug logging hints.
2026-02-01 10:06:34 -06:00
Joe
01e20f521a Refactor logging in syncback command to use log crate
- Replaced `eprintln!` statements with `log::info!` for consistent logging throughout the `syncback` command.
- Enhanced logging for download operations, syncback initiation, and sourcemap generation to improve traceability.
- Updated git index refresh logging to provide clearer feedback on success or failure.
- Ensured that debug logs are used appropriately for non-git repository scenarios.
2026-02-01 09:58:13 -06:00
Joe
6ed96f1f7e Enhance SelectionOption component with hover state and caret visibility logic
- Refactored the `SelectionOption` to be a Roact component that tracks hover state.
- Added logic to determine caret visibility based on node properties (parent-only, has children, and selection state).
- Updated background and text transparency based on hover state for improved UX.
- Adjusted event handling for mouse enter, mouse leave, and click actions to accommodate new behavior.
- Modified `SelectionRadio` to pass necessary props to `SelectionOption` for consistent behavior.
2026-02-01 09:51:48 -06:00
Joe
2b2ada219e Implement auto-download feature for syncback command
- Enhanced the `syncback` command to automatically download Roblox place files from the asset delivery API, allowing for zero-argument usage.
- Updated `Cargo.toml` to include compression features for `reqwest` and moved `tempfile` to dependencies.
- Introduced a new `download` argument in `SyncbackCommand` to specify place IDs for downloading.
- Implemented logic to resolve input file paths, prioritizing downloads when necessary.
- Added sourcemap generation after successful syncback and refreshed the git index if in a repository.
- Updated tests to validate the new download functionality and sourcemap creation.
2026-02-01 09:46:34 -06:00
Joe
8fe908740f Add statistics tracking for syncback operations
- Introduced a new `SyncbackStats` module to track and report issues during syncback, including duplicate names, unknown classes, and properties.
- Updated the `syncback_loop` and related functions to utilize the stats tracker, logging summaries of issues encountered.
- Enhanced property filtering and instance syncing to record statistics on unknown classes and properties.
- Modified tests to ensure consistent output by normalizing temporary paths in snapshots.
- Added `regex` dependency for path normalization in tests.
2026-02-01 08:29:00 -06:00
Joe
58399bb863 Implement incremental syncback mode to preserve existing file structure
- Added an `incremental` flag to the `SyncbackCommand` to allow for preserving existing file structure and middleware formats during syncback operations.
- Enhanced the `syncback_loop` function to differentiate between clean mode and incremental mode, ensuring orphaned files are removed only in clean mode.
- Updated logging to reflect the mode of operation during syncback.
- Introduced new tests to validate the behavior of clean mode versus incremental mode, ensuring proper handling of orphaned files and preservation of existing structures.
2026-02-01 08:14:20 -06:00
Joe
0e5e809894 UX update 2026-02-01 07:58:06 -06:00
Joe
3e6a50ce4b syncback 2026-01-31 13:22:29 -06:00
Joe
5f91a0777a Implement new oneshot Vfs for CLI commands and enhance JSON5 serialization
- Added `new_oneshot` method to the Vfs struct, providing a backend suitable for one-time operations without file watching.
- Updated CLI commands (`fmt_project` and `syncback`) to utilize the new oneshot Vfs, improving error handling during file operations.
- Enhanced JSON5 serialization by introducing a custom serializer that directly builds a tree structure, improving performance and maintaining sorted keys.
- Improved error logging in JSON serialization to provide more context on failures.
2026-01-31 13:06:37 -06:00
Joe
fca802a4e5 update 2026-01-31 12:08:06 -06:00
Joe
ebbc15c676 Update dependencies in Cargo.lock and Cargo.toml
- Bump versions of several packages: `insta` to 1.46.2, `portable-atomic` to 1.13.1, `portable-atomic-util` to 0.2.5, `slab` to 0.4.12, `zerocopy` to 0.8.37, `zerocopy-derive` to 0.8.37, and `zmij` to 1.0.18.
- Update checksums for the modified packages to ensure integrity and compatibility.
2026-01-31 12:06:51 -06:00
Joe
6dc8f219bd Enhance logging for syncback operations and patch applications
- Added detailed logging for syncback operations, including additions, removals, and updates, to improve traceability and debugging.
- Implemented summary logs for patch applications in both the client and server, capturing the number of changes made.
- Enhanced logging in the ChangeBatcher and ApiService to provide insights into property changes and instance updates during syncback processes.
- Improved error handling and logging for VFS events to ensure better visibility of file operations.
2026-01-31 12:06:27 -06:00
Joe
d3d914e660 Enhance path encoding logic and add comprehensive tests
- Updated the `encode_path_name` function to handle cases of leading, trailing, and entirely empty strings, ensuring correct encoding of spaces.
- Introduced new tests for single space, multiple spaces, and empty string scenarios to validate encoding and decoding behavior.
2026-01-31 11:53:44 -06:00
Joe
9dd2fd159e Refactor property filter imports and improve log formatting in ApiService
- Adjusted the import order for property filter functions for consistency.
- Enhanced log formatting in the syncback logic to improve readability and maintainability.
- Reformatted code for better alignment and clarity in various sections of the ApiService implementation.
2026-01-30 13:19:32 -06:00
Joe
dccd3a691a Enhance property encoding and class descriptor retrieval in rbx_dom_lua
- Introduced a new function, `findClassDescriptor`, to retrieve class properties and metadata, including inherited properties, from the database.
- Updated `encodeInstance` to include encoding for Tags alongside Attributes, ensuring comprehensive property serialization.
- Improved property filtering logic to skip non-serializable properties and those matching default values, aligning with syncback behavior.
- Enhanced comments for clarity on property handling and encoding processes.
2026-01-30 13:18:20 -06:00
Joe
c0d089f0aa Enhance script property encoding in encodeInstance.lua
- Updated the encodeInstance function to include additional script properties (Disabled, LinkedSource, etc.) for encoding into the .meta.json5 file.
- Improved handling of properties by skipping those that are already managed or should be ignored, ensuring only serializable properties are encoded.
- Clarified comments to indicate the necessity of encoding the Source property.
2026-01-30 12:55:53 -06:00
Joe
439eb3f5f8 Enhance syncback logic for removed instances in ApiService
- Implemented functionality to delete files from the filesystem when instances are removed in Studio but exist in Rojo, ensuring proper synchronization.
- Added error handling for cases where the instance's filesystem path may not exist due to parent directory deletions.
- Introduced a new method, `syncback_removed_instance`, to encapsulate the logic for handling the removal of instances and their associated metadata files.
- Updated tests to verify the correct behavior of the new removal logic.
2026-01-30 12:52:36 -06:00
Joe
8c6aa36027 Enhance error handling in TestServeSession for interrupted reads
- Updated the error handling logic in the TestServeSession implementation to account for `std::io::ErrorKind::Interrupted`, ensuring that the session can properly retry on interrupted read operations, in addition to handling timeouts and would-block scenarios.
2026-01-30 11:40:01 -06:00
Joe
a98d5c6cce Enhance PatchSet data model update handling and update default project path in CLI
- Improved the `removeDataModelName` function in PatchSet to remove names from both `changedName` and `changedProperties`, ensuring more robust update management.
- Updated the default project path in the ServeCommand struct to `default.project.json5` for clearer project serving expectations.
2026-01-30 11:35:49 -06:00
Joe
77088eccd8 Implement DataModel name change removal in PatchSet and adjust session handling in App
- Added a new function to PatchSet to remove the DataModel name change from updates, preventing unwanted synchronization of the project name.
- Updated the App:startSession method to conditionally skip session lock acquisition and release based on one-shot mode settings.
- Enhanced the confirmation callback to utilize the new PatchSet function for filtering DataModel name changes from patches.
2026-01-30 11:26:40 -06:00
Joe
240c225be0 Refactor PullAll button logic in Confirming.lua for improved readability
- Removed conditional rendering of the PullAll button based on settings and simplified its implementation.
- Enhanced the overall structure of the button definition for better clarity in the ConfirmingPage render function.
2026-01-30 11:18:00 -06:00
Joe
0b243b4ca9 Add CSV input files and enhance syncback warning logic
- Introduced a new CSV input file with translation data for Spanish.
- Updated the `init.csv` file to include a new entry for "Rojo" with its context and example.
- Enhanced the syncback logic to conditionally emit warnings for duplicate child names based on the new `warn_duplicate_names` configuration in `SyncbackRules`.
- Added documentation for the new warning behavior in the `SyncbackRules` and `SyncbackSnapshot` implementations.
2026-01-30 10:42:38 -06:00