Skip to content

fix(browser): continue loading after empty object pages - #257

Merged
cxymds merged 3 commits into
rustfs:mainfrom
GatewayJ:fix/table-bucket-empty-page
Oct 7, 2026
Merged

cxymds merged 3 commits into
rustfs:mainfrom
GatewayJ:fix/table-bucket-empty-page

Conversation

@GatewayJ

@GatewayJ GatewayJ commented Oct 7, 2026 •

Copy link
Copy Markdown
Member

Description

Object Browser stops on an empty protected-listing page even when RustFS returns a continuation token. Keep the next-page controls available, distinguish a partial listing from an empty bucket, and resume viewport-driven loading when the current request finishes. Failed append requests retain manual retry without an automatic retry loop.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

Testing

  • Unit tests added/updated
  • Manual testing completed

Validated commit 7ab8480: frozen install, type-check, lint, format check, all 636 tests, and git diff --check passed on Node 22.

Automated hook tests mount the production useObjectListPagination with React and a mocked IntersectionObserver and append request. They cover resuming after loading clears, disconnecting during loading, stopping automatic retries after errors, and explicit retry. happy-dom is a development-only dependency for these DOM tests, and test:run includes the hook suite. Mutation checks confirm that removing the loading dependency or error guard makes the corresponding test fail.

Real Next.js UI with deterministic S3 network fixtures reproduced the original failure on main and verified two empty pages followed by a visible object, final empty results, append failure and keyboard retry, manual loading without IntersectionObserver, and rejection of stale responses after a prefix change. Desktop, mobile, light, and dark states were inspected. Fixtures do not establish the original reporter's exact deployment cause.

Checklist

  • Code follows the project's style guidelines
  • Self-review completed
  • TypeScript types are properly defined
  • All commit messages are in English (Conventional Commits)
  • All existing tests pass
  • No new dependencies added, or they are justified

Related Issues

Fixes https://github.com/rustfs/backlog/issues/2730
Related report: rustfs/rustfs#8116

Screenshots (if applicable)

Same page and S3 response sequence, captured from the real UI with network fixtures. Screenshot assets are kept outside the implementation diff.

Before After
Stops on the empty first page Continues to the visible object

Additional Notes

Independent reviewer/simplifier found no actionable issues. The change preserves S3 request parameters, backend filtering, existing search behavior, and response scope guards.

@GatewayJ
GatewayJ requested review from cxymds and a balanced review from Copilot and removed request for cxymds October 7, 2026 05:07

Copilot AI 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.

Copilot review overview

🟡 Changes recommended

The central observer retry and resume behavior lacks automated behavioral coverage.

Review effort: Balanced
Findings: 1 Low severity

Open (1)
What changed in this PR

Fixes Object Browser pagination when protected listings return empty pages with continuation tokens.

Changes:

  • Adds a partial empty-page state and preserves pagination controls.
  • Resumes viewport loading after requests while preventing automatic failure retries.
  • Adds state tests and UI review evidence.
File Description
components/​object/​list.tsx Updates pagination UI and observer lifecycle.
lib/​object-list-state.ts Adds the partial display state.
tests/​lib/​object-list-state.test.ts Tests empty-page state resolution.
tests/​lib/​object-list-source.test.js Updates pagination source assertions.
docs/​ui-review/​register.md Records the UI fix and evidence.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread components/object/list.tsx Outdated
@cxymds
cxymds merged commit cda7ff9 into rustfs:main Oct 7, 2026
6 checks passed
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