title: How to render a choice field in a template
body: <p>I use Symfony2 and twig as template engine. </p>
  
  <p>In my controller I have the following form:</p>
  
  <pre><code>      $usr= $this-&gt;get('security.context')-&gt;getToken()-&gt;getUser();      
        $associatedmissions = array($usr-&gt;getMissions());
  
        $form = $this-&gt;createFormBuilder($product)        
         -&gt;add('mission', 'choice', array(
              'choices'   =&gt; $associatedmission,
              'multiple'  =&gt;  false,
              'expanded'  =&gt; true, ))
  </code></pre>
  
  <p>But when I call the page, appears an error:</p>
  
  <pre><code>Catchable Fatal Error: Object of class Doctrine\ORM\PersistentCollection could not be 
  converted to string in 
  C:\BitNami\wampstack-5.4.23-
  0\frameworks\symfony\vendor\symfony\symfony\src\Symfony\Component\Translation\
  IdentityTranslator.php line 65
  </code></pre>
  
  <p>In the profiler I can see the error:</p>
  
  <pre><code>CRITICAL - Uncaught PHP Exception Twig_Error_Runtime: "An exception has been thrown 
  during the rendering of a template ("") in "form_div_layout.html.twig" at line 99." at 
  C:\BitNami\wampstack-5.4.23-0\frameworks\symfony\app\cache\dev\classes.php line 4372 
  
  Context: {"exception":"Object(Twig_Error_Runtime)"}
  </code></pre>
  
  <p>What happened?</p>
  
  <p>It's strange because with it works properly</p>
  
  <pre><code>-&gt;add('mission', 'entity')
  </code></pre>
  
  <p>-UPDATE--</p>
  
  <p>Here my controller:</p>
  
  <pre><code>public function createAction(Request $request)
     {                                           
         $product = new Product();
  
         $usr= $this-&gt;get('security.context')-&gt;getToken()-&gt;getUser();      
         $associatedmissions = array($usr-&gt;getMissions());
  
            $form = $this-&gt;createFormBuilder($product)                                      
             -&gt;add('name', 'text')
             -&gt;add('mission', 'choice', array(
                  'choices'   =&gt; $associatedmissions,
                  'multiple'  =&gt;  false,
                  'expanded'  =&gt; false, ))
  
             -&gt;add('save', 'submit')
             -&gt;getForm();    
  
  
         $form-&gt;handleRequest($request);
         if ($form-&gt;isValid()) {
  
           $em = $this-&gt;getDoctrine()-&gt;getManager();    
           $em-&gt;persist($product);
           $em-&gt;flush();
  
         return $this-&gt;render('AcmeGroundStationBundle:Product:tasksuccess.html.twig', array('product' =&gt; $product));
         }    
  
         return $this-&gt;render('AcmeGroundStationBundle:Product:formupload.html.twig', array(
         'form' =&gt; $form-&gt;createView()
         ));
  }
  </code></pre>