Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-15837] Android: platform-specific Resources folder not working for commonjs modules

GitHub Issuen/a
TypeBug
PriorityCritical
StatusClosed
ResolutionFixed
Resolution Date2013-11-28T06:58:37.000+0000
Affected Version/sRelease 3.2.0
Fix Version/s2013 Sprint 24, 2013 Sprint 24 Core, Release 3.2.0, Release 3.3.0
ComponentsAndroid
Labelsmodule_android, qe-3.2.0, qe-closed-3.2.0, qe-testadded
ReporterShreya Chowbey
AssigneeChris Barber
Created2013-11-27T10:10:47.000+0000
Updated2014-03-07T01:03:06.000+0000

Description

Steps Followed: 1. Create an alloy project. 2. launch the project on android emulator. Actual Result: It fails and gives an 'Alloy module not found' as an uncaught exception. Please refer the attached console log file and screen shot for more clarification.

Attachments

FileDateSize
alloy_module missing.png2013-11-27T10:10:47.000+0000225029
alloy module missing.txt2013-11-27T10:10:47.000+000021762

Comments

  1. Federico Casali 2013-11-27

    Was able to reproduce. Windows 8 TiSDK 3.2.0.v20131126144841 Alloy 1.3.0-beta CLI 3.2.0-beta Titanium Studio 3.2.0.201311262027 1. Create a new default project in Titanium Studio and run on the emulator from Titanium Studio (Android version tested 2.3.3) 2. Once run, the described issue is shown. 3. Checking into the Resources folder, I see the 'alloy.js' file in the Resources/android/ folder. The same behavior is also reproducible if creating and building a new Alloy project from CLI.
  2. Tony Lukasavage 2013-11-27

    Can someone please attempt the equivalent issue with a traditional Titanium app so we can determine if this is even an Alloy issue, or if it just happens to occur in an alloy app since alloy uses platform-specific folders. This is untested, but give something like this a shot.

    app.js

       require('alloy').sayHi();
       

    android/alloy.js

       exports.sayHi = function() { alert('hi'); };
       
  3. Federico Casali 2013-11-27

    I can reproduce the issue also with a classic project following Tony's latest comment. So, it seems related to platform-specific folders usage.
  4. Chris Barber 2013-11-28

    Master pull request: https://github.com/appcelerator/titanium_mobile/pull/5044 3_2_X pull request: https://github.com/appcelerator/titanium_mobile/pull/5045
  5. Shreya Chowbey 2013-11-28

    Verified this issue as fixed on, Mac 10.9 Appcelerator Studio, build: 3.2.0.201311261642 mobilesdk-3.2.0.v20131127194046-osx alloy-1.0.3-beta But verification on Windows OS was blocked by TISTUD-5815 Windows: Android configuration fails
  6. Samuel Dowse 2013-12-03

    Verified fixed on: Windows 8.1 Titanium Studio, build: 3.2.0.201311262027 Titanium SDK, build: 3.2.0.v20131127194046 CLI: 3.2.0-beta Alloy: 1.3.0-beta Created an alloy project and a classic project built and installed to Android emulator and device. Used code from description and code from comments. Both successfully launched. Closing.

JSON Source