{"action":"created","issue":{"url":"https://api.github.com/repos/lelandrichardson/react-native-maps/issues/502","repository_url":"https://api.github.com/repos/lelandrichardson/react-native-maps","labels_url":"https://api.github.com/repos/lelandrichardson/react-native-maps/issues/502/labels{/name}","comments_url":"https://api.github.com/repos/lelandrichardson/react-native-maps/issues/502/comments","events_url":"https://api.github.com/repos/lelandrichardson/react-native-maps/issues/502/events","html_url":"https://github.com/lelandrichardson/react-native-maps/pull/502","id":173351944,"number":502,"title":"Update for compatibility with React-Native 0.32 (Android) and fix local installation/building and local React-Native reference","user":{"login":"chrisknepper","id":4976096,"avatar_url":"https://avatars.githubusercontent.com/u/4976096?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisknepper","html_url":"https://github.com/chrisknepper","followers_url":"https://api.github.com/users/chrisknepper/followers","following_url":"https://api.github.com/users/chrisknepper/following{/other_user}","gists_url":"https://api.github.com/users/chrisknepper/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisknepper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisknepper/subscriptions","organizations_url":"https://api.github.com/users/chrisknepper/orgs","repos_url":"https://api.github.com/users/chrisknepper/repos","events_url":"https://api.github.com/users/chrisknepper/events{/privacy}","received_events_url":"https://api.github.com/users/chrisknepper/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":19,"created_at":"2016-08-26T01:58:32Z","updated_at":"2016-08-29T21:40:42Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/lelandrichardson/react-native-maps/pulls/502","html_url":"https://github.com/lelandrichardson/react-native-maps/pull/502","diff_url":"https://github.com/lelandrichardson/react-native-maps/pull/502.diff","patch_url":"https://github.com/lelandrichardson/react-native-maps/pull/502.patch"},"body":"This pull request seeks to address two issues with `react-native-maps` on Android.\r\n\r\n1. For a few recent versions of `react-native`, the constructor signature for the UI Event class changed, causing `MapView` to crash upon rendering. This is addressed in #450 and that code change is also included here.\r\n\r\n2. The recommended installation of this plugin (as seen in Instructions.md) states that this module should be required in Gradle like this:\r\n\r\n```groovy\r\ncompile 'com.airbnb.android:react-native-maps:0.7.1'\r\n```\r\n\r\nThat syntax, combined with the way that the plugin had been structured causes problems. Gradle doesn't recurse/ignores the `settings.gradle` in this plugin file telling it to include `lib`, which means that before this change, a user would also need to include this in their app's `android/settings.gradle` file:\r\n\r\n```groovy\r\ninclude ':react-native-maps'\r\nproject(':react-native-maps').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-maps/android/lib')\r\n```\r\n\r\nWhich almost works, but since then it only looks in `lib`, it ignores the `build.gradle` in the plugin root telling it where to find the local `react-native`. These problems combine in a way which causes this plugin to download and reference `react-native` from Maven, not locally.\r\n\r\nOn Maven, the newest version of `react-native` available is 0.20.1. If Gradle gets it from there instead of locally (i.e. 0.32), it fails to build because of the signature change I refer to in point 1. \r\n\r\nSo bottom line **we should reference `react-native`from the peer node_modules folder, and encourage users of the plugin include it in their `app/build.gradle` files the new way**:\r\n\r\n `android/app/build.gradle`:\r\n```groovy\r\ncompile project(':react-native-maps')\r\n```\r\n\r\n`android/settings.gradle`:\r\n```groovy\r\ninclude ':react-native-maps'\r\nproject(':react-native-maps').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-maps/android')\r\n```"},"comment":{"url":"https://api.github.com/repos/lelandrichardson/react-native-maps/issues/comments/243265729","html_url":"https://github.com/lelandrichardson/react-native-maps/pull/502#issuecomment-243265729","issue_url":"https://api.github.com/repos/lelandrichardson/react-native-maps/issues/502","id":243265729,"user":{"login":"felipecsl","id":190648,"avatar_url":"https://avatars.githubusercontent.com/u/190648?v=3","gravatar_id":"","url":"https://api.github.com/users/felipecsl","html_url":"https://github.com/felipecsl","followers_url":"https://api.github.com/users/felipecsl/followers","following_url":"https://api.github.com/users/felipecsl/following{/other_user}","gists_url":"https://api.github.com/users/felipecsl/gists{/gist_id}","starred_url":"https://api.github.com/users/felipecsl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/felipecsl/subscriptions","organizations_url":"https://api.github.com/users/felipecsl/orgs","repos_url":"https://api.github.com/users/felipecsl/repos","events_url":"https://api.github.com/users/felipecsl/events{/privacy}","received_events_url":"https://api.github.com/users/felipecsl/received_events","type":"User","site_admin":false},"created_at":"2016-08-29T21:40:42Z","updated_at":"2016-08-29T21:40:42Z","body":"Also this file needs to be updates with the new path: https://github.com/lelandrichardson/react-native-maps/blob/master/example/android/settings.gradle"}}
{"actor":{"display_login":"felipecsl"}}