{ "id": "152346", "key": "TIMOB-20140", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "17706", "name": "Release 5.4.0", "archived": false, "released": true, "releaseDate": "2016-08-11" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2015-12-17T22:09:10.000+0000", "created": "2015-10-26T16:15:59.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "android", "supportTeam" ], "versions": [], "issuelinks": [ { "id": "50294", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "154315", "key": "TIMOB-20234", "fields": { "summary": "Streaming Audio not working on Android Marshmallow with Alloy", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Medium", "id": "3" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "updated": "2016-07-15T00:58:53.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "I'm having an issue with audio streaming on any Android device running the newest Android version (Marshmallow).\r\n\r\nI'm using the following code to play the audio stream (works on iOS, and android prior to Marshmallow);\r\n\r\n*Test case*\r\n{code:javascript}\r\nAudioPlayer = Ti.Media.createAudioPlayer({ allowBackground: true });\r\nAudioPlayer.setUrl( 'http://icecast.omroep.nl/3fm-bb-mp3' );\r\nAudioPlayer.start();\r\n{code}\r\n\r\n*Expected Result*\r\nStream starts playing\r\n\r\n*Actual Result*\r\nStream doesn't start playing, instead i'm getting an error saying “unknown media error”.\r\n\r\n---\r\n\r\nLike I said, this was working on both iOS and Android (prior to Marshmallow).\r\n\r\nDoes anyone know a workaround or a fix for this?\r\nAny help is appreciated!", "attachment": [], "flagged": false, "summary": "Streaming Audio not working on Android Marshmallow", "creator": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "_Original:_\r\n* Titanium 3.5.1. GA\r\n* Android 6 (Marshmallow)\r\n\r\n_Updated:_\r\n* Titanium 5.0.1.GA", "closedSprints": [ { "id": 536, "state": "closed", "name": "2015 Sprint 25 SDK", "startDate": "2015-12-05T01:30:40.415Z", "endDate": "2015-12-19T01:30:00.000Z", "completeDate": "2015-12-29T03:19:42.127Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "367983", "author": { "name": "mrahman", "key": "mrahman", "displayName": "Mostafizur Rahman", "active": true, "timeZone": "Asia/Dhaka" }, "body": "Hello\r\n\r\nWe tested this issue in our environment. Streaming audio is working properly.\r\n\r\n*Testing Environment:*\r\nAppc CLI - version 5.0.4-2\r\nAppc Studio - 4.3.1\r\nMac OSx - 10.9.5\r\nNode.js - 0.10.33\r\nnpm - 1.4.28\r\nTi SDK - 5.0.2 GA\r\nAndroid Emulator - Google Nexus 6p - 6.0.0\r\n\r\napp.js\r\n{code}\r\nvar win = Titanium.UI.createWindow({\r\ntitle:'Audio Test',\r\nbackgroundColor:'#fff',\r\nlayout: 'vertical'\r\n});\r\n\r\nvar startStopButton = Titanium.UI.createButton({\r\ntitle:'Start/Stop Streaming',\r\ntop:10,\r\nwidth:200,\r\nheight:40\r\n});\r\n\r\nvar pauseResumeButton = Titanium.UI.createButton({\r\ntitle:'Pause/Resume Streaming',\r\ntop:10,\r\nwidth:200,\r\nheight:40,\r\nenabled:false\r\n});\r\n\r\nwin.add(startStopButton);\r\nwin.add(pauseResumeButton);\r\n\r\n// allowBackground: true on Android allows the\r\n// player to keep playing when the app is in the\r\n// background.\r\nvar audioPlayer = Ti.Media.createAudioPlayer({\r\nurl: 'http://icecast.omroep.nl/3fm-bb-mp3',\r\nallowBackground: true\r\n});\r\n\r\nstartStopButton.addEventListener('click',function() {\r\n// When paused, playing returns false.\r\n// If both are false, playback is stopped.\r\nif (audioPlayer.playing || audioPlayer.paused)\r\n{\r\naudioPlayer.stop();\r\npauseResumeButton.enabled = false;\r\nif (Ti.Platform.name === 'android')\r\n{\r\naudioPlayer.release();\r\n}\r\n}\r\nelse\r\n{\r\naudioPlayer.start();\r\npauseResumeButton.enabled = true;\r\n}\r\n});\r\n\r\npauseResumeButton.addEventListener('click', function() {\r\nif (audioPlayer.paused) {\r\naudioPlayer.start();\r\n}\r\nelse {\r\naudioPlayer.pause();\r\n}\r\n});\r\n\r\naudioPlayer.addEventListener('progress',function(e) {\r\nTi.API.info('Time Played: ' + Math.round(e.progress) + ' milliseconds');\r\n});\r\n\r\naudioPlayer.addEventListener('change',function(e)\r\n{\r\nTi.API.info('State: ' + e.description + ' (' + e.state + ')');\r\n});\r\n\r\nwin.addEventListener('close',function() {\r\naudioPlayer.stop();\r\nif (Ti.Platform.osname === 'android')\r\n{\r\naudioPlayer.release();\r\n}\r\n});\r\n\r\nwin.open();\r\n{code}\r\n\r\nThanks.", "updateAuthor": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-10-27T12:01:28.000+0000", "updated": "2015-10-28T01:23:46.000+0000" }, { "id": "368108", "author": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Hi,\r\n\r\nThanks for the quick response! I have tested the above code on a few Android devices and it still doesn't seem to work.\r\n\r\n*Testing Environment:*\r\nAppc CLI - Version 4.1.2\r\nMac OSx - 10.10.5\r\nNode.js - v0.10.37\r\nnpm - 1.4.28\r\nTi SDK - 5.0.1.GA\r\n\r\n*Devices:*\r\nSony Xperia Z3 - Android 4.4.4 (Works)\r\nSamsung Galaxy S4 - Android 5.0.1 (Works)\r\nSamsung Galaxy S6 Edge - Android 5.1.1 (Works)\r\n*LG Nexus 5 - Android 6.0 Marshmallow (Does not work)*\r\n\r\nBelow is the logcat output that I get when trying to play the stream on the LG Nexus 5 with Android 6.0. So this issue only persists on Android 6.0 and not on prior releases.\r\n\r\n{code:bash}\r\n10-28 10:29:26.439 199 787 D audio_hw_primary: out_set_parameters: enter: usecase(1: low-latency-playback) kvpairs: routing=2\r\n10-28 10:29:26.450 199 786 D audio_hw_primary: select_devices: out_snd_device(2: speaker) in_snd_device(0: none)\r\n10-28 10:29:26.450 199 786 D msm8974_platform: platform_send_audio_calibration: sending audio calibration for snd_device(2) acdb_id(15)\r\n10-28 10:29:26.450 199 786 D audio_hw_primary: enable_snd_device: snd_device(2: speaker)\r\n10-28 10:29:26.454 199 786 D audio_hw_primary: enable_audio_route: apply and update mixer path: low-latency-playback\r\n10-28 10:29:26.466 28963 28990 I TiAPI : State: starting (4)\r\n10-28 10:29:26.871 199 29045 E NuCachedSource2: source returned error -1, 10 retries left\r\n10-28 10:29:29.681 199 787 D audio_hw_primary: disable_audio_route: reset and update mixer path: low-latency-playback\r\n10-28 10:29:29.682 199 787 D audio_hw_primary: disable_snd_device: snd_device(2: speaker)\r\n10-28 10:29:30.067 199 29045 E NuCachedSource2: source returned error -1, 9 retries left\r\n10-28 10:29:31.705 796 3645 D NetlinkSocketObserver: NeighborEvent{elapsedMs=160692055, 192.168.1.1, [001DAAC25F80], RTM_NEWNEIGH, NUD_REACHABLE}\r\n10-28 10:29:33.188 199 29045 E NuCachedSource2: source returned error -1, 8 retries left\r\n10-28 10:29:36.305 199 29045 E NuCachedSource2: source returned error -1, 7 retries left\r\n10-28 10:29:39.485 199 29045 E NuCachedSource2: source returned error -1, 6 retries left\r\n10-28 10:29:42.619 199 29045 E NuCachedSource2: source returned error -1, 5 retries left\r\n10-28 10:29:45.768 199 29045 E NuCachedSource2: source returned error -1, 4 retries left\r\n10-28 10:29:46.312 199 787 D audio_hw_primary: out_set_parameters: enter: usecase(1: low-latency-playback) kvpairs: routing=2\r\n10-28 10:29:46.315 28963 28990 I TiAPI : State: playing (3)\r\n10-28 10:29:46.324 199 786 D audio_hw_primary: select_devices: out_snd_device(2: speaker) in_snd_device(0: none)\r\n10-28 10:29:46.324 199 786 D msm8974_platform: platform_send_audio_calibration: sending audio calibration for snd_device(2) acdb_id(15)\r\n10-28 10:29:46.324 199 786 D audio_hw_primary: enable_snd_device: snd_device(2: speaker)\r\n10-28 10:29:46.329 199 786 D audio_hw_primary: enable_audio_route: apply and update mixer path: low-latency-playback\r\n10-28 10:29:48.891 199 29045 E NuCachedSource2: source returned error -1, 3 retries left\r\n10-28 10:29:49.537 199 787 D audio_hw_primary: disable_audio_route: reset and update mixer path: low-latency-playback\r\n10-28 10:29:49.537 199 787 D audio_hw_primary: disable_snd_device: snd_device(2: speaker)\r\n10-28 10:29:52.019 199 29045 E NuCachedSource2: source returned error -1, 2 retries left\r\n10-28 10:29:54.647 28963 29072 I APSAnalyticsService: Analytics Service Started\r\n10-28 10:29:54.726 28963 29072 I APSAnalyticsService: Stopping Analytics Service\r\n10-28 10:29:55.096 199 29045 E NuCachedSource2: source returned error -1, 1 retries left\r\n10-28 10:29:58.217 199 29045 E NuCachedSource2: source returned error -1, 0 retries left\r\n10-28 10:29:58.327 199 29039 E GenericSource: Failed to init from data source!\r\n10-28 10:29:58.329 199 29038 D NuPlayerDriver: notifyListener_l(0xb3678900), (100, 1, -2147483648)\r\n10-28 10:29:58.330 28963 29040 E MediaPlayer: error (1, -2147483648)\r\n10-28 10:29:58.330 28963 28990 E MediaPlayer: Error (1,-2147483648)\r\n10-28 10:29:58.331 199 1338 D NuPlayerDriver: reset(0xb3678900)\r\n10-28 10:29:58.331 199 1338 D NuPlayerDriver: notifyListener_l(0xb3678900), (8, 0, 0)\r\n10-28 10:29:58.331 199 29038 D NuPlayerDriver: notifyResetComplete(0xb3678900)\r\n10-28 10:30:00.219 796 3072 I AccountManagerService: getTypesVisibleToCaller: isPermitted? true\r\n10-28 10:30:00.237 7976 29086 I EventLogService: Opted in for usage reporting\r\n10-28 10:30:00.242 7976 29086 I EventLogService: Aggregate from 1446024316135 (log), 1446022800106 (data)\r\n10-28 10:30:00.392 7976 29086 I ServiceDumpSys: dumping service [account]\r\n10-28 10:30:01.017 796 809 I ActivityManager: Start proc 29096:com.google.android.deskclock/u0a69 for broadcast com.google.android.deskclock/com.android.alarmclock.DigitalAppWidgetProvider\r\n10-28 10:30:01.043 29096 29096 W System : ClassLoader referenced unknown path: /data/app/com.google.android.deskclock-1/lib/arm\r\n10-28 10:30:01.064 29096 29096 I GAv4 : Google Analytics 7.8.95 is starting up. To enable debug logging on a device run:\r\n10-28 10:30:01.064 29096 29096 I GAv4 : adb shell setprop log.tag.GAv4 DEBUG\r\n10-28 10:30:01.064 29096 29096 I GAv4 : adb logcat -s GAv4\r\n10-28 10:30:01.076 29096 29096 W GAv4 : AnalyticsReceiver is not registered or is disabled. Register the receiver for reliable dispatching on non-Google Play devices. See http://goo.gl/8Rd3yj for instructions.\r\n10-28 10:30:01.081 29096 29096 W GAv4 : CampaignTrackingReceiver is not registered, not exported or is disabled. Installation campaign tracking is not possible. See http://goo.gl/8Rd3yj for instructions.\r\n10-28 10:30:01.088 29096 29118 W GAv4 : AnalyticsService not registered in the app manifest. Hits might not be delivered reliably. See http://goo.gl/8Rd3yj for instructions.\r\n{code}\r\n\r\nCould you try this on an actual device with Android 6.0 and see if you can reproduce this issue?\r\n\r\nAlso i'm using Titanium SDK 3.5.1.GA in the live version of the apps where I use streaming music, and this issue also occurs.\r\nAnd just for my information, is it still possible to build apps for the Playstore and Appstore with the newest Titanium release (5.0.2.GA) for free? Or do you now need a subscription (Indie, Team or Enterprise) to use the newer versions of Titanium?", "updateAuthor": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-10-28T10:19:23.000+0000", "updated": "2015-10-28T10:20:38.000+0000" }, { "id": "369522", "author": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "body": "I can confirm that I am getting reports from users of my radio streaming apps on Google Play that they no longer play after the user has installed Android 6.0.\r\n\r\nI also installed Android 6.0 on my Nexus 7 last night and found this to be the case. I then re-built an app using the Android 6.0 SDK (was previously build targeting Android 5.0) but found it still won't play. The error thrown is Player error: Unknown media error. code is -2147483648\r\n\r\nAnd I've just downloaded a Genymotion Nexus 5X with Android 6.0 and found it also won't play audio streams using the Appcelerator AudioPlayer API (mp3 streams from a streaming server).", "updateAuthor": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "created": "2015-11-10T07:26:33.000+0000", "updated": "2015-11-10T07:26:33.000+0000" }, { "id": "369746", "author": { "name": "Paky50", "key": "paky50", "displayName": "Pasquale", "active": true, "timeZone": "Europe/Rome" }, "body": "Hi to all,\r\nYesterday my Nexus 7 2015 updated to Android 6.0 Marshmallow and my radio streaming dont work.\r\nI tried by Genymotion Nexus 5X but same result.\r\nNo console errors and no sound. \r\n\r\nSome news?\r\n\r\nThanks", "updateAuthor": { "name": "Paky50", "key": "paky50", "displayName": "Pasquale", "active": true, "timeZone": "Europe/Rome" }, "created": "2015-11-11T15:22:49.000+0000", "updated": "2015-11-11T17:31:37.000+0000" }, { "id": "370412", "author": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "body": "Thanks for opening this again. If you want a URL to test try http://sc6.radiocaroline.net:8040\r\nI have also tried adding /;.mp3 on the end as some devices (Galaxy models) won't recognise this as a stream without it. Both produce Unknown media error -2147483648\r\n\r\nI don't suppose this is a revival of the 'OKHTTP' bug from Android 5.0?\r\n\r\n", "updateAuthor": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "created": "2015-11-16T18:24:17.000+0000", "updated": "2015-11-17T10:43:44.000+0000" }, { "id": "372613", "author": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Has there been any update regarding this issue? A fix or maybe a workaround?", "updateAuthor": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-12-10T10:18:20.000+0000", "updated": "2015-12-10T10:18:20.000+0000" }, { "id": "372847", "author": { "name": "stalimk", "key": "stalimk", "displayName": "Stali Matos", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I have the same problem... Marshmallow dont play audio streaming Icecast / shoutcas mp3.", "updateAuthor": { "name": "stalimk", "key": "stalimk", "displayName": "Stali Matos", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-12-14T16:52:51.000+0000", "updated": "2015-12-14T16:52:51.000+0000" }, { "id": "373190", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "PR: https://github.com/appcelerator/titanium_mobile/pull/7591", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-12-17T08:51:07.000+0000", "updated": "2015-12-17T08:51:07.000+0000" }, { "id": "373273", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "PR merged.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-12-18T06:55:10.000+0000", "updated": "2015-12-18T06:55:10.000+0000" }, { "id": "373274", "author": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "body": "Thanks Ashram - what was the actual problem then? And do you know when the fix will make it's way into the Ti SDK?", "updateAuthor": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "created": "2015-12-18T07:04:17.000+0000", "updated": "2015-12-18T07:04:17.000+0000" }, { "id": "373369", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "This is planned for fix release in SDK 6.0.0.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-12-22T05:42:59.000+0000", "updated": "2015-12-22T05:42:59.000+0000" }, { "id": "374174", "author": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Thanks Ashram!\r\nIs it possible to fix this in one of the current builds? 5.2 or maybe a 5.3?", "updateAuthor": { "name": "WVersluijs", "key": "wversluijs", "displayName": "Wouter Versluijs", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-01-11T14:50:55.000+0000", "updated": "2016-01-11T14:50:55.000+0000" }, { "id": "374239", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "If you need the latest and greatest right from the oven, you could try the master branch (which is currently set at 6.0.0) http://builds.appcelerator.com.s3.amazonaws.com/index.html#master from the builds. These are not GA or even RC, so be careful with this. These are continuous builds. I quote *`Below are the latest untested continuous integrations builds of the Titanium SDK. `*\r\n\r\nAlternatively, you could compile it yourself from github and take only the changes you need in to a 5.2.X branch.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2016-01-12T01:42:06.000+0000", "updated": "2016-01-12T01:42:06.000+0000" }, { "id": "374332", "author": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "body": "I did try a nightly build about a week ago and again today and found that although some of my Shoutcast streams now played under Android 6.0 (on a Nexus 7), others did not and produced our old friend error (1, -2147483648)\r\n\r\n*Examples:*\r\nWon't play: http://sc2.radiocaroline.net:10558\r\nWill play: http://sc2.radiocaroline.net:8000\r\n\r\nThe error starts at: E/NuCachedSource2(16101): source returned error -1, 10 retries left\r\n\r\nIn a further test using 'Classic' Ti the stream that would not play in an Alloy build now plays and we see the following printed in the Console, which I have never seen in an Alloy implementation:\r\n\r\nAAS: Asking for stream handler for protocol: 'http'\r\n\r\nAudio in Android seems to be a bit of a lottery - if it works great. If it does't we're stuffed as nobody seems to be able to say what the cause is!", "updateAuthor": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "created": "2016-01-12T20:47:10.000+0000", "updated": "2016-01-12T20:49:03.000+0000" }, { "id": "374372", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "[~patrickmounteney] Thanks for checking this out.\r\n\r\n{quote}In a further test using 'Classic' Ti the stream that would not play in an Alloy build now plays and we see the following printed in the Console, which I have never seen in an Alloy implementation:{quote}\r\n\r\nSo basically this is a good thing? Just that there is a weird log entry.\r\n\r\nWill need to investigate\r\n{quote}Won't play: http://sc2.radiocaroline.net:10558\r\nWill play: http://sc2.radiocaroline.net:8000{quote}", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2016-01-13T03:04:54.000+0000", "updated": "2016-01-13T03:04:54.000+0000" }, { "id": "374373", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "Do you know if there is any difference between the 2 Shoutcast? (Slight protocol differences? etc...)", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2016-01-13T03:07:27.000+0000", "updated": "2016-01-13T03:07:27.000+0000" }, { "id": "374393", "author": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "body": "As far as I can tell both of the above Shoutcast streams are the same protocol as they come from the same server (Shoutcast 1.9.8), be it different ports. But read on as I spent some time testing this yesterday and my conclusion is that there is some difference between the way the 'Classic Ti' implements AudioPlayer behind the scenes and the way Alloy does. I can run the same very simple test (below) and get two different results, depending on if it was built with Alloy or not and version of Android the test is run under.\r\n\r\n*Test code built with Ti. SDK 6.0.0.v20160112093414 and targeting Android API 23*\r\n\r\n\r\nvar player = Titanium.Media.createAudioPlayer({\r\nallowBackground: true,\r\nurl: \"http://sc2.radiocaroline.net:10558\"\r\n});\r\n\r\n\r\nfunction streamButtonClick(){\r\nTi.API.info(\"Playing : \"+ player.url);\r\nplayer.play();\r\n}\r\n\r\n\r\n*Test 1:*\r\n\r\nAlloy build - run on Nexus 7 Tablet Android 6.0.1 - It doesn't play and throws error (1, -2147483648)\r\nClassic build - run on Nexus 7 Tablet Android 6.0.1 - streams plays\r\n\r\n*Test 2:*\r\n\r\nAlloy build - run on Lenovo Tablet Android 4.2.2 - streams plays\r\nClassic build - run on Lenovo Tablet Android 4.2.2 - streams plays\r\n\r\nObservations: When it works we see this printed in the Ti Console:\r\n[DEBUG] : AAS: Asking for stream handler for protocol: 'http'\r\n[DEBUG] : MediaPlayer: setSubtitleAnchor in MediaPlayer\r\n\r\nWhen it doesn’t work we get:\r\n[ERROR] : MediaPlayer: error (1, -2147483648)\r\n\r\nAnd when it does work, in the Android log we see:\r\n01-12 07:48:55.722: D/audio_hw_primary(16101): enable_audio_route: apply and update mixer path: low-latency-playback\r\n01-12 07:48:55.988: E/NuCachedSource2(16101): source returned error -1, 10 retries left\r\n\r\nConclusion: There is something in an Alloy build, when run under Android 6.0, that is causing NuCachedSource2 to error and the stream never plays.", "updateAuthor": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "created": "2016-01-13T09:35:02.000+0000", "updated": "2016-01-13T10:53:34.000+0000" }, { "id": "374495", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "[~patrickmounteney] Created this ticket TIMOB-20234 to address this.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2016-01-14T02:24:33.000+0000", "updated": "2016-01-14T02:24:33.000+0000" }, { "id": "376210", "author": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "updateAuthor": { "name": "patrickmounteney", "key": "patrickmounteney", "displayName": "Patrick Mounteney", "active": true, "timeZone": "Europe/London" }, "created": "2016-02-08T07:32:21.000+0000", "updated": "2016-02-08T07:32:21.000+0000" }, { "id": "390756", "author": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "updateAuthor": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-07-15T00:58:29.000+0000", "updated": "2016-07-15T00:58:46.000+0000" } ], "maxResults": 22, "total": 22, "startAt": 0 } } }