Development

#390 (cache->remove: error if dir does not exits)

You must first sign up to be able to contribute.

Ticket #390 (closed defect: fixed)

Opened 3 years ago

Last modified 2 years ago

cache->remove: error if dir does not exits

Reported by: pixelpope Assigned to:
Priority: major Milestone: 0.6.3
Component: Version: 0.6.1
Keywords: Cc:
Qualification:

Description

Hey there. I'm referring to this forum thread: http://www.symfony-project.com/forum/index.php/m/4599/

When trying to remove a page from cache, that has not yet been accessed, an error occurs (example code):

message:  	Unable to open cache directory "/www/htdocs/domain/cache/frontend/prod/template//domain_com/all/page/show/10"
code: 	N/A
class: 	sfFileCache
file: 	/www/htdocs/domain/lib/symfony/cache/sfFileCache.class.php
line: 	357

Well that's pretty straightforward I guess. If the directory structure Symfony is looking for the cache in does not exist yet, this error occurs.

I worked around this with

if (has(...)) remove(...)

in my remove action, but I guess it would be easier to put the if(has()) right into the remove that is called. Or whatever. I'm pretty new to Symfony, so you probably shouldn't listen to me. ;)

Also, notice the double slash before the domain? Looks a bit strange to me. Is that normal?

Change History

04/10/06 11:13:41 changed by fabien

  • milestone set to 0.6.3.

06/16/06 09:46:47 changed by fabien

  • milestone changed from 0.6.3 to 1.0.0.

06/16/06 17:11:20 changed by fabien

  • status changed from new to closed.
  • resolution set to fixed.
  • milestone changed from 0.6.4 to 0.6.3.

in r1468