Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-27320

iOS: Ti.Stream.writeStream fires callback for each loop of writes, no way to tell when done


    • Type: Bug
    • Status: Open
    • Priority: Medium
    • Resolution: Unresolved
    • Affects Version/s: Release 8.2.0
    • Fix Version/s: None
    • Component/s: iOS
    • Labels:
    • Story Points:


      Ti.Stream.writeStream behaves differently on iOS vs Android. Android will do all of the writes and will fire the callback once at the end (or will fire it as soon as an error occurs).

      iOS will fire if an error occurs; or every iteration of it's internal read/write loop and at then at the end. But there's no way to know beforehand if it is done unless you know the exact byte count expected to be transferred. (The case I specifically saw was a Ti.File.FileStream and copying it's data)

      As a first step, adding a "done" property to the callback's argument object would be useful so you can tell when iOS is actually finished. A second step would be to eliminate the per-loop callback firing altogether for iOS.


          Issue Links



              • Assignee:
                amukherjee Abir Mukherjee
                cwilliams Christopher Williams
              • Watchers:
                1 Start watching this issue


                • Created:

                  Backbone Issue Sync

                  • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                    Git Integration