Skip to content

Simplify delete file|dir to just delete path#2181

Merged
djeebus merged 6 commits into
mainfrom
simplify-deletes
Mar 20, 2026
Merged

Simplify delete file|dir to just delete path#2181
djeebus merged 6 commits into
mainfrom
simplify-deletes

Conversation

@djeebus

@djeebus djeebus commented Mar 19, 2026

Copy link
Copy Markdown
Contributor

Note

Medium Risk
Medium risk because it changes the gRPC surface (renamed RPCs/messages) and alters deletion semantics to recursive DeletePath, which could remove directories if callers pass broader paths than intended.

Overview
This PR updates the volumes gRPC API to use clearer, operation-scoped RPC names (e.g., CreateVolume, DeleteVolume, StatPath, UpdatePath) and replaces separate file/dir delete operations with a single recursive DeletePath endpoint that validates existence and blocks deleting /; the API service is updated accordingly, and orchestrator tests are reshaped to cover the new request/response types and DeletePath behavior (including directories and symlinks).

Written by Cursor Bugbot for commit fec8cfa. This will update automatically on new commits. Configure here.

Comment thread packages/orchestrator/pkg/volumes/path_delete.go

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 77fbe9288e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/orchestrator/internal/volumes/path_delete.go Outdated
Comment thread packages/orchestrator/pkg/volumes/path_delete.go
Comment thread packages/orchestrator/pkg/volumes/path_delete.go Outdated
dobrac
dobrac previously requested changes Mar 20, 2026

@dobrac dobrac left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, just the broken symlink handling

Comment thread packages/orchestrator/pkg/volumes/path_delete.go Outdated
Comment thread packages/orchestrator/pkg/volumes/path_delete_test.go

@levb levb left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

++ to prior comment on symlink/test; No other comments.

djeebus added 2 commits March 20, 2026 10:47
# Conflicts:
#	packages/orchestrator/internal/volumes/file_delete.go
#	packages/orchestrator/internal/volumes/file_update.go
#	packages/orchestrator/internal/volumes/stat.go
#	packages/orchestrator/internal/volumes/stat_test.go
#	packages/orchestrator/pkg/volumes/dir_delete.go
#	packages/orchestrator/pkg/volumes/dir_delete_test.go
#	packages/orchestrator/pkg/volumes/file_delete.go
#	packages/orchestrator/pkg/volumes/file_delete_test.go
#	packages/orchestrator/pkg/volumes/file_update.go
#	packages/orchestrator/pkg/volumes/file_update_test.go
#	packages/orchestrator/pkg/volumes/internal_test.go
#	packages/orchestrator/pkg/volumes/path_delete.go
#	packages/orchestrator/pkg/volumes/path_delete_test.go
#	packages/orchestrator/pkg/volumes/path_stat.go
#	packages/orchestrator/pkg/volumes/path_stat_test.go
#	packages/orchestrator/pkg/volumes/path_update.go
#	packages/orchestrator/pkg/volumes/stat.go
#	packages/orchestrator/pkg/volumes/stat_test.go
#	packages/orchestrator/pkg/volumes/utils_test.go

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Comment thread packages/orchestrator/pkg/volumes/path_delete_test.go

target := "symlink-target.txt"
link := "symlink-to-delete"
target := "broken-symlink-target.txt"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LOL add parallel-tests-are-hard-437-uniq... :)

@levb levb left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@djeebus djeebus dismissed dobrac’s stale review March 20, 2026 18:33

implemented the fixes

@djeebus djeebus merged commit 3c2f7d9 into main Mar 20, 2026
65 of 66 checks passed
@djeebus djeebus deleted the simplify-deletes branch March 20, 2026 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants