I’m running the following command:
WP_CLI_PHP_ARGS=’-d include_path=vendor/google/appengine-php-sdk’ vendor/bin/wp –path=my-wordpress-project plugin list
And I’m getting the following error:
PHP Fatal error: Uncaught Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php:61
Stack trace:
#0 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/HandlerStack.php(42): GuzzleHttp\choose_handler()
#1 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Client.php(65): GuzzleHttp\HandlerStack::create()
#2 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/google/auth/src/HttpHandler/HttpHandlerFactory.php(33): GuzzleHttp\Client->__construct()
#3 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(124): Google\Auth\HttpHandler\HttpHandlerFactory::build()
#4 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(42): Google\Cloud\Storage\WordPress\get_google_storage_client()
#5 $PROJECT_DIR/my-wordpress-project/wp-settings.php(391): include_once('/home/yar/yaraj...')
#6 /home/yar/yaraj in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php on line 61
Fatal error: Uncaught Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php:61
Stack trace:
#0 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/HandlerStack.php(42): GuzzleHttp\choose_handler()
#1 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Client.php(65): GuzzleHttp\HandlerStack::create()
#2 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/google/auth/src/HttpHandler/HttpHandlerFactory.php(33): GuzzleHttp\Client->__construct()
#3 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(124): Google\Auth\HttpHandler\HttpHandlerFactory::build()
#4 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(42): Google\Cloud\Storage\WordPress\get_google_storage_client()
#5 $PROJECT_DIR/my-wordpress-project/wp-settings.php(391): include_once('/home/yar/yaraj...')
#6 /home/yar/yaraj in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php on line 61
Error: There has been a critical error on this website.Learn more about troubleshooting WordPress. There has been a critical error on this website.
Here is my composer.json:
{
"require": {
"google/cloud-tools": "^0.12.0",
"wp-cli/wp-cli-bundle": "^2.5"
},
"require-dev": {
"google/appengine-php-sdk": "^1.9"
}
}
Please let me know if it will help for me to provide any other info/details to identify the problem.
Thank you in advance!
]]>Error… Forgot what is the error on multisite.
]]>I want to run WordPress only in sub directory ‘news’,
so I’ve written in app.yaml
- url: /news/(.*\.(htm|html|css|js))$
static_files: wordpress/\1
….and so on,
and in wp-config.php
define( 'WP_SITEURL', $protocol_to_use . $_SERVER['HTTP_HOST'].'/news');
define( 'WP_HOME', $protocol_to_use . $_SERVER['HTTP_HOST'] .'/news');
But in this case, I couldn’t upload files.
It causes 403 error and error message says ‘HTTP error’.
How can I avoid it, or
is it not supporsed to be used in this way?
By uploading, it returns “A network error occurrd.” or 503 Error and nothing is Uploaded.
I’m using WordPress in Japanese, it says’アップロード中にエラーが発生しました。後ほど再度お試しください。’ (An error occurred in uploading. Please try again later.)
Of course, I already made a bucket and have typed “bucket name” in plugin setting page.
]]>Running WP 4.3.1 Theme FlatOn doesn’t work after activating GAE4WP, gives 500 Server error blank page, any listing of themes that do work? Twenty Fifteen is working.
]]>Hi,
I have recently purchased a SSL Certificate and have installed it into my App Engine application. I have ticked Serve images over HTTPS
in the settings but as the description said: Only new images will be served over HTTPS
.
This is strange as when I copy a image link that served over http, and just change it https, it works fine!!!
I have over 200 images and and simply can’t re upload them. Also the green padlock near the top is not showing and I need this as its a store.
How can I just force https on these image assets?? Thanks.
]]>I installed my WordPress website on GAE with no problems. It was quite easy. Created the storage bucket. Activate the GAE plugin. Added my email address and bucket name. Website is up and running. I removed W3 Total Cache and EWWW Image Optimizer plugin.
I checked my website performance on Google Page Speed Insights and PingDom and Google PageSpeed Insights gives me 11/100 (Desktop Version) and PingDom gives me 81/100. PingDom use to be 87/100 and Google Speed Inisghts was 88/100 (Desktop version)
Google Page Speed Insights says I need to:
Optimize images
Reduce server response time
Leverage browser caching
And I should consider:
Eliminate render-blocking JavaScript and CSS in above-the-fold content
Minify CSS
Minify JavaScript
Minify HTML
Should I still be using a .htaccess file that has rules for file types to leverage browser caching?
Should I still be using EWWW Image Optimizer?
Should I still be using W3 Total Cache to Minify?
Not sure how to Reduce server response time. I thought this wouldn’t be a problem since I’m using GAE.
Any help would be greatly appreciated!
]]>Hi GAE team, hi everybody,
We have configured a CNAME bucket as described here:
https://cloud.google.com/storage/docs/reference-uris#cname
With WordPress on GAE the image URIs look like this:
https://storage.googleapis.com/cdn.domain.com/IMG_20150904_152433120-119×89.jpg
How can we make WordPress use the CNAME URIs that look like this?
https://cdn.domain.com/IMG_20150904_152433120-119×89.jpg
If there is no option yet, could you please add CNAME bucket support to the GAE plugin?
Thanks in advance!
ianflorian
Hi,
Plugin could not be activated because it triggered a fatal error:
Warning: require_once(google/appengine/api/urlfetch_service_pb.php): failed to open stream: No such file or directory in /home/…../public_html/insuranceinfo.co.in/wp-content/plugins/google-app-engine/modules/urlfetch.php on line 72
Fatal error: require_once(): Failed opening required ‘google/appengine/api/urlfetch_service_pb.php’ (include_path=’.:/usr/lib/php:/usr/local/lib/php’) in /home/…../public_html/insuranceinfo.co.in/wp-content/plugins/google-app-engine/modules/urlfetch.php on line 72
Kindly assist
Regards
Himanshu
reference: https://www.ads-software.com/support/topic/featured-image-being-cropped
in modules/uploads.php lines 398 thru 408 the plugin specifies the arguments to the gae resizing/cropping feature provided by the google storage service. Unfortunately, the way it is currently implemented in this plugin, when an image size is specified with both width and height along with crop=>true, the output can only be sqaure. To allow for non-square dimensions the =s1234-c parameter needs to be replaced with =w1234-h1234-c. When crop is falsy, and the url therefore isn’t appended with the -c argument, then the =s1234 parameter behaves as expected.
]]>Hi Team ??
I have an image in the media library with text inserted in the caption field. With the GAE plugin disabled a caption shortcode is inserted:
[caption id="attachment_1422" align="alignnone" width="179"]
(Image url info goes here)
Caption Text goes here.
[/caption]
Once the GAE plugin is activated the caption shortcode is no longer inserted around the image when using the Add Media modal.
I’ve tested this with Twenty Fifteen theme and all other plugins disabled except for the GAE plugin.
Is there any modification we could make to the GAE plugin to allow for caption shortcodes to be inserted?
Thanks. Any help on this would be most appreciated.
]]>How is it possible to organize uploads like images in subfolders with WordPress in Google App Engine?
Are plugins like “Media File Manager Advanced” or “WordPress Media Folder” working?
Kind regards,
Bernd
When I try to activate this plugin GAE 1.6, I receive error:
]]>Warning: require_once(google/appengine/api/urlfetch_service_pb.php): failed to open stream: No such file or directory in
/wp-content/plugins/google-app-engine/modules/urlfetch.php on line 72Fatal error: require_once(): Failed opening required ‘google/appengine/api/urlfetch_service_pb.php’ (include_path=’.:/usr/local/php5.4/lib/php’) in
/wp-content/plugins/google-app-engine/modules/urlfetch.php on line 72
<\blockquote>How to resolve this ?
I need to use SendGrid for sending email.
But this plugin is conflicting with it. When I uncheck “Use App Engine Email Service”, and save changes, the page refreshes with “Use App Engine Email Service” checked again.
I’m in the latest WP, with all plugins updated.
]]>I have this error when i try to activate this extension.
Same problem after a copy-file of the extension directory.
Warning: require_once(google/appengine/api/urlfetch_service_pb.php): failed to open stream: No such file or directory in /wordpress/wp-content/plugins/google-app-engine/modules/urlfetch.php on line 72
Fatal error: require_once(): Failed opening required ‘google/appengine/api/urlfetch_service_pb.php’ (include_path=’.:/usr/share/php:/usr/share/pear’) in /wordpress/wp-content/plugins/google-app-engine/modules/urlfetch.php on line 72
]]>The “Our Clients” block used in a page [our-clients] works locally when I deactivate the “Google App Engine for WordPress” 1.6 Plugin, but that’s not my intent.
And I totally cannot manage it to work remotely on appspot.com servers.
Thanks for helping.
]]>Hi all
I’ve run into some difficulties when trying to upload media files from a child blog.
The setup is as follows:
Google App Engine v. 1.9.18 – runtime php 5.5 enabled
Wordpress 4.1.1
Google App Engine for WordPress v. 1.6
WordPress MU Domain Mapping v. 0.5.5.1
Multisite Plugin Manager v. 3.1.4
Admin Menu Tree Page View v. 2.6.9
Batcache Manager v. 1.2
Akismet v. 3.0.4
WP Bootstrap Menu v. 1.1.1
The initial setup was based upon this tutorial:
https://frankie.bz/blog/developers/wordpress-multisite-on-google-app-engine-php-beta/
In order to gain access to the admin panels on the “child”-sites (preventing https), I’ve altered the settings in wp-config.php regarding determining and setting http / https and adjusted settings in app.yaml according to this article:
https://stackoverflow.com/questions/22338756/gae-php-how-to-disable-https-for-wordpress
So far – that part now works – i’m able to login to the adminpanel for the “child”-sites (just no https!)
When trying to upload images to the “child”-site (wp-admin/media-new.php) causes a “Http error” on the screen.
When consulting the GAE log I can spot that /wp-admin/async-upload.php has an http-error 500: “PHP Fatal error: Google Cloud Storage filename missing from upload in Unknown on line 0”
(Additional information: if reloading the page (F5) after this error occurs, the GAE-instance crashes )
Uploading images from the main site [App Name].appspot.com works just fine.
Any pointers/leads on where to look for fixing this? ??
]]>Hi,
when trying to view the Media library in grid mode the upload.php fails to load on GAE. No error log on the dev. console, no trace message.
If I try it with the SDK’s dev_appserver.py, it gives the message on both console and webpage:
Fatal error: Uncaught exception 'InvalidArgumentException' with message 'Invalid options supplied: url_expiry_time_seconds' in /root/google-cloud-sdk/platform/google_appengine/php/sdk/google/appengine/api/cloud_storage/CloudStorageTools.php:193 Stack trace: #0 /root/nutcom-services/wordpress/wp-content/plugins/google-app-engine/modules/uploads.php(314)
… snip …
I believe this only happens since the 1.6 plugin update.
Upload.php with list mode seems to work.
Uploading a new media file gives back an error message, but the file on the bucket storage is created.
Hello,
Whenever I try to activate this plugin after deploying to the app engine I get a blank admin page and my admin logs give me this stack trace:
PHP Fatal error: Uncaught exception 'google\appengine\api\app_identity\AppIdentityException' with message 'The application is not valid.' in /base/data/home/runtimes/php/sdk/google/appengine/api/app_identity/AppIdentityService.php:285
Stack trace:
#0 /base/data/home/runtimes/php/sdk/google/appengine/api/app_identity/AppIdentityService.php(83): google\appengine\api\app_identity\AppIdentityService::applicationErrorToException(Object(google\appengine\runtime\ApplicationError))
Only the admin page is blank. The rest of the site is accessible and works.
]]>I want to lock down a wordpress project on GAE to be accessible only to domain users. I set up my app.yaml so all routes are login: required or login: admin , and in the appengine.google.com console, set it to use the “Google Apps domain” authentication type.
At first, it worked. However, now even if you are signed in to the domain, it behaves as if you are not authorized (returns error 500). I suspect that the difference is the instance was already warmed up the first time, whereas the second time, it was not.
Any way around this / has anyone experienced this problem and found a solution?
]]>Hi,
We got a problem in viewing media with grid mode. It takes very long to load all the images and their information, usually around 24 – 30 seconds on Google App Engine and Google Cloud Storage. Disabling this plugin can reduce the time to 2-3 seconds. Debugging showed that the bottleneck is at line 329, modules/uploads.php. Executing this line usually takes 0.5 – 0.8 seconds.
$file = get_attached_file( $id );
It is quite strange that get_attached_file with the same ID has been called before this line and is very fast. Tracing deep down to the get_attached_file function, which calls wp_upload_dir, in which wp_mkdir_p will be invoked. In wp_mkdir_p, we recognised that is_dir call is actually the root cause, accounting for most of the time taken. It seems this bug has something to do the underlying implementation of is_dir in Php Google App Engine. We thought there must be some caching mechanism behind it.
Have anyone encountered this? Do you have any suggestions or ideas that could be taken? At the moment, we use a hacky solution by adding is_writable check along with is_dir as following. It turned out that is_writable is far more faster than is_dir under Google App Engine.
// Workaround for GCS.
// as is_dir consumes too much time in Google App Engine and Cloud Storage
// we check if the directory is writable or not.
if ( file_exists( $target ) )
return is_writable($target) || @is_dir( $target );
It is also a question for WordPress. It seems very inefficient in calling wp_mkdir_p every time we call get_attached_file. is_dir may be very fast in dealing with local environments but working with remote Cloud Storage would incur high latency.
Thanks!
https://www.ads-software.com/plugins/google-app-engine/
Huge fan of cloud PaaS like Google App Engine, but so far things are running pretty slow on IoT.do. We moved everything over around the holidays, from Windows Azure actually. In your ‘Other Notes’, the Batcache plugin link works, but the Memcache link is broken. Is something else supposed to replace it? Definitely need better performance, or after the 60 day trial we’re moving again…
]]>I am using WP 3.9.1 , installed on the Google App Engine (https://emumbawp.appspot.com/) – When I upload media, I get an HTTP error and an error code of 500 in the response. I installed plugin “google-app-engine”(https://www.ads-software.com/plugins/google-app-engine/) which supporrs media upload but still having the problem. I reviewed my file modules/uploads.php but no conflict there. Any suggestions?
]]>Hello,
I am trying to upload some media from the frontend of the wordpress site. I am using the wordpress media uploader function that is in the default WP.
When I test the site on my localhost it uploads the files on to the wp-content/uploads folder. Then I use the media uploader in the WP admin area, the file uploads properly to the bucket as well.
Can someone please point me in the correct direction. If someone has uploaded media files from the frontend, and have a sample code I’d really appreciate.
Thank you for all the help in advance.
]]>I have installed wordpress on app engine, updated and activated the plug-ins and created the required cloud bucket.
When working offline everything works great. However when hosting on app-engine and I try to upload an image I get the following message:
Upload Error: File is empty. Please upload something more substantial. This error could also be caused by uploads being disabled in your php.ini or by post_max_size being defined as smaller than upload_max_filesize in php.ini.
Checked the files but I cannot see what the problem is? Do I have to upload files differently than when it is running offline? or the plugins take care to make the procedure the same?
Sorry i am not an expert and Thanks for your help.
]]>i cant upload files via buddypress plugin or any other plugin.
For example buddypress profile photo change feature doesnt work or BuddyPress
Activity Plus plugin gave an error like :
“Server error. upload directory isn’t writable. “
what was causing this problem ?
]]>Hi,
When activating the plugin, the default bucket name is : <app_id>.appspot.com
I created a new bucket and tried to set it. I get “Settings saved.” but the bucket name remains the default <app_id>.appspot.com.
What am I’m doing wrong?
I deactivated billing a few times before. So my site was inactive for some time. Now that I’ve booted it back up again, I am unable to upload photos – it says [Error: An error occurred in the upload. Please try again later. ]- well, I’ve checked the bucket and it shows up there (with a different file name – a really long string of nonsense like this lkeEFJj234dsfsdfFJSLDFdhd). I could see the photos in WordPress before and those uploads show up with the same file name as the file I uploaded from my computer in the Bucket.
So it uploads to the bucket, but wordpress can’t see it? Maybe because of the different filename? Or can this be an effect of me deactivating my site for a while? I can still see the uploads I made before when it was still working (in wordpress, they’re still in the media viewer thing).
The bat cache thing and the app engine plug in are both installed and activated (latest version).
I’ve tried creating a new bucket, no luck as well…
]]>I have an application that requires using media_sideload_image to sideload images from a URL and then attach the to a wordpress post. The function uses the temp location on the filesystem (by default /tmp or WP_TEMP_DIR) as a temporary download area for the file. This fails when running on appengine (since there is no local storage). Any ideas how i can make this work seamlessly using the appengine plugin. I have tried setting the WP_TEMP_DIR to “gs://<bucket>” but that does not work. I am able to manually upload files just fine so the plugin is setup correctly and bucket permissions are ok.
]]>I’ve successfully installed a basic WordPress blog on Google App Engine, using Google’s WP quickstart project for GAE, and their GAE WordPress plugin. I now need to install various other 3rd party wordpress plugins to the blog.
My question is can I expect any 3rd party WordPress plugins to work properly, given App Engine’s restrictions on local file writes (so needing to use Google Cloud Storage instead), and any other app engine restrictions (e.g. Mail usage, and any others?). i.e. does the GAE WordPress Plugin patch WordPress so that any random 3rd party plugin will automatically work properly?
If not, what can I expect to go wrong, and what can I do about it? (I know, a slightly general question, but looking for any tips or strategy for fixing from anyone with experience in this).
Worst case scenario: I have to manually patch any broken plugins to cope with no local file writing (etc), or ask the plugin developer to. Hopefully the situation is not this bad!?
(Note: I know that plugins have to be installed on WP on my dev SDK on my local machine, then the whole app redeployed, then the plugins activated on my live GAE WP site)
Many thanks, Alex
]]>