prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  repr for particle unions
  The `__repr__` for particle unions should include the contents of `sub_types`
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `yt/data_objects/unions.py`
  Content:
  ```
  1 from yt.funcs import ensure_list
  2 
  3 class Union(object):
  4     def __init__(self, name, sub_types):
  5         self.name = name
  6         self.sub_types = ensure_list(sub_types)
  7 
  8     def __iter__(self):
  9         for st in self.sub_types:
  10             yield st
  11 
  12 class MeshUnion(Union):
  13     def __init__(self, name, sub_types):
  14         super(MeshUnion, self).__init__(name, sub_types)
  15
  ```
  
  Path: `yt/data_objects/particle_unions.py`
  Content:
  ```
  1 from .unions import Union
  2 
  3 class ParticleUnion(Union):
  4     def __init__(self, name, sub_types):
  5         super(ParticleUnion, self).__init__(name, sub_types)
  6
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/yt/data_objects/particle_unions.py b/yt/data_objects/particle_unions.py
  --- a/yt/data_objects/particle_unions.py
  +++ b/yt/data_objects/particle_unions.py
  @@ -1,5 +1,6 @@
   from .unions import Union
   
   class ParticleUnion(Union):
  +    _union_type = "particle"
       def __init__(self, name, sub_types):
           super(ParticleUnion, self).__init__(name, sub_types)
  diff --git a/yt/data_objects/unions.py b/yt/data_objects/unions.py
  --- a/yt/data_objects/unions.py
  +++ b/yt/data_objects/unions.py
  @@ -1,6 +1,7 @@
   from yt.funcs import ensure_list
   
   class Union(object):
  +    _union_type = ""
       def __init__(self, name, sub_types):
           self.name = name
           self.sub_types = ensure_list(sub_types)
  @@ -9,6 +10,11 @@
           for st in self.sub_types:
               yield st
   
  +    def __repr__(self):
  +        return "{} Union: '{}' composed of: {}".format(
  +            self._union_type.capitalize(), self.name, self.sub_types)
  +
   class MeshUnion(Union):
  +    _union_type = "mesh"
       def __init__(self, name, sub_types):
           super(MeshUnion, self).__init__(name, sub_types)
  
verification_info: {"golden_diff": "diff --git a/yt/data_objects/particle_unions.py b/yt/data_objects/particle_unions.py\n--- a/yt/data_objects/particle_unions.py\n+++ b/yt/data_objects/particle_unions.py\n@@ -1,5 +1,6 @@\n from .unions import Union\n \n class ParticleUnion(Union):\n+    _union_type = \"particle\"\n     def __init__(self, name, sub_types):\n         super(ParticleUnion, self).__init__(name, sub_types)\ndiff --git a/yt/data_objects/unions.py b/yt/data_objects/unions.py\n--- a/yt/data_objects/unions.py\n+++ b/yt/data_objects/unions.py\n@@ -1,6 +1,7 @@\n from yt.funcs import ensure_list\n \n class Union(object):\n+    _union_type = \"\"\n     def __init__(self, name, sub_types):\n         self.name = name\n         self.sub_types = ensure_list(sub_types)\n@@ -9,6 +10,11 @@\n         for st in self.sub_types:\n             yield st\n \n+    def __repr__(self):\n+        return \"{} Union: '{}' composed of: {}\".format(\n+            self._union_type.capitalize(), self.name, self.sub_types)\n+\n class MeshUnion(Union):\n+    _union_type = \"mesh\"\n     def __init__(self, name, sub_types):\n         super(MeshUnion, self).__init__(name, sub_types)\n", "issue": "repr for particle unions\nThe `__repr__` for particle unions should include the contents of `sub_types`\n", "before_files": [{"content": "from yt.funcs import ensure_list\n\nclass Union(object):\n    def __init__(self, name, sub_types):\n        self.name = name\n        self.sub_types = ensure_list(sub_types)\n\n    def __iter__(self):\n        for st in self.sub_types:\n            yield st\n\nclass MeshUnion(Union):\n    def __init__(self, name, sub_types):\n        super(MeshUnion, self).__init__(name, sub_types)\n", "path": "yt/data_objects/unions.py"}, {"content": "from .unions import Union\n\nclass ParticleUnion(Union):\n    def __init__(self, name, sub_types):\n        super(ParticleUnion, self).__init__(name, sub_types)\n", "path": "yt/data_objects/particle_unions.py"}], "after_files": [{"content": "from yt.funcs import ensure_list\n\nclass Union(object):\n    _union_type = \"\"\n    def __init__(self, name, sub_types):\n        self.name = name\n        self.sub_types = ensure_list(sub_types)\n\n    def __iter__(self):\n        for st in self.sub_types:\n            yield st\n\n    def __repr__(self):\n        return \"{} Union: '{}' composed of: {}\".format(\n            self._union_type.capitalize(), self.name, self.sub_types)\n\nclass MeshUnion(Union):\n    _union_type = \"mesh\"\n    def __init__(self, name, sub_types):\n        super(MeshUnion, self).__init__(name, sub_types)\n", "path": "yt/data_objects/unions.py"}, {"content": "from .unions import Union\n\nclass ParticleUnion(Union):\n    _union_type = \"particle\"\n    def __init__(self, name, sub_types):\n        super(ParticleUnion, self).__init__(name, sub_types)\n", "path": "yt/data_objects/particle_unions.py"}]}