is-uploaded-file

Symfony HttpFoundation UploadedFile “not uploaded due to unknown error” when using Doctrine DataFixtures

♀尐吖头ヾ 提交于 2019-12-09 18:29:47
问题 I've been using my Attachment entity based on the cookbook recipie How To Handle File Uploads With Doctrine in Symfony 2.3. It works well, even in functional tests. However using it with Doctrine DataFixtures is causing me problems. [Symfony\Component\HttpFoundation\File\Exception\FileException] The file "o-rly-copy.jpg" was not uploaded due to an unknown error. This was not helpful, however I did run php app/console doctrine:fixtures:load -v to bring up a stack trace and it appears the

Symfony HttpFoundation UploadedFile “not uploaded due to unknown error” when using Doctrine DataFixtures

浪子不回头ぞ 提交于 2019-12-04 09:53:50
I've been using my Attachment entity based on the cookbook recipie How To Handle File Uploads With Doctrine in Symfony 2.3. It works well, even in functional tests. However using it with Doctrine DataFixtures is causing me problems. [Symfony\Component\HttpFoundation\File\Exception\FileException] The file "o-rly-copy.jpg" was not uploaded due to an unknown error. This was not helpful, however I did run php app/console doctrine:fixtures:load -v to bring up a stack trace and it appears the exception is thrown not on the persisting method, but on $manager->flush() Attachment::setFile() requires an