Skip to content

Fixes RSL RL imports - #4871

Merged
kellyguo11 merged 2 commits into
isaac-sim:developfrom
kellyguo11:fix-rsl-rl
Mar 7, 2026
Merged

kellyguo11 merged 2 commits into
isaac-sim:developfrom
kellyguo11:fix-rsl-rl

Conversation

@kellyguo11

Copy link
Copy Markdown
Contributor

Description

Fixes some missing imports for RSL RL

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 updated the changelog and the corresponding version in the extension's config/extension.toml file
  • I have added my name to the CONTRIBUTORS.md or my name already exists there

@github-actions github-actions Bot added bug Something isn't working isaac-lab Related to Isaac Lab team labels Mar 7, 2026
@greptile-apps

greptile-apps Bot commented Mar 7, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR is a small bug fix that adds two missing exports — RslRlMLPModelCfg and RslRlRNNModelCfg — to the RSL-RL type stub file (__init__.pyi), making them accessible when importing from isaaclab_rl.rsl_rl.

  • Both classes are confirmed to exist in rl_cfg.py, so the imports are valid and correctly wired.
  • __all__ and the from .rl_cfg import (...) block are updated consistently.
  • RslRlCNNModelCfg, also defined in rl_cfg.py, remains absent from the exports — worth confirming whether this is intentional.

Confidence Score: 5/5

  • This PR is safe to merge — it only adds missing type stub exports that are already correctly implemented in the source.
  • The change is minimal and low-risk: two class names are added to __all__ and one import block in a .pyi stub file. Both classes (RslRlMLPModelCfg, RslRlRNNModelCfg) are verified to exist in rl_cfg.py. No logic, runtime behavior, or existing exports are modified.
  • No files require special attention.

Important Files Changed

Filename Overview
source/isaaclab_rl/isaaclab_rl/rsl_rl/init.pyi Adds RslRlMLPModelCfg and RslRlRNNModelCfg to __all__ and to the from .rl_cfg import block; both classes exist in rl_cfg.py, so the fix is correct. RslRlCNNModelCfg (also in rl_cfg.py) remains unexported, which may or may not be intentional.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A["isaaclab_rl.rsl_rl\n(__init__.py / __init__.pyi)"] --> B["rl_cfg.py"]
    A --> C["rnd_cfg.py"]
    A --> D["symmetry_cfg.py"]
    A --> E["distillation_cfg.py"]
    A --> F["exporter.py"]
    A --> G["vecenv_wrapper.py"]
    A --> H["utils.py"]

    B --> B1["RslRlMLPModelCfg ✅ (added)"]
    B --> B2["RslRlRNNModelCfg ✅ (added)"]
    B --> B3["RslRlCNNModelCfg ⚠️ (not exported)"]
    B --> B4["RslRlPpoAlgorithmCfg"]
    B --> B5["RslRlBaseRunnerCfg"]
    B --> B6["RslRlOnPolicyRunnerCfg"]
    B --> B7["RslRlPpoActorCriticCfg"]
    B --> B8["RslRlPpoActorCriticRecurrentCfg"]
Loading

Last reviewed commit: 4f4d67f

Comment on lines 36 to 41
RslRlPpoActorCriticCfg,
RslRlPpoActorCriticRecurrentCfg,
RslRlPpoAlgorithmCfg,
RslRlMLPModelCfg,
RslRlRNNModelCfg,
)

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.

RslRlCNNModelCfg also missing from exports

rl_cfg.py defines three model config classes — RslRlMLPModelCfg, RslRlRNNModelCfg, and RslRlCNNModelCfg (line 114 in rl_cfg.py). This PR correctly adds the first two, but RslRlCNNModelCfg is still absent from both __all__ and the from .rl_cfg import (...) block. If this class is intended to be public, it should be exported here in the same way. If it is intentionally unexposed (e.g., experimental), a comment in rl_cfg.py explaining this would help future contributors avoid making the same fix again.

@kellyguo11
kellyguo11 merged commit b8ac392 into isaac-sim:develop Mar 7, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working isaac-lab Related to Isaac Lab team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants