Fix/critical bugs - #16
Merged
Merged
Conversation
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
This PR addresses critical bugs discovered in the terminal adapter scripts and TypeScript project reference build, while introducing atomic filesystem persistence, fault-tolerant project listing, and enhanced model validation rules.
Changes
1. Fixes & Terminal Adapter Isolation
#!/bin/zsh) and redundant shell environment sourcing (~/.profile,~/.bashrc) in macOS and Linux script generators incrates/codelaunch-core/src/ide/terminal/mod.rs.TerminalAdapter::renderto output files intooutput_dir.join(project.id.to_string())(matchingVsCodeAdapter). This eliminates filename collisions between projects sharing the same name and ensuresdelete_projectcleanly purges orphaned terminal scripts.terminal/mod.rstests and introduced a dedicated test verifying project ID collision prevention.2. TypeScript Build & Composite References
// @ts-expect-errorinvite.config.ts(since@types/nodeis present), resolving TS2578 failures.npm run buildto invoketsc -b && vite buildsotsconfig.node.jsonand composite project references are verified in CI..tsbuildinfoand emitted type declarations tonode_modules/.tmp/to avoid dirtying the git working directory, and added*.tsbuildinfoto.gitignore.3. Storage Resilience & Atomicity (
FsProjectRepository)FsProjectRepository::savenow writes to a<id>.json.tmpfile before atomically moving it to<id>.jsonviafs::rename. This protects against data corruption in the event of an unexpected process exit or system crash.FsProjectRepository::listnow handles corrupted JSON files and invalid directory entries gracefully by logging a warning and continuing, preventing a single malformed file from emptying the user's project list.serde::de::IgnoredAnywithin a dedicatedProjectListEntryprojection to avoid parsing and allocating full folder/terminal hierarchies during list operations.4. Structural Validations (
model::validation)ValidationError::EmptyFolderNameandValidationError::EmptyTerminalLabelto reject blank names and labels prior to persistence.5. CI / Release Workflow
tauri-apps/tauri-actionfrom@v1to@v2in.github/workflows/release.yml.Verification & Testing
All validation suites pass locally with zero errors or warnings: