From e072c2278bbe955d5490fd32440aba64520a1211 Mon Sep 17 00:00:00 2001 From: John Cantu Date: Mon, 29 Sep 2025 15:15:32 -0700 Subject: [PATCH 1/4] Eliminate term "nested" Git repositories to reduce confusion, clarified related error messages --- src/i18n/locales/en/common.json | 2 +- .../checkpoints/ShadowCheckpointService.ts | 32 +++++----- .../__tests__/ShadowCheckpointService.spec.ts | 60 +++++++++---------- 3 files changed, 47 insertions(+), 47 deletions(-) diff --git a/src/i18n/locales/en/common.json b/src/i18n/locales/en/common.json index 3a613cc1c21..5017118aa46 100644 --- a/src/i18n/locales/en/common.json +++ b/src/i18n/locales/en/common.json @@ -29,7 +29,7 @@ "checkpoint_timeout": "Timed out when attempting to restore checkpoint.", "checkpoint_failed": "Failed to restore checkpoint.", "git_not_installed": "Git is required for the checkpoints feature. Please install Git to enable checkpoints.", - "nested_git_repos_warning": "Checkpoints are disabled because a nested git repository was detected at: {{path}}. To use checkpoints, please remove or relocate this nested git repository.", + "nested_git_repos_warning": "Checkpoints are disabled because a Git repository was detected below the workspace root at: {{path}}. To use checkpoints, please remove or relocate this git repository, or open a Git repository as the workspace root.\n\nFor more information, see https://docs.roocode.com/features/checkpoints#git-repositories-below-the-workspace-root", "no_workspace": "Please open a project folder first", "update_support_prompt": "Failed to update support prompt", "reset_support_prompt": "Failed to reset support prompt", diff --git a/src/services/checkpoints/ShadowCheckpointService.ts b/src/services/checkpoints/ShadowCheckpointService.ts index e68a7cfea10..d81ad9ef84d 100644 --- a/src/services/checkpoints/ShadowCheckpointService.ts +++ b/src/services/checkpoints/ShadowCheckpointService.ts @@ -70,17 +70,17 @@ export abstract class ShadowCheckpointService extends EventEmitter { throw new Error("Shadow git repo already initialized") } - const nestedGitPath = await this.getNestedGitRepository() + const childGitPath = await this.getChildGitRepository() - if (nestedGitPath) { + if (childGitPath) { // Show persistent error message with the offending path - const relativePath = path.relative(this.workspaceDir, nestedGitPath) - const message = t("common:errors.nested_git_repos_warning", { path: relativePath }) + const relativePath = path.relative(this.workspaceDir, childGitPath) + const message = t("common:errors.child_git_repos_warning", { path: relativePath }) vscode.window.showErrorMessage(message) throw new Error( - `Checkpoints are disabled because a nested git repository was detected at: ${relativePath}. ` + - "Please remove or relocate nested git repositories to use the checkpoints feature.", + `Checkpoints are disabled because a Git repository was detected below the workspace root at: ${relativePath}. ` + + `To use checkpoints, please remove or relocate this git repository, or open a Git repository as the workspace root.`, ) } @@ -160,17 +160,17 @@ export abstract class ShadowCheckpointService extends EventEmitter { } } - private async getNestedGitRepository(): Promise { + private async getChildGitRepository(): Promise { try { // Find all .git/HEAD files that are not at the root level. const args = ["--files", "--hidden", "--follow", "-g", "**/.git/HEAD", this.workspaceDir] const gitPaths = await executeRipgrep({ args, workspacePath: this.workspaceDir }) - // Filter to only include nested git directories (not the root .git). + // Filter to only include child git directories (not the root .git). // Since we're searching for HEAD files, we expect type to be "file" - const nestedGitPaths = gitPaths.filter(({ type, path: filePath }) => { - // Check if it's a file and is a nested .git/HEAD (not at root) + const childGitPaths = gitPaths.filter(({ type, path: filePath }) => { + // Check if it's a file and is a child .git/HEAD (not at root) if (type !== "file") return false // Ensure it's a .git/HEAD file and not the root one @@ -182,10 +182,10 @@ export abstract class ShadowCheckpointService extends EventEmitter { ) }) - if (nestedGitPaths.length > 0) { - // Get the first nested git repository path + if (childGitPaths.length > 0) { + // Get the first child git repository path // Remove .git/HEAD from the path to get the repository directory - const headPath = nestedGitPaths[0].path + const headPath = childGitPaths[0].path // Use path module to properly extract the repository directory // The HEAD file is at .git/HEAD, so we need to go up two directories @@ -195,7 +195,7 @@ export abstract class ShadowCheckpointService extends EventEmitter { const absolutePath = path.join(this.workspaceDir, repoDir) this.log( - `[${this.constructor.name}#getNestedGitRepository] found ${nestedGitPaths.length} nested git repositories, first at: ${repoDir}`, + `[${this.constructor.name}#getChildGitRepository] found ${childGitPaths.length} child git repositories, first at: ${repoDir}`, ) return absolutePath } @@ -203,10 +203,10 @@ export abstract class ShadowCheckpointService extends EventEmitter { return null } catch (error) { this.log( - `[${this.constructor.name}#getNestedGitRepository] failed to check for nested git repos: ${error instanceof Error ? error.message : String(error)}`, + `[${this.constructor.name}#getChildGitRepository] failed to check for child git repos: ${error instanceof Error ? error.message : String(error)}`, ) - // If we can't check, assume there are no nested repos to avoid blocking the feature. + // If we can't check, assume there are no child repos to avoid blocking the feature. return null } } diff --git a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts index 622a90f39ab..4b1e7336da4 100644 --- a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts +++ b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts @@ -378,11 +378,11 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( }) }) - describe(`${klass.name}#hasNestedGitRepositories`, () => { - it("throws error when nested git repositories are detected during initialization", async () => { + describe(`${klass.name}#hasChildGitRepositories`, () => { + it("throws error when child git repositories are detected during initialization", async () => { // Create a new temporary workspace and service for this test. - const shadowDir = path.join(tmpDir, `${prefix}-nested-git-${Date.now()}`) - const workspaceDir = path.join(tmpDir, `workspace-nested-git-${Date.now()}`) + const shadowDir = path.join(tmpDir, `${prefix}-child-git-${Date.now()}`) + const workspaceDir = path.join(tmpDir, `workspace-child-git-${Date.now()}`) // Create a primary workspace repo. await fs.mkdir(workspaceDir, { recursive: true }) @@ -391,19 +391,19 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await mainGit.addConfig("user.name", "Roo Code") await mainGit.addConfig("user.email", "support@roocode.com") - // Create a nested repo inside the workspace. - const nestedRepoPath = path.join(workspaceDir, "nested-project") - await fs.mkdir(nestedRepoPath, { recursive: true }) - const nestedGit = simpleGit(nestedRepoPath) - await nestedGit.init() - await nestedGit.addConfig("user.name", "Roo Code") - await nestedGit.addConfig("user.email", "support@roocode.com") + // Create a child repo inside the workspace. + const childRepoPath = path.join(workspaceDir, "nested-project") + await fs.mkdir(childRepoPath, { recursive: true }) + const childGit = simpleGit(childRepoPath) + await childGit.init() + await childGit.addConfig("user.name", "Roo Code") + await childGit.addConfig("user.email", "support@roocode.com") - // Add a file to the nested repo. - const nestedFile = path.join(nestedRepoPath, "nested-file.txt") - await fs.writeFile(nestedFile, "Content in nested repo") - await nestedGit.add(".") - await nestedGit.commit("Initial commit in nested repo") + // Add a file to the child repo. + const childFile = path.join(childRepoPath, "nested-file.txt") + await fs.writeFile(childFile, "Content in child repo") + await childGit.add(".") + await childGit.commit("Initial commit in child repo") // Create a test file in the main workspace. const mainFile = path.join(workspaceDir, "main-file.txt") @@ -411,18 +411,18 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await mainGit.add(".") await mainGit.commit("Initial commit in main repo") - // Confirm nested git directory exists before initialization. - const nestedGitDir = path.join(nestedRepoPath, ".git") - const headFile = path.join(nestedGitDir, "HEAD") + // Confirm child git directory exists before initialization. + const childGitDir = path.join(childRepoPath, ".git") + const headFile = path.join(childGitDir, "HEAD") await fs.writeFile(headFile, "HEAD") - expect(await fileExistsAtPath(nestedGitDir)).toBe(true) + expect(await fileExistsAtPath(childGitDir)).toBe(true) vitest.spyOn(fileSearch, "executeRipgrep").mockImplementation(({ args }) => { const searchPattern = args[4] if (searchPattern.includes(".git/HEAD")) { // Return the HEAD file path, not the .git directory - const headFilePath = path.join(path.relative(workspaceDir, nestedGitDir), "HEAD") + const headFilePath = path.join(path.relative(workspaceDir, childGitDir), "HEAD") return Promise.resolve([ { path: headFilePath, @@ -437,10 +437,10 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( const service = new klass(taskId, shadowDir, workspaceDir, () => {}) - // Verify that initialization throws an error when nested git repos are detected - // The error message now includes the specific path of the nested repository + // Verify that initialization throws an error when child git repos are detected + // The error message now includes the specific path of the child repository await expect(service.initShadowGit()).rejects.toThrowError( - /Checkpoints are disabled because a nested git repository was detected at:/, + /Checkpoints are disabled because a child git repository was detected at:/, ) // Clean up. @@ -449,12 +449,12 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await fs.rm(workspaceDir, { recursive: true, force: true }) }) - it("succeeds when no nested git repositories are detected", async () => { + it("succeeds when no child git repositories are detected", async () => { // Create a new temporary workspace and service for this test. - const shadowDir = path.join(tmpDir, `${prefix}-no-nested-git-${Date.now()}`) - const workspaceDir = path.join(tmpDir, `workspace-no-nested-git-${Date.now()}`) + const shadowDir = path.join(tmpDir, `${prefix}-no-child-git-${Date.now()}`) + const workspaceDir = path.join(tmpDir, `workspace-no-child-git-${Date.now()}`) - // Create a primary workspace repo without any nested repos. + // Create a primary workspace repo without any child repos. await fs.mkdir(workspaceDir, { recursive: true }) const mainGit = simpleGit(workspaceDir) await mainGit.init() @@ -468,13 +468,13 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await mainGit.commit("Initial commit in main repo") vitest.spyOn(fileSearch, "executeRipgrep").mockImplementation(() => { - // Return empty array to simulate no nested git repos found + // Return empty array to simulate no child git repos found return Promise.resolve([]) }) const service = new klass(taskId, shadowDir, workspaceDir, () => {}) - // Verify that initialization succeeds when no nested git repos are detected + // Verify that initialization succeeds when no child git repos are detected await expect(service.initShadowGit()).resolves.not.toThrow() expect(service.isInitialized).toBe(true) From ba30ca780d956893fc8a8a27d9e99d02c119ecd8 Mon Sep 17 00:00:00 2001 From: John Cantu Date: Mon, 29 Sep 2025 15:47:38 -0700 Subject: [PATCH 2/4] fix regex match for modified error message --- .../checkpoints/__tests__/ShadowCheckpointService.spec.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts index 4b1e7336da4..9260e8956cf 100644 --- a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts +++ b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts @@ -440,7 +440,7 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( // Verify that initialization throws an error when child git repos are detected // The error message now includes the specific path of the child repository await expect(service.initShadowGit()).rejects.toThrowError( - /Checkpoints are disabled because a child git repository was detected at:/, + /Checkpoints are disabled because a Git repository was detected below the workspace root at: .*?\. To use checkpoints, please remove or relocate this git repository, or open a Git repository as the workspace root\./, ) // Clean up. From 439a0a24e70373ffe04010e3b0e1f39d1a3d5c88 Mon Sep 17 00:00:00 2001 From: John Cantu Date: Mon, 29 Sep 2025 15:15:32 -0700 Subject: [PATCH 3/4] Eliminate term "nested" Git repositories to reduce confusion, clarified related error messages --- src/i18n/locales/en/common.json | 2 +- .../checkpoints/ShadowCheckpointService.ts | 32 +++++----- .../__tests__/ShadowCheckpointService.spec.ts | 60 +++++++++---------- 3 files changed, 47 insertions(+), 47 deletions(-) diff --git a/src/i18n/locales/en/common.json b/src/i18n/locales/en/common.json index 3a613cc1c21..5017118aa46 100644 --- a/src/i18n/locales/en/common.json +++ b/src/i18n/locales/en/common.json @@ -29,7 +29,7 @@ "checkpoint_timeout": "Timed out when attempting to restore checkpoint.", "checkpoint_failed": "Failed to restore checkpoint.", "git_not_installed": "Git is required for the checkpoints feature. Please install Git to enable checkpoints.", - "nested_git_repos_warning": "Checkpoints are disabled because a nested git repository was detected at: {{path}}. To use checkpoints, please remove or relocate this nested git repository.", + "nested_git_repos_warning": "Checkpoints are disabled because a Git repository was detected below the workspace root at: {{path}}. To use checkpoints, please remove or relocate this git repository, or open a Git repository as the workspace root.\n\nFor more information, see https://docs.roocode.com/features/checkpoints#git-repositories-below-the-workspace-root", "no_workspace": "Please open a project folder first", "update_support_prompt": "Failed to update support prompt", "reset_support_prompt": "Failed to reset support prompt", diff --git a/src/services/checkpoints/ShadowCheckpointService.ts b/src/services/checkpoints/ShadowCheckpointService.ts index e68a7cfea10..d81ad9ef84d 100644 --- a/src/services/checkpoints/ShadowCheckpointService.ts +++ b/src/services/checkpoints/ShadowCheckpointService.ts @@ -70,17 +70,17 @@ export abstract class ShadowCheckpointService extends EventEmitter { throw new Error("Shadow git repo already initialized") } - const nestedGitPath = await this.getNestedGitRepository() + const childGitPath = await this.getChildGitRepository() - if (nestedGitPath) { + if (childGitPath) { // Show persistent error message with the offending path - const relativePath = path.relative(this.workspaceDir, nestedGitPath) - const message = t("common:errors.nested_git_repos_warning", { path: relativePath }) + const relativePath = path.relative(this.workspaceDir, childGitPath) + const message = t("common:errors.child_git_repos_warning", { path: relativePath }) vscode.window.showErrorMessage(message) throw new Error( - `Checkpoints are disabled because a nested git repository was detected at: ${relativePath}. ` + - "Please remove or relocate nested git repositories to use the checkpoints feature.", + `Checkpoints are disabled because a Git repository was detected below the workspace root at: ${relativePath}. ` + + `To use checkpoints, please remove or relocate this git repository, or open a Git repository as the workspace root.`, ) } @@ -160,17 +160,17 @@ export abstract class ShadowCheckpointService extends EventEmitter { } } - private async getNestedGitRepository(): Promise { + private async getChildGitRepository(): Promise { try { // Find all .git/HEAD files that are not at the root level. const args = ["--files", "--hidden", "--follow", "-g", "**/.git/HEAD", this.workspaceDir] const gitPaths = await executeRipgrep({ args, workspacePath: this.workspaceDir }) - // Filter to only include nested git directories (not the root .git). + // Filter to only include child git directories (not the root .git). // Since we're searching for HEAD files, we expect type to be "file" - const nestedGitPaths = gitPaths.filter(({ type, path: filePath }) => { - // Check if it's a file and is a nested .git/HEAD (not at root) + const childGitPaths = gitPaths.filter(({ type, path: filePath }) => { + // Check if it's a file and is a child .git/HEAD (not at root) if (type !== "file") return false // Ensure it's a .git/HEAD file and not the root one @@ -182,10 +182,10 @@ export abstract class ShadowCheckpointService extends EventEmitter { ) }) - if (nestedGitPaths.length > 0) { - // Get the first nested git repository path + if (childGitPaths.length > 0) { + // Get the first child git repository path // Remove .git/HEAD from the path to get the repository directory - const headPath = nestedGitPaths[0].path + const headPath = childGitPaths[0].path // Use path module to properly extract the repository directory // The HEAD file is at .git/HEAD, so we need to go up two directories @@ -195,7 +195,7 @@ export abstract class ShadowCheckpointService extends EventEmitter { const absolutePath = path.join(this.workspaceDir, repoDir) this.log( - `[${this.constructor.name}#getNestedGitRepository] found ${nestedGitPaths.length} nested git repositories, first at: ${repoDir}`, + `[${this.constructor.name}#getChildGitRepository] found ${childGitPaths.length} child git repositories, first at: ${repoDir}`, ) return absolutePath } @@ -203,10 +203,10 @@ export abstract class ShadowCheckpointService extends EventEmitter { return null } catch (error) { this.log( - `[${this.constructor.name}#getNestedGitRepository] failed to check for nested git repos: ${error instanceof Error ? error.message : String(error)}`, + `[${this.constructor.name}#getChildGitRepository] failed to check for child git repos: ${error instanceof Error ? error.message : String(error)}`, ) - // If we can't check, assume there are no nested repos to avoid blocking the feature. + // If we can't check, assume there are no child repos to avoid blocking the feature. return null } } diff --git a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts index 622a90f39ab..4b1e7336da4 100644 --- a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts +++ b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts @@ -378,11 +378,11 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( }) }) - describe(`${klass.name}#hasNestedGitRepositories`, () => { - it("throws error when nested git repositories are detected during initialization", async () => { + describe(`${klass.name}#hasChildGitRepositories`, () => { + it("throws error when child git repositories are detected during initialization", async () => { // Create a new temporary workspace and service for this test. - const shadowDir = path.join(tmpDir, `${prefix}-nested-git-${Date.now()}`) - const workspaceDir = path.join(tmpDir, `workspace-nested-git-${Date.now()}`) + const shadowDir = path.join(tmpDir, `${prefix}-child-git-${Date.now()}`) + const workspaceDir = path.join(tmpDir, `workspace-child-git-${Date.now()}`) // Create a primary workspace repo. await fs.mkdir(workspaceDir, { recursive: true }) @@ -391,19 +391,19 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await mainGit.addConfig("user.name", "Roo Code") await mainGit.addConfig("user.email", "support@roocode.com") - // Create a nested repo inside the workspace. - const nestedRepoPath = path.join(workspaceDir, "nested-project") - await fs.mkdir(nestedRepoPath, { recursive: true }) - const nestedGit = simpleGit(nestedRepoPath) - await nestedGit.init() - await nestedGit.addConfig("user.name", "Roo Code") - await nestedGit.addConfig("user.email", "support@roocode.com") + // Create a child repo inside the workspace. + const childRepoPath = path.join(workspaceDir, "nested-project") + await fs.mkdir(childRepoPath, { recursive: true }) + const childGit = simpleGit(childRepoPath) + await childGit.init() + await childGit.addConfig("user.name", "Roo Code") + await childGit.addConfig("user.email", "support@roocode.com") - // Add a file to the nested repo. - const nestedFile = path.join(nestedRepoPath, "nested-file.txt") - await fs.writeFile(nestedFile, "Content in nested repo") - await nestedGit.add(".") - await nestedGit.commit("Initial commit in nested repo") + // Add a file to the child repo. + const childFile = path.join(childRepoPath, "nested-file.txt") + await fs.writeFile(childFile, "Content in child repo") + await childGit.add(".") + await childGit.commit("Initial commit in child repo") // Create a test file in the main workspace. const mainFile = path.join(workspaceDir, "main-file.txt") @@ -411,18 +411,18 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await mainGit.add(".") await mainGit.commit("Initial commit in main repo") - // Confirm nested git directory exists before initialization. - const nestedGitDir = path.join(nestedRepoPath, ".git") - const headFile = path.join(nestedGitDir, "HEAD") + // Confirm child git directory exists before initialization. + const childGitDir = path.join(childRepoPath, ".git") + const headFile = path.join(childGitDir, "HEAD") await fs.writeFile(headFile, "HEAD") - expect(await fileExistsAtPath(nestedGitDir)).toBe(true) + expect(await fileExistsAtPath(childGitDir)).toBe(true) vitest.spyOn(fileSearch, "executeRipgrep").mockImplementation(({ args }) => { const searchPattern = args[4] if (searchPattern.includes(".git/HEAD")) { // Return the HEAD file path, not the .git directory - const headFilePath = path.join(path.relative(workspaceDir, nestedGitDir), "HEAD") + const headFilePath = path.join(path.relative(workspaceDir, childGitDir), "HEAD") return Promise.resolve([ { path: headFilePath, @@ -437,10 +437,10 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( const service = new klass(taskId, shadowDir, workspaceDir, () => {}) - // Verify that initialization throws an error when nested git repos are detected - // The error message now includes the specific path of the nested repository + // Verify that initialization throws an error when child git repos are detected + // The error message now includes the specific path of the child repository await expect(service.initShadowGit()).rejects.toThrowError( - /Checkpoints are disabled because a nested git repository was detected at:/, + /Checkpoints are disabled because a child git repository was detected at:/, ) // Clean up. @@ -449,12 +449,12 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await fs.rm(workspaceDir, { recursive: true, force: true }) }) - it("succeeds when no nested git repositories are detected", async () => { + it("succeeds when no child git repositories are detected", async () => { // Create a new temporary workspace and service for this test. - const shadowDir = path.join(tmpDir, `${prefix}-no-nested-git-${Date.now()}`) - const workspaceDir = path.join(tmpDir, `workspace-no-nested-git-${Date.now()}`) + const shadowDir = path.join(tmpDir, `${prefix}-no-child-git-${Date.now()}`) + const workspaceDir = path.join(tmpDir, `workspace-no-child-git-${Date.now()}`) - // Create a primary workspace repo without any nested repos. + // Create a primary workspace repo without any child repos. await fs.mkdir(workspaceDir, { recursive: true }) const mainGit = simpleGit(workspaceDir) await mainGit.init() @@ -468,13 +468,13 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( await mainGit.commit("Initial commit in main repo") vitest.spyOn(fileSearch, "executeRipgrep").mockImplementation(() => { - // Return empty array to simulate no nested git repos found + // Return empty array to simulate no child git repos found return Promise.resolve([]) }) const service = new klass(taskId, shadowDir, workspaceDir, () => {}) - // Verify that initialization succeeds when no nested git repos are detected + // Verify that initialization succeeds when no child git repos are detected await expect(service.initShadowGit()).resolves.not.toThrow() expect(service.isInitialized).toBe(true) From 37bedd04508d1ebe008cc81d619b0cf88d745601 Mon Sep 17 00:00:00 2001 From: John Cantu Date: Mon, 29 Sep 2025 15:47:38 -0700 Subject: [PATCH 4/4] fix regex match for modified error message --- .../checkpoints/__tests__/ShadowCheckpointService.spec.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts index 4b1e7336da4..9260e8956cf 100644 --- a/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts +++ b/src/services/checkpoints/__tests__/ShadowCheckpointService.spec.ts @@ -440,7 +440,7 @@ describe.each([[RepoPerTaskCheckpointService, "RepoPerTaskCheckpointService"]])( // Verify that initialization throws an error when child git repos are detected // The error message now includes the specific path of the child repository await expect(service.initShadowGit()).rejects.toThrowError( - /Checkpoints are disabled because a child git repository was detected at:/, + /Checkpoints are disabled because a Git repository was detected below the workspace root at: .*?\. To use checkpoints, please remove or relocate this git repository, or open a Git repository as the workspace root\./, ) // Clean up.