{ "id": "175432", "key": "TIMOB-28081", "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": "21052", "description": "", "name": "Release 9.3.0", "archived": false, "released": true, "releaseDate": "2020-12-14" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2020-11-20T15:43:06.000+0000", "created": "2020-08-12T01:07:06.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "android", "build", "gradle", "library" ], "versions": [], "issuelinks": [], "assignee": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2020-11-20T15:43:06.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": "*Summary:*\r\nIf an app includes an Apache \"commons-logging\" library via gradle (or a module that references it via gradle), then it will fail to build.\r\n\r\n*Steps to reproduce:*\r\n# Create a \"Classic\" Titanium app project.\r\n# Add the below \"build.gradle\" file to project folder: {{./platform/android}}\r\n# Build for Android.\r\n\r\n./platform/android/build.gradle\r\n{code:groovy}\r\ndependencies {\r\n\timplementation 'commons-logging:commons-logging:1.1.3'\r\n}\r\n{code}\r\n\r\n*Result:*\r\nThe following build failure will occur...\r\n{code}\r\n[ERROR] [GRADLE] \r\n[ERROR] [GRADLE] FAILURE: Build failed with an exception.\r\n[ERROR] [GRADLE] \r\n[ERROR] [GRADLE] * What went wrong:\r\n[ERROR] [GRADLE] Execution failed for task ':app:checkDebugDuplicateClasses'.\r\n[ERROR] [GRADLE] > 1 exception was raised by workers:\r\n[ERROR] [GRADLE] java.lang.RuntimeException: Duplicate class org.apache.commons.logging.Log found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogConfigurationException found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory$1 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory$2 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory$3 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory$4 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory$5 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogFactory$6 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.LogSource found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.AvalonLogger found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.Jdk13LumberjackLogger found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.Jdk14Logger found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.Log4JLogger found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.LogFactoryImpl found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.LogFactoryImpl$1 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.LogFactoryImpl$2 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.LogFactoryImpl$3 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.LogKitLogger found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.NoOpLog found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.ServletContextCleaner found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.SimpleLog found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.SimpleLog$1 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.WeakHashtable found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.WeakHashtable$1 found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.WeakHashtable$Entry found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.WeakHashtable$Referenced found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] Duplicate class org.apache.commons.logging.impl.WeakHashtable$WeakKey found in modules jetified-commons-logging-1.1.3.jar (commons-logging:commons-logging:1.1.3) and jetified-titanium-9.2.0-runtime.jar (org.appcelerator:titanium:9.2.0)\r\n[ERROR] [GRADLE] \r\n[ERROR] [GRADLE] Go to the documentation to learn how to Fix dependency resolution errors.\r\n{code}\r\n\r\n*Cause:*\r\nTitanium is including its own copy of the {{commons-logging-1.1.1.jar}} as shown below.\r\nhttps://github.com/appcelerator/titanium_mobile/tree/master/android/titanium/lib\r\n\r\n*Solution:*\r\nWe should be referencing this library via gradle instead. This will allow gradle's dependency management resolve this for us.\r\nOr we can remove our usage of this JAR.\r\n", "attachment": [], "flagged": false, "summary": "Android: App build fails if it includes an Apache \"commons-logging\" library", "creator": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "closedSprints": [ { "id": 1206, "state": "closed", "name": "2020 Sprint 19", "startDate": "2020-09-14T20:01:00.000Z", "endDate": "2020-09-25T20:01:00.000Z", "completeDate": "2020-09-28T15:30:19.875Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "456618", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "PR (9.3.x): https://github.com/appcelerator/titanium_mobile/pull/11970", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-08-27T02:48:48.000+0000", "updated": "2020-08-27T02:48:48.000+0000" }, { "id": "457050", "author": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "body": "FR Passed, Waiting on Jenkins build.", "updateAuthor": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-09-28T14:25:50.000+0000", "updated": "2020-09-28T14:25:50.000+0000" }, { "id": "457659", "author": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "body": "*Closing ticket*. Fix verified in SDK version {{9.3.0.v20201119063936}}.\r\n\r\nTest and other information can be found at:\r\nhttps://github.com/appcelerator/titanium_mobile/pull/11970", "updateAuthor": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-11-20T15:42:55.000+0000", "updated": "2020-11-20T15:42:55.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }