Acorn/paths.storage does not work always

I have:

  • sage v10.2.0
  • roots/acorn 2.1.2

My host does not allow editing wp-content/cache. I found the acorn/paths.storage filter which has solved most of the issues as I can move the cache folder to wp-content/uploads/sage-cache

A couple of issues remain:

  1. I had to manually create the folder structure in the new cache folder. Otherwise I’m getting an exception The /app/wp-content/uploads/sage-cache/framework/cache directory must be present and writable.. I would expect this to be done automatically.
  2. I am still seeing one warning: Warning: mkdir(): Permission denied in /app/wp-content/themes/conspicuous/vendor/illuminate/filesystem/Filesystem.php on line 602

The following is still being attempted to be created: /app/wp-content/cache/acorn/framework/cache/data despite me having a custom acorn/paths.storage location. Judging by some printing, the filter function is being called after the above mkdir attempt which might be origin of the issue.

Could someone suggest on how to further force custom cache folder.

I have the same version of Acorn. The cache folder shouldn’t be located in the wp-content folder anymore but in the bedrock root folder: /app/cache. But I guess you don’t use Bedrock?

Correct: I do not use Bedrock. Even if it was in /app/cache that would not work for me as the only writable folder on the host is wp-content/uploads

Solved with a symlink (as indicated here: How to change Acorn's default path?). But I should not have had to do that, since I have used the filter.