I spend a few hours writing a little script. Basically what it does is create a new text file and fills it up with whatever. I zip the text file --using zipfile-- and here's where my problem lies.
I want to run the Windows system command:
copy /b "imgFile.jpg" + "zipFile.zip" newImage.jpg
To merge the image "imgFile.jpg" and the zip "zipFile.zip".
So:
os.system("copy /b \"imgFile.jpg\" + \"zipFile.zip\" newImage.jpg")
When I run my script, it all seems to go fine. But when it's done and I try to extract the 'newImage.jpg' file, it gives me:
The archive is either in unknown format or damaged
This ONLY happens when I run the system command within the script. It works fine when I use the shell. It even works if I use a separate script.
I've double checked my zip file. Everything is in good shape. Is there something I'm doing wrong? Something I'm not seeing?