ybenaziz
Forum Replies Created
-
Hi Everybody,
Any news about the issue ?
Thank you
@ianmjones @rodlathamcaci It’s the same error that you have :
Debug log error:
AS3CF: Error removing local file C:\FilePath/file.jpg.This is the part of code that throw this error ( classes/amazon-s3-and-cloudfront.php , Function : “remove_local_files”) :
if ( ! @unlink( $path ) ) { $message = 'Error removing local file '; if ( ! file_exists( $path ) ) { $message = "Error removing local file. Couldn't find the file at "; } else if ( ! is_writable( $path ) ) { $message = 'Error removing local file. Ownership or permissions are mis-configured for '; } AS3CF_Error::log( $message . $path ); }
The @ with the unlink function prevent throwing the exact error. when we remove the @ we got this :
Adding Image directly in Post :
[2019-03-29 09:09:01] local.ERROR: unlink(C:\laragon\www\backstage\project\htdocs\content/uploads/sites/3/ccc-rr.jpg): Resource temporarily unavailable {"exception":"[object] (ErrorException(code: 0): unlink(C:\\laragon\\www\\backstage\\project\\htdocs\\content/uploads/sites/3/ccc-rr.jpg): Resource temporarily unavailable at C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php:1389) [stacktrace] #0 [internal function]: Themosis\\Core\\Bootstrap\\ExceptionHandler->handleError(2, 'unlink(C:\\\\larag...', 'C:\\\\laragon\\\\www\\\\...', 1389, Array) #1 C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php(1389): unlink('C:\\\\laragon\\\\www\\\\...') #2 C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php(1249): Amazon_S3_And_CloudFront->remove_local_files(Array, 303) #3 C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php(1040): Amazon_S3_And_CloudFront->upload_attachment(303, Array) #4 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-includes\\class-wp-hook.php(286): Amazon_S3_And_CloudFront->wp_update_attachment_metadata(Array, 303) #5 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-includes\\plugin.php(208): WP_Hook->apply_filters(Array, Array) #6 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-includes\\post.php(5581): apply_filters('wp_update_attac...', Array, 303) #7 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-admin\\includes\\media.php(401): wp_update_attachment_metadata(303, Array) #8 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-admin\\includes\\ajax-actions.php(2357): media_handle_upload('async-upload', '302', Array) #9 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-admin\\async-upload.php(33): wp_ajax_upload_attachment() #10 {main} "}
Adding Image in Library :
[2019-03-29 09:12:47] local.ERROR: unlink(C:\laragon\www\backstage\project\htdocs\content/uploads/sites/3/ccc-rr.jpg): Resource temporarily unavailable {"exception":"[object] (ErrorException(code: 0): unlink(C:\\laragon\\www\\backstage\\project\\htdocs\\content/uploads/sites/3/ccc-rr.jpg): Resource temporarily unavailable at C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php:1389) [stacktrace] #0 [internal function]: Themosis\\Core\\Bootstrap\\ExceptionHandler->handleError(2, 'unlink(C:\\\\larag...', 'C:\\\\laragon\\\\www\\\\...', 1389, Array) #1 C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php(1389): unlink('C:\\\\laragon\\\\www\\\\...') #2 C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php(1249): Amazon_S3_And_CloudFront->remove_local_files(Array, 304) #3 C:\\laragon\\www\\backstage\\project\\htdocs\\content\\plugins\\amazon-s3-and-cloudfront\\classes\\amazon-s3-and-cloudfront.php(1040): Amazon_S3_And_CloudFront->upload_attachment(304, Array) #4 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-includes\\class-wp-hook.php(286): Amazon_S3_And_CloudFront->wp_update_attachment_metadata(Array, 304) #5 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-includes\\plugin.php(208): WP_Hook->apply_filters(Array, Array) #6 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-includes\\post.php(5581): apply_filters('wp_update_attac...', Array, 304) #7 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-admin\\includes\\media.php(401): wp_update_attachment_metadata(304, Array) #8 C:\\laragon\\www\\backstage\\project\\htdocs\\cms\\wp-admin\\async-upload.php(91): media_handle_upload('async-upload', 0) #9 {main} "}
Hi everybody,
If anyone knows if there is a previous version where we haven’t this bug.
I have the same problem, the file are not removed from local. when I debug , unlink function failed because the path is still used by another process ( I think the upload to s3 server process) so this is why unlink throw the error “Resource temporarily unavailable”.