Skip to content

fix: clarify trashbin expiration CLI help - #63160

Open
mvanhorn wants to merge 2 commits into
nextcloud:masterfrom
mvanhorn:fix/45418-clarify-trashbin-expiration
Open

fix: clarify trashbin expiration CLI help#63160
mvanhorn wants to merge 2 commits into
nextcloud:masterfrom
mvanhorn:fix/45418-clarify-trashbin-expiration

Conversation

@mvanhorn

@mvanhorn mvanhorn commented Aug 11, 2026

Copy link
Copy Markdown
  • Resolves: #

Summary

Update the Symfony command metadata in ExpireTrash::configure() so both the command description and optional user_id argument explain that the operation processes deleted files according to the configured trashbin retention and space policy. Make the wording explicit that supplying user IDs limits processing to those users, while omitting them processes all users; avoid implying that the trashbin feature is disabled or that every deleted file is forcibly removed. Preserve the existing execution path, retention behavior, all-user default, and app command registration.

The trashbin:expire command currently says that it “expires” a user's trashbin without explaining what expiration does. This leaves administrators unsure whether the command disables the trashbin, empties it unconditionally, or applies the configured retention and space policy. The production path calls Trashbin::expire(), which removes entries eligible under trashbin_retention_obligation and, where the policy permits, removes oldest entries to bring the trashbin back within its size limit. A recent server change clarified the special disabled-policy runtime output, but the command and user_id help text remain ambiguous; broader documentation is separately tracked in nextcloud/documentation#15421.

Fixes #45418

TODO

  • ...

Checklist

  • Code is properly formatted
  • Sign-off message is added to all commits
  • Tests (unit, integration, api and/or acceptance) are included
  • Screenshots before/after for front-end changes
    Not verified: this needs a person on the named hardware or environment.
  • Documentation (manuals or wiki) has been updated or is not required
  • Backports requested where applicable (ex: critical bugfixes)
  • Labels added where applicable (ex: bug/enhancement, 3. to review, feature component)
    Not run: no test command resolved in this workspace, so nothing was executed to pass.
  • Milestone added for target branch/version (ex: 32.x for stable32)
    Not run: no test command resolved in this workspace, so nothing was executed to pass.

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

AI was used for assistance.

@mvanhorn
mvanhorn requested a review from a team as a code owner August 11, 2026 10:51
@mvanhorn
mvanhorn requested review from come-nc, icewind1991, leftybournes and provokateurin and removed request for a team August 11, 2026 10:51

@come-nc come-nc 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.

The test should be removed and I’m not sold on the new description/help text.
"Processes deleted files" sounds confusing to me. It deletes expired files, it does not process them?

Per review: "Processes deleted files" was confusing since the command deletes
expired files rather than processing them. Description and help now say so
directly, and the test that pinned the exact wording is removed.
@mvanhorn

Copy link
Copy Markdown
Author

You are right on both counts. "Processes deleted files" was doing no work: the command deletes expired files, so the description and help now say that directly. The test pinning the exact wording is gone too, since it only asserted the strings back at themselves.

966f8a3.

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.

[Bug]: Clarification of expiring Trashbin

2 participants