Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

File Transfer Can Crash Simulator

ANSWERED

I think I've found another situation in which the simulator behaves differently to hardware. When I try to do a File Transfer of an image, the simulator windows both disappear. No error messages are reported in studio.

 

After two days trying to work out what I was doing wrong (even though my code works fine on hardware), I tried to run the sample code in the File Transfer Guide. Same result. *phew*

 

I can provide a project that demonstrates this behaviour, although it's simply the code previously linked.

 

I couldn't work out exactly which line of code causes the problem, nor even whether it's the app or the companion. I suspect the app, and it may be a race condition or something to do with deferred processing since the visible code seems to execute completely before the crash.

 

I was about to try wrapping the image ArrayBuffer in CBOR until I noticed that the guide code doesn't do so.

 

Windows 7 x64, Firefox 56.0.2.

Peter McLennan
Gondwana Software
Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

The issue is fixed, thanks for reporting: we'll release a new version of the simulator by the end of the week.

View best answer in original post

Best Answer
9 REPLIES 9

Thanks for reporting this issue. I'm testing it right now. The default File Transfer project from Fitbit Studio doesn't make the simulator, but I'll try with the code from the documentation to see how it goes.

 

Are you on Windows ou Mac?

Best Answer
0 Votes

I'm not able to reproduce on Mac. I have the simulator version 0.5.2.

Best Answer
0 Votes

@SunsetRunnerI think you just answered your previous question. 😉 I'm on Windows 7.

 

I'll investigate the File Transfer project and see if I can spot the difference.

 

Thanks for looking into this!

Peter McLennan
Gondwana Software
Best Answer
0 Votes

I just tested the File Transfer Template project on Windows 7 simulator (Ionic and Versa). Same result: simulator disappeared without reporting an error.

Peter McLennan
Gondwana Software
Best Answer
0 Votes

This happens also on Win10, Simu 0.5.2.

Best Answer
0 Votes

@qooAppsThanks for confirming. I'm relieved that I wasn't doing something dense, although there was always a chance that my firewall/antivirus was interfering.

Peter McLennan
Gondwana Software
Best Answer
0 Votes

I was able to reproduce the problem on my Windows 10 VM just by using the file transfer project template. I'll check with the product team.

Best Answer
0 Votes

The issue is fixed, thanks for reporting: we'll release a new version of the simulator by the end of the week.

Best Answer

Thanks @SunsetRunner. Quick work! There's a Versa app in it for you. 😉

Peter McLennan
Gondwana Software
Best Answer