This repository was archived by the owner on Nov 28, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
This repository was archived by the owner on Nov 28, 2019. It is now read-only.
Importing attachments results in faulty file references #62
Copy link
Copy link
Open
Description
Hi, I have the following problem:
I'm trying to import attachments, but for some reason the imports aren't referenced correctly in the corresponding posts, or the directory in which they end up is incorrect. I'm getting this error:
WPOS3: File /app/web/app/uploads/Casper-van-Eijck-in-actie-0115-007.jpg does not exist.
WP Offload S3 is looking for the file, but can't find where it's supposed to be. Neither are they showing up correctly in wp-admin.
Example:
- wp:attachment_url in WXR file:
/wp-content/uploads/Casper-van-Eijck-in-actie-0115-007.jpg - directory it ends up in:
/app/uploads/2017/02/Casper-van-Eijck-in-actie-0115-007.jpg - new post_meta:
_w2m_origin_link: http://domain/en/2017/02/15/foo-post/casper-van-eijck-in-actie-0115-007-2/_w2m_origin_post_id: 65328_w2m_remote_guid: http://domain/wp-content/uploads/Casper-van-Eijck-in-actie-0115-007.jpg_wp_attached_file: Casper-van-Eijck-in-actie-0115-007.jpgwpml_media_processed: 1_wp_attachment_metadata(unserialized to YAML):
width: 2953
height: 1969
file: 2017/02/Casper-van-Eijck-in-actie-0115-007.jpg
sizes:
thumbnail: { file: Casper-van-Eijck-in-actie-0115-007-300x300.jpg, width: 300, height: 300, mime-type: image/jpeg }
medium: { file: Casper-van-Eijck-in-actie-0115-007-875x583.jpg, width: 875, height: 583, mime-type: image/jpeg }
medium_large: { file: Casper-van-Eijck-in-actie-0115-007-1280x853.jpg, width: 1280, height: 853, mime-type: image/jpeg }
large: { file: Casper-van-Eijck-in-actie-0115-007-1280x853.jpg, width: 1280, height: 853, mime-type: image/jpeg }
thumbnail_uncropped: { file: Casper-van-Eijck-in-actie-0115-007-300x200.jpg, width: 300, height: 200, mime-type: image/jpeg }
home_small: { file: Casper-van-Eijck-in-actie-0115-007-540x405.jpg, width: 540, height: 405, mime-type: image/jpeg }
home_large: { file: Casper-van-Eijck-in-actie-0115-007-1125x640.jpg, width: 1125, height: 640, mime-type: image/jpeg }
large_cropped: { file: Casper-van-Eijck-in-actie-0115-007-900x900.jpg, width: 900, height: 900, mime-type: image/jpeg }
article__header__xl: { file: Casper-van-Eijck-in-actie-0115-007-1600x900.jpg, width: 1600, height: 900, mime-type: image/jpeg }
article__header__l: { file: Casper-van-Eijck-in-actie-0115-007-1600x600.jpg, width: 1600, height: 600, mime-type: image/jpeg }
article__header__m: { file: Casper-van-Eijck-in-actie-0115-007-1600x400.jpg, width: 1600, height: 400, mime-type: image/jpeg }
share: { file: Casper-van-Eijck-in-actie-0115-007-1200x630.jpg, width: 1200, height: 630, mime-type: image/jpeg }
image_meta:
aperture: '0'
credit: 'Levien Willemse'
camera: ''
caption: ''
created_timestamp: '0'
copyright: "Rochussenstraat 315-b\n3023 DG Rotterdam Holland\n010-4779415 06-53 301015"
focal_length: '0'
iso: '0'
shutter_speed: '0'
title: ''
orientation: '0'
keywords: { }
It seems like _wp_attached_file (and the file keys in sizes?) is being set incorrectly.
Import log:
[2017-02-21 11:42:55] w2m-import.INFO: Attachment file downloaded (id: 22 {"file":"/app/web/app/uploads/2017/02/Casper-van-Eijck-in-actie-0115-007.jpg","url":"https://newdomain/app/uploads/2017/02/Casper-van-Eijck-in-actie-0115-007.jpg","type":"image/jpeg","error":false} []
[2017-02-21 11:42:55] w2m-import.INFO: Successfully imported post {"type":"attachment","origin_id":65328,"local_id":22} []
[2017-02-21 11:42:55] w2m-import.NOTICE: Cannot find remote post for locale en_US {"origin_id":65328,"locale":"en_US","element_id":22} []
[2017-02-21 11:42:55] w2m-import.WARNING: Missing attribute 'date' in XML post node {"action":"w2m_import_parse_post_error"} []
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels