-
Notifications
You must be signed in to change notification settings - Fork 208
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
Optional outputs #291
Optional outputs #291
Conversation
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
@googlebot I consent. Gotta figure why this fails the check. One of these days. |
I'll give this a review once it's synced. Also, I think the CLAbot fails because your PR includes (because of hte way you merged master into this branch, rather than rebasing on top of master) it includes one of my commits. Because there are commits from authors that aren't the PR author, they need to consent. So it's actually my commit that's at issue. If you rebase on |
85a9231
to
fb00402
Compare
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
fb00402
to
53319cd
Compare
bce4c42
to
cb384f3
Compare
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
cb384f3
to
dc66a0f
Compare
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
…ested do not create it. Break apart compileAll to allow stage independent compilations. Make jdeps optional, as it is not currently consumed so we shouldn't do the work. Update test framework to handle the output scheme. If kotlin srcs are absent, skip kotlin compilation. Issue: bazelbuild/issues/232
…e explicit and resilient that using collect_default.
dc66a0f
to
5f538dc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved with some nits and comments.
val friendPaths = info.friendPathsList.map { Paths.get(it).toAbsolutePath() } | ||
val cp = inputs.joinedClasspath | ||
val args = mutableListOf<String>() | ||
args.addAll(baseArgs() + listOf( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- isn't lazy, here, unless you're passing Sequence. While this is hardly the place where key optimizations need to happen, this will create a new list, and add all the lists, only to add them to a list. 🤷♂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not worry about it, but this was just to remind you about + and lists.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hrm. Kotlin isn't smart, I guess. Builder time. Mostly, I didn't like the mutable list passing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, it's not that big a deal (especially at this N) - you can just use sequences here, and it'll do the same thing. Just remember, Lists - eager, Sequences - lazy, and you're fine.
return args | ||
} | ||
|
||
internal fun JvmCompilationTask.baseArgs(): List<String> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please pick a style. getFoo()
or foo()
(or internal val JvmCompilationTask.commonArgs get() =
if you want to be all kotlin-properties about it)
(as in, getCommonArgs()
is a thing, so either keep consistent, or rename that to commonArgs()
or whatever, so they're consistent)
:)
LGTM |
* Convert all Dep dependencies to be addressable by label at test time. * Add files explicitly to runfiles from the data attribute. This is more explicit and resilient that using collect_default. * New output scheme for the JvmCompilationTask, if an output isn't requested do not create it. * Break apart compileAll to allow stage independent compilations. Make jdeps optional, as it is not currently consumed so we shouldn't do the work. Update test framework to handle the output scheme. If kotlin srcs are absent, skip kotlin compilation. * Introduce CompilationArgs to improve compilation argument readability Issue: bazelbuild/issues/232
* upstream/master: Fix non-reproducible archives (bazelbuild#304) Adds a kt_plugin rule (bazelbuild#308) Ensure that KotlionBuilder workers use a clean directory for each compilation. (bazelbuild#298) Apply autoformatting to all files. (bazelbuild#302) Optional outputs (bazelbuild#291) Change plugins to use depsets, as opposed to lists. (bazelbuild#292) Add Corbin to the codeowners. (bazelbuild#293) Update Protobuf to 3.11.3 (bazelbuild#286) Remove tree artifacts (bazelbuild#287) Cleanup src tree (bazelbuild#288) Update README.md (bazelbuild#285) Filter non-kotlin code out of generated sources (bazelbuild#263) Update readme so the dev instructions highlight using a local clone (bazelbuild#283) Remove third_party checked in jars, and properly pull maven dependencies. (bazelbuild#279) Only propagate srcjar if it isn't the default empty jar added in ae70089 to fix bazelbuild/intellij#1616 (bazelbuild#276) Allow resources to be in a kotlin directory (bazelbuild#268)
* Convert all Dep dependencies to be addressable by label at test time. * Add files explicitly to runfiles from the data attribute. This is more explicit and resilient that using collect_default. * New output scheme for the JvmCompilationTask, if an output isn't requested do not create it. * Break apart compileAll to allow stage independent compilations. Make jdeps optional, as it is not currently consumed so we shouldn't do the work. Update test framework to handle the output scheme. If kotlin srcs are absent, skip kotlin compilation. * Introduce CompilationArgs to improve compilation argument readability Issue: bazelbuild/issues/232
Changes the builder to be more intelligent about work execution: If an output is not requested, it is not created
Jdeps output is now optional, as it is not currently consumed.
Fix for java_test runfiles and kt_jvm_import. native rules consume runfiles in a separate private provider, to ensure that all starlark runfiles are picked up, each starlark rule should create runfiles.
Depends on: //pull/290