Strange behavior with prod environment (app.php)

New topics about Symfony 2 should go here

Moderators: dcobalt, tiagojsag

Strange behavior with prod environment (app.php)

Postby diegocaprioli » Wed Feb 29, 2012 3:25 pm

Hello,

I was having a problem with my prod environment. Dev environment worked perfectly. When I tried to browse the website using prod environment, I only got blank pages.

I checked my prod.log file, and I saw this:

Code: Select all
[2012-02-29 13:54:43] request.CRITICAL: Exception thrown when handling an exception (InvalidArgumentException: The directory "C:\nnn\website\app/cache/prod_new/annotations" does not exist.) [] []


So I checked the permissions of my app/cache folder to verify that it could work on them. The permissions were fine.
What I didn't understand is why it tries to work with the "pord_new" environment. I searched where in my project was the text "prod_new" used, and I saw that it was only referenced in several lines in the file app/cache/prod/appProdProjectContainer.php. I cleared the pord cache, but the conseole threw a similar error than the log:

Code: Select all
Unable to write in the "C:\nnn\website\app/cache/prod_new" directory


So I deleted manually all the folders in the app/cache folder, and now it works perfectly on both environments, dev and prod. Now, the file app/cache/prod/appProdProjectContainer.php hasn't any reference to prod_new.

I'm sure that I never changed the name of the environment, so I'm a bit perplexed about how this "prod_new" came to be in that code... This is not urgent, because I already solved the problem. But I'm new to version 2 of symfony, and wanted to leran a bit more of this mecanism and if there is anyone had a similar problem and know the cause?

Thanks in advance!
User avatar
diegocaprioli
Member
 
Posts: 38
Joined: Thu Apr 19, 2007 11:44 am

Return to General Symfony 2 discussion

Who is online

Users browsing this forum: Bing [Bot], Eiradiana and 19 guests