Call 'Get Videos' and 'Get Playlists' API's causes Runtime Error
This is regression it doesn't occur in 2.1.2.GA and 2.1.3.GA
Steps to reproduce:
1. Create a sample project
2. Copy files from Example folder (in module) to Resources folder (in the sample project)
3. Install Brightcove module (
https://wiki.appcelerator.org/display/tis/Using+Titanium+Modules)
4. Specify Brightcove.readToken in app.js and videos.js
5. Launch the app
6. Tap 'Get Videos' button
7. Tap 'Get Playlists' > 'Sample Playlist'
Actual results:
After step 6 or 7 Runtime Error occurs. Log:
10-10 15:42:27.818: E/TiExceptionHandler(5026): (main) [14647,14647] ----- Titanium Javascript Runtime Error -----
10-10 15:42:27.818: E/TiExceptionHandler(5026): (main) [1,14648] - In Resources/videos.js:2,18
10-10 15:42:27.818: E/TiExceptionHandler(5026): (main) [0,14648] - Message: Uncaught ReferenceError: require is not defined
10-10 15:42:27.818: E/TiExceptionHandler(5026): (main) [0,14648] - Source: var Brightcove = require('ti.brightcove');
10-10 15:42:27.818: E/V8Exception(5026): Exception occurred at Resources/videos.js:2: Uncaught ReferenceError: require is not defined
Expected results:
List of videos should appear.
Comments:
Sample project is attached. There is Brightcove.readToken in the project but if it is expired you have to use another one.
Still occurs. Tested on: Titanium Studio, build: 2.1.2.201208301612 Titanium SDK: 3.0.0.v20121017100120 Brightcove module ver.: 2.0.1 Device: Samsung Nexus S (4.1.1) New screenshot and logs are attached
Runtime Error occurs. Tested on: Titanium Studio, build: 2.1.2.201208301612 Titanium SDK: 3.1.0.v20121017135345 Brightcove module ver.: 2.0.1 Devices: LG VS910 4G(2.3.6) Samsung GalaxyS3 (4.0.4) New screenshot and logs are attached
For 3_0_X branch, this should as a part of this PR: https://github.com/appcelerator/titanium_mobile/pull/3321
Reopen to modify the label.
Closing ticket as fixed.