-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
kalatheme_lib_dir() rage! #73
Comments
Getting the same errors on pantheon: Warning: mkdir(): Permission denied in kalatheme_lib_dir() (line 345 of /srv/bindings/98feb60b74854cf88cd32ef8b6cc8fb3/code/sites/all/themes/kalatheme/includes/utils.inc). |
If you switch to SFTP mode on pantheon do these go away? On Fri, Jun 27, 2014 at 5:19 PM, katypool notifications@github.com wrote:
Cheers, Mike Pirog |
Yes they do |
@pirog @katypool it seems that we be using not the latest version of kalatheme, the code that was there (that this error generates) is now gone. As seen here: https://github.com/drupalprojects/kalatheme/blob/7.x-3.x/includes/utils.inc Even if we dont win with this codez, we can look into http://drupalcontrib.org/api/drupal/drupal%21includes%21file.inc/function/file_prepare_directory/7 |
pretty sure file_prepare_directory is what the libraries module uses so On Sat, Jun 28, 2014 at 10:59 AM, John Ouellet notifications@github.com
Cheers, Mike Pirog |
we could also check if libraries is installed and just use the directory On Sat, Jun 28, 2014 at 11:51 AM, Mike Pirog mike@kalamuna.com wrote:
Cheers, Mike Pirog |
you are correct, i looked at most contrib modules and that api function is used a few places. |
@labboy0276 if GIT mode is enabled on pantheon you are just not going to have permission to create this dir on pantheon (and likely other things as well)... there may be an authorize.php implementation that solves the problem. I noticed that panopoly spins up with SFTP mode on by default instead of git, probably so it can install apps, so that is worth looking into also. |
@labboy0276 there is an implementation in Kalatheme that uses the local file transfer protocol similar to teh apps module implementation that is probably your ticket to ride. |
Ok. So
The only point of this function is return the "location" of the libraries directory. Which may not exist yet if the user hasn't installed the libraries dir yet. It shouldn't try to create or change permissions on that dir at this point. It just wants to know where it is so another function can check if it is writable as part of a larger check to determine whether a user can upload a bootstrap library for their theme/subtheme or not.
All this stuff is just to determine whether the user can actually write to that dir using one of many methods. It does not seek to actually try to write to it at this point. That stuff should happen when the user actually tries to upload a custom library or build a subtheme. |
Aka this really should be something like this
|
#73: Fix kalatheme_lib_dir(), pantheon warning, create lib dir first
#73: Limit verbosity of bootstrap library warning on batch finish
OK. So, i've added a check to see if you are pantheon so the user is prompted to switch their connection mode to SFTP. As far as i understand things GIT mode will not currently allow us to create subthemes or install libraries on pantheon because drupal does not support a SFTP filetransfer protocol. this is the same result when you try to install a module or theme. @joshkoenig may have more insight here. I'm going to close this issue but if @katypool @labboy0276 and others can test on pantheon and reopen if applicable that would be great. |
I'm using Barracuda and had that issue but it now seems resolved. |
#73: Limit verbosity of bootstrap library warning on batch finish
So this is happening now on Pantheon only
Warning: mkdir(): Permission denied in kalatheme_lib_dir() (line 345 of /srv/bindings/88bc69aeba2d4570a5229486c6e0d244/code/profiles/hotsauce/themes/kalatheme/includes/utils.inc)
On Install, also it gives a chmod error from the code I wrote before.
We will need to see what the right syntax is or how to make the directory and change the perms in something like pantheon
The text was updated successfully, but these errors were encountered: