Bug Report
Describe the bug
In agentlightning/verl/trainer.py, _train_step calls _dump_generations without passing the required gts argument, causing a TypeError at runtime when trainer.rollout_data_dir is set.
Error message
File "agentlightning/verl/trainer.py", line 421, in _train_step
self._dump_generations(
TypeError: RayPPOTrainer._dump_generations() missing 1 required positional argument: 'gts'
Steps to Reproduce
- Set
rollout_data_dir in the trainer config
- Run training — the error is triggered at the rollout generation dump step
Root Cause
_dump_generations is defined with gts as a required positional argument:
def _dump_generations(self, inputs, outputs, gts, scores, reward_extra_infos_dict, dump_path):
But the call site in _train_step does not pass gts:
self._dump_generations(
inputs=inputs,
outputs=outputs,
scores=scores,
reward_extra_infos_dict=reward_extra_infos_dict,
dump_path=rollout_data_dir,
)
Suggested Fix
Either pass gts=None at the call site, or give gts a default value of None in the function signature to make it optional when ground truth is unavailable.
Environment
- Version: v0.3.0
- File:
agentlightning/verl/trainer.py
- Class:
RayPPOTrainer
Bug Report
Describe the bug
In
agentlightning/verl/trainer.py,_train_stepcalls_dump_generationswithout passing the requiredgtsargument, causing aTypeErrorat runtime whentrainer.rollout_data_diris set.Error message
Steps to Reproduce
rollout_data_dirin the trainer configRoot Cause
_dump_generationsis defined withgtsas a required positional argument:But the call site in
_train_stepdoes not passgts:Suggested Fix
Either pass
gts=Noneat the call site, or givegtsa default value ofNonein the function signature to make it optional when ground truth is unavailable.Environment
agentlightning/verl/trainer.pyRayPPOTrainer