-
Notifications
You must be signed in to change notification settings - Fork 527
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove kt_download_local_dev_dependencies() from WORKSPACE file once rules_kotlin() is released #1535
Comments
@miaboloix |
Hey @FareesHussain. I think @jcqli might be working on this as part of #2431. |
Sure, I did'nt notice that miaboloix was already assigned |
@BenHenning this is done right? |
I mean the underlying work for this has been done we just need to remove the local dependency from workspace file now |
@aggarwalpulkit596 Removing |
@jcqli Unassigning you from this issue because of inactivity, please re-assign yourself if you are currently working on this. |
(Closing to trigger the TODO workflow). |
The issue is reopened because of the following unresolved TODOs: Line 33 in 87a7acc
|
This is early work to migrate the codebase to Bazel 5.x (and maybe 6.x), as well as Kotlin to 1.6 (and maybe 1.7). The Kotlin migration is needed due to an incompatibility with older rules_kotlin and Bazel 5.x. Other dependencies needed updating, as well, including Dagger and rules_java. Issue #1535 is being fixed as part of these upgrades. As part of working through the Dagger issues that were encountered, it was noticed that the codebase was actually setting up Dagger incorrectly. This has been corrected: the codebase now defines a single top-level dagger_rules(). This commit is not yet the final solution--the build doesn't yet work and requires investigation before the rest of the work can be completed. This commit partly continues the migration work from #4092 though it's not yet finished. What remains includes: - Migrating to latest Bazel & Kotlin versions - If possible, modularize all third-party deps like oppia-proto-api - Enable strict Kotlin & Java deps - Enable warnings-as-errors for Kotlin & Java (and fix all issues) - Ensure Guava-Android is used instead of JRE - Resolve all Maven conflicts - Remove dependence on Oppia's custom Android tools - Remove support on legacy D8 (needs verification) - Remove disabling incremental dexing (for faster builds) - Disabling header compilation being disabled (for faster builds)
## Explanation Fixes #1535 Fixes part of #4120 This PR preps for the codebase-wide migration to Kotlin 1.6 (done in #4937) by first upgrading rules_kotlin from 1.5.0 alpha 2 to 1.5.0 beta 3. This upgrade, while small, produces a few nice benefits: - It removes the need for extra WORKSPACE dependency setup (thus addressing #1535). - It moves a bunch of rules_kotlin macros to new locations which results in changing nearly every ``BUILD.bazel`` file in the codebase. The changes are straightforward to review in isolation, so this PR acts as a means to help reduce the complexity of #4937 by pulling ahead these groups of ``BUILD.bazel`` changes while also moving rules_kotlin the smallest number of versions (ahead of the more major upgrades which will occur downstream). Note that this change is needed because: - We'll need to upgrade to a newer version of rules_kotlin in order to bring in Kotlin 1.6 support. - rules_kotlin moved these macros and using the old ones results in a _lot_ of build warnings that spam the local console when trying to build. Separately, this PR includes some minor trailing space cleanup in wiki/Oppia-Bazel-Setup-Instructions.md that was noticed when editing the file (since my local development environment auto-strips trailing spaces). ## Essential Checklist - [x] The PR title and explanation each start with "Fix #bugnum: " (If this PR fixes part of an issue, prefix the title with "Fix part of #bugnum: ...".) - [x] Any changes to [scripts/assets](https://github.com/oppia/oppia-android/tree/develop/scripts/assets) files have their rationale included in the PR explanation. - [x] The PR follows the [style guide](https://github.com/oppia/oppia-android/wiki/Coding-style-guide). - [x] The PR does not contain any unnecessary code changes from Android Studio ([reference](https://github.com/oppia/oppia-android/wiki/Guidance-on-submitting-a-PR#undo-unnecessary-changes)). - [x] The PR is made from a branch that's **not** called "develop" and is up-to-date with "develop". - [x] The PR is **assigned** to the appropriate reviewers ([reference](https://github.com/oppia/oppia-android/wiki/Guidance-on-submitting-a-PR#clarification-regarding-assignees-and-reviewers-section)). ## For UI-specific PRs only N/A -- This should only affect build infrastructure, and barely impact resulting binary builds. --------- Co-authored-by: Adhiambo Peres <[email protected]> Co-authored-by: Sean Lip <[email protected]>
Is your feature request related to a problem? Please describe.
In order for Bazel to properly build Oppia Android,
rules_kotiln
must support data-binding. The current release ofrules_kotlin
does not include bazelbuild/rules_kotlin#346, which adds this necessary support. Thus, we have created our own fork ofrules_kotlin
(https://github.com/oppia/rules_kotlin) and released this fork (https://github.com/oppia/rules_kotlin/releases/tag/legacy-1.4.0-rcx-oppia-exclusive-rc01) in order to import the most recent version ofrules_kotlin
in Oppia Android's WORKSPACE file. However, in doing this, it has become clear that our release is missing certain dependencies that the officialrules_kotlin
release includes. In order to include those dependencies, we added the following lines to our WORKSPACE file:load("@io_bazel_rules_kotlin//kotlin:dependencies.bzl", "kt_download_local_dev_dependencies")
kt_download_local_dev_dependencies()
However, once
rules_kotlin
releases a version with data-binding support, these lines will not be necessary.Describe the solution you'd like
Once
rules_kotlin
releases a version with data-binding support, we should delete the two lines mentioned above.The text was updated successfully, but these errors were encountered: