Skip to content

Unable to run the quick start example #137

@JustinTong0323

Description

@JustinTong0323

Reproduce: follow the instruction in quickstart, at Step 4: Agent Training with GRPO, would have this error:

[2025-07-08 19:37:12,747] [INFO] [real_accelerator.py:254:get_accelerator] Setting ds_accelerator to cuda (auto detect)
[2025-07-08 19:37:14,247] [INFO] [logging.py:107:log_dist] [Rank -1] [TorchCheckpointEngine] Initialized with serialization = False
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/root/xinyuan/sgl-workspace/rllm/examples/math_tool/train_math_with_tool.py", line 7, in <module>
    from rllm.trainer.agent_trainer import AgentTrainer
  File "/root/xinyuan/sgl-workspace/rllm/rllm/trainer/__init__.py", line 6, in <module>
    from .agent_trainer import AgentTrainer
  File "/root/xinyuan/sgl-workspace/rllm/rllm/trainer/agent_trainer.py", line 6, in <module>
    from rllm.trainer.verl.train_agent_ppo import train_agent
  File "/root/xinyuan/sgl-workspace/rllm/rllm/trainer/verl/train_agent_ppo.py", line 9, in <module>
    from rllm.trainer.env_agent_mappings import AGENT_CLASS_MAPPING, ENV_CLASS_MAPPING
  File "/root/xinyuan/sgl-workspace/rllm/rllm/trainer/env_agent_mappings.py", line 17, in <module>
    "swe": safe_import("rllm.environments.swe.swe", "SWEEnv"),
  File "/root/xinyuan/sgl-workspace/rllm/rllm/trainer/env_agent_mappings.py", line 3, in safe_import
    module = __import__(module_path, fromlist=[class_name])
  File "/root/xinyuan/sgl-workspace/rllm/rllm/environments/swe/swe.py", line 19, in <module>
    R2EGYM_PATH = os.path.dirname(r2egym.__file__)
AttributeError: 'NoneType' object has no attribute '__file__'. Did you mean: '__le__'?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions