Device-Type-Library-Import
Device-Type-Library-Import copied to clipboard
Uploading of front/rear images for device types fails
The front_image and rear_image attributes require special handling for uploading images into Django. Since the script doesn't use multipart/form data, the import of any device type that specifies these attributes fails with
{"front_image":["The submitted data was not a file. Check the encoding type on the form."],"rear_image":["The submitted data was not a file. Check the encoding type on the form."]}
Hello @jbemmel, as mentioned in the PR, v2.0.0 was released today. Thus, you will need to reevaluate how your PR is written and what files have been modified. I would be glad to assist if needed.
Please also refer to this PR in the devicetype-library as well as this issue thread.
In the coming days I will also be working on a new release for this script to accommodate these changes. Feel free to pitch in if you would like
Working on a draft here: https://github.com/jbemmel/Device-Type-Library-Import/tree/fix_image_upload_v2
Need to move the images to the new location, will update after you push that
Awesome, once the PR is fixed I'll merge the images for you