Skip to content

[CLI] Increase default --limit from 10 to 30 for list commands#4181

Merged
Wauplin merged 2 commits into
mainfrom
cli-default-limit-30
May 4, 2026
Merged

[CLI] Increase default --limit from 10 to 30 for list commands#4181
Wauplin merged 2 commits into
mainfrom
cli-default-limit-30

Conversation

@Wauplin

@Wauplin Wauplin commented May 4, 2026

Copy link
Copy Markdown
Collaborator

Context: https://huggingface.slack.com/archives/C03V11RNS7P/p1777634553808299

Summary

  • Bump the default --limit from 10 to 30 for hf models list, hf datasets list, and hf spaces list.
  • 10 felt too few as a default — 30 gives a better overview without being overwhelming.
  • Other commands (hf spaces search, hf datasets leaderboard) are left unchanged.

🤖 Generated with Claude Code


Note

Low Risk
Low risk: changes only the default pagination size for hf models/datasets/spaces ls, with no auth, data mutation, or protocol changes; main impact is slightly larger API responses by default.

Overview
Increases the default --limit from 10 → 30 for hf models ls, hf datasets ls, and hf spaces ls, and updates the generated CLI docs to match.

Centralizes this default as REPO_LIST_DEFAULT_LIMIT in cli/_cli_utils.py and updates the “listing files” validation checks to compare against the new default constant.

Reviewed by Cursor Bugbot for commit e7fee43. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@Wauplin Wauplin requested review from hanouticelina and julien-c May 4, 2026 10:22

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

Reviewed by Cursor Bugbot for commit fc9b57d. Configure here.

Comment thread src/huggingface_hub/cli/models.py Outdated
@bot-ci-comment

bot-ci-comment Bot commented May 4, 2026

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@Wauplin Wauplin merged commit e2aad97 into main May 4, 2026
21 checks passed
@Wauplin Wauplin deleted the cli-default-limit-30 branch May 4, 2026 10:40
@huggingface-hub-bot

Copy link
Copy Markdown
Contributor

This PR has been shipped as part of the v1.14.0 release.

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.

2 participants