Skip to content

Fix tqdm progress bar rendering in GitHub Actions logs - #6949

Open
mataylor-nvidia wants to merge 2 commits into
isaac-sim:developfrom
mataylor-nvidia:mataylor/fix-tqdm-ci-logs
Open

Fix tqdm progress bar rendering in GitHub Actions logs#6949
mataylor-nvidia wants to merge 2 commits into
isaac-sim:developfrom
mataylor-nvidia:mataylor/fix-tqdm-ci-logs

Conversation

@mataylor-nvidia

Copy link
Copy Markdown

Description

The "Prefilling reset buffer" tqdm progress bar in
isaaclab_tasks/core/lift/mdp/events.py renders as garbled Unicode block
characters in GitHub Actions logs. The root cause is that tqdm uses
carriage-return (\r) overwriting to update the bar in place; GitHub's log
viewer does not support \r, so each update is emitted as a new line full of
characters.

Fix: add disable=not sys.stderr.isatty() to the tqdm call so the bar
is suppressed when stderr is not a terminal (i.e. in CI). Replace the missing
output with logging.info calls at start and on completion so CI logs still
confirm the buffer fill is running and when it finishes.

No behaviour change in interactive terminals — tqdm renders normally there.

Fixes # (issue)

Type of change

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

Checklist

  • I have read and understood the contribution guidelines
  • I have run the pre-commit checks with ./isaaclab.sh --format
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • I have added a changelog fragment under source/<pkg>/changelog.d/ for every touched package (do not edit CHANGELOG.rst or bump extension.toml — CI handles that)
  • I have added my name to the CONTRIBUTORS.md or my name already exists there

The "Prefilling reset buffer" tqdm bar renders as garbled block
characters in GitHub Actions logs because the log viewer does not
support carriage-return-based line overwriting.

Add disable=not sys.stderr.isatty() so the bar is suppressed when
running in CI. Replace the missing terminal output with logging.info
calls at the start and on completion so CI logs still show meaningful
progress.
@greptile-apps

greptile-apps Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Too many files changed for review (3000 files, 100 file limit).

@mataylor-nvidia
mataylor-nvidia changed the base branch from main to develop August 6, 2026 20:38
@mataylor-nvidia
mataylor-nvidia requested a review from StafaH as a code owner August 6, 2026 20:38
@mataylor-nvidia
mataylor-nvidia requested a review from a team August 6, 2026 20:38

@isaaclab-review-bot isaaclab-review-bot Bot 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.

Isaac Lab Review Bot

The TTY-aware tqdm suppression is a minimal, non-breaking fix, but two maintainability issues should be corrected before merge: the logger assignment interrupts the import block, and the changelog uses incorrect Sphinx roles that may produce unresolved references.

  • Design and architecture: Applying disable=not sys.stderr.isatty() at tqdm construction preserves the existing prefill control flow and keeps progress.update() valid in both interactive and non-interactive environments. No architectural concern was found with this approach.
  • API: No public signatures, defaults, return types, or exported symbols change. Interactive behavior remains intact, while non-TTY output changes only in presentation, so no deprecation or public API documentation updates are required.
  • Implementation: Move _log = logging.getLogger(__name__) below the complete import block to preserve PEP 8 import ordering and avoid E402/isort failures. In the changelog, reference isaaclab_tasks.core.lift.mdp.events with :mod: rather than :func:, and render the third-party tqdm name as a literal instead of an unresolved :class: target.

Minor fixes needed. Posted 2 actionable findings inline.

Automated review; human maintainers own approval decisions.

^^^^^

* Fixed the "Prefilling reset buffer" progress bar in
:func:`~isaaclab_tasks.core.lift.mdp.events` rendering as garbled block

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.

🟡 Warning · Implementation — Incorrect Sphinx roles in changelog fragment

isaaclab_tasks.core.lift.mdp.events is a module, so :func: will not resolve once the fragment is compiled into CHANGELOG.rst; likewise :class:tqdm targets an external package with no such documented class. Use `:mod:` for the module and plain literal markup (tqdm``) for the third-party library to avoid broken references in the generated changelog.

import warp as wp
from tqdm import tqdm

_log = logging.getLogger(__name__)

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.

🟡 Warning · Implementation — Logger assignment splits the import block

_log = logging.getLogger(__name__) is inserted between the third-party imports and the isaaclab imports, so module-level executable code now precedes imports. This breaks PEP 8 import ordering (E402) and leaves isort with two disjoint import sections, which can churn under the formatting hooks. Move the logger definition below the final import block.

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.

1 participant