# How to migrate pettingzoo to RLlib?

**URL:** <https://discuss.ray.io/t/how-to-migrate-pettingzoo-to-rllib/13780>\
**Category:** RLlib\
**Created:** [February 20, 2024, 9:54pm UTC](https://discuss.ray.io/t/how-to-migrate-pettingzoo-to-rllib/13780 "2024-02-20T21:54:32Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![barbarey](https://avatars.discourse-cdn.com/v4/letter/b/d26b3c/32.png) [@barbarey](https://discuss.ray.io/u/barbarey)\
**Post date:** [February 20, 2024, 9:54pm UTC](https://discuss.ray.io/t/how-to-migrate-pettingzoo-to-rllib/13780/1 "2024-02-20T21:54:32Z")

</div>

Currently i have a Pettingzoo environment that i wanted to train using RLlib but with no success. Is pettingzoo not compatible with RLlib? do i have to wrap my pettingzoo environment as a Gym environment? however how would that work with multiple agents? Should i just redo the environment following RLlib?

Im really lost right now so any help or links to documentation would be greatly appreciated!

This is the error i am currently getting:  
ray.exceptions.RayActorError: The actor died because of an error raised in its creation task, ray::RolloutWorker. **init** () (pid=25608, ip=127.0.0.1, actor\_id=701c132f8e476310db1e589201000000, repr=\<ray.rllib.evaluation.rollout\_worker.RolloutWorker object at 0x0000023DFFF6AA30\>)  
ValueError: Env must be of one of the following supported types: BaseEnv, gymnasium.Env, gym.Env, MultiAgentEnv, VectorEnv, RemoteBaseEnv, ExternalMultiAgentEnv, ExternalEnv, but instead is of type \<class ‘EVenv.DepotEnv’\>.
