Well, I’m not familiar with the plugin, but what sort of variables or data did you insert into the function? That error message is stating that you tried to insert a table even though the input should have been a string.
I follow the documentation to replace bucket_name:“TestBuket”, and object_key is like this: “Test/TestMusic.mp3”
And dest_path is like this: “s3://TestBuket/Test/TestMusic.mp3”.
I gave a .txt and .mp3 respectively to try, both have problems, and txt is downloaded in less than 1 second, mp3 is 6 seconds, which should indicate that it has received the object correctly?
But it is a mistake when it reaches 100%.
I tried to empty the onDownload function, but the problem remains.
local function onGetObject( evt ) if evt.error then print(evt.error, evt.message, evt.status) else if evt.progress then print(evt.progress) else print("object download complete") end end end
If not, give it a go.
If you did, then also I presume that you using “s3:getObject(bucket_name, object_key, base_dir, dest_path, listener)”? In this case, probably the reason why you are seeing this error is because of your dest_path, i.e. “s3://TestBuket/Test/TestMusic.mp3”. It tries to save the file to a location it cannot access and therefore it fails at that point.
We are talking about a Corona project, so the system.DocumentsDirectory is pointing to a the simulator’s sandbox (if you are on simulator) or the project’s Documents folder. Try changing the dest_path to “testMusic.mp3” and then open your project’s sandbox and look inside the documents folder to see if it is there.
Errors are rarely safe to ignore, but without having access to your project and/or a deeper knowledge of the plugin and its workings, I can’t really help you weed out that problem with just this information.
You can try debugging it yourself or contact the plugin’s developer for help.