- Each breaking change should be discussed in a design document. We
can discuss the rollout plan on a case-by-case basis.
- A change in Bazel should never break a project tested on Bazel CI.
We won't be able to release Bazel 1.0 if we're not able to do
guarantee stability to users.
> I think better to make commitment in terms of time instead of number of releases.
Releases are time-based, so it's kind of the same. The date you submit
your change is not meaningful for the users - they will care the day
their Bazel binary contains your change.
On Wed, 22 Aug 2018 at 20:14, Dmitry Babkin <dba...@google.com> wrote:
>
> - We wait again multiple releases before removing the flag.
> I think better to make commitment in terms of time instead of number of releases.
> For instance: after 1st of November this flag will be removed.
>
> On Tue, Aug 21, 2018 at 2:59 PM Laurent Le Brun <laur...@google.com> wrote:
>>
>> For Starlark language/API, we follow this process:
>> https://docs.bazel.build/versions/master/skylark/backward-compatibility.html
>> and we try to go slowly.
>> - We first update the documentation to mark something as deprecated.
>> - When a flag is introduced, we wait multiple releases before we switch it.
>> - We announce changes in the release announcement.
>> - We wait again multiple releases before removing the flag.
>> - We try to provide a good error message. We often keep special-cases
>> in the code just to have a good error message (it generally mentions
>> the incompatible flag to switch).
>> - We try to do this, even when we just fix a bug (e.g. we rolled back
>> the fix for https://github.com/bazelbuild/bazel/issues/5709 because it
>> could possibly break users, even if we haven't found any code that
>> would break).
>>
>> In my opinion, this is not enough and we should try to do more.
>> - We are working on better tooling
>> (https://github.com/bazelbuild/buildtools/issues/341). We should
>> provide a tool to automatically fix user code, at least for the simple
>> cases.
--
You received this message because you are subscribed to the Google Groups "bazel-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-dev+...@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/CAFtxR%2BksMsNXicTr0j24fq3q%2BRj59cqa3eZair_gP%3Dc0DLHnjg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/8268e3b9-c8f9-4552-8446-287ea740cb76%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-dev+unsubscribe@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/CAFtxR%2BksMsNXicTr0j24fq3q%2BRj59cqa3eZair_gP%3Dc0DLHnjg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-dev+...@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/CAFtxR%2BksMsNXicTr0j24fq3q%2BRj59cqa3eZair_gP%3Dc0DLHnjg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--Lukács T. Berki | Software Engineer | lbe...@google.com |Google Germany GmbH | Erika-Mann-Str. 33 | 80636 München | Germany | Geschäftsführer: Paul Manicle, Halimah DeLaine Prado | Registergericht und -nummer: Hamburg, HRB 86891
--
You received this message because you are subscribed to a topic in the Google Groups "bazel-dev" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/bazel-dev/tk3szEs1WAY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to bazel-dev+...@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/CAOu%2B0LW%3DJn58j4fefUobbO%2BY6vijXMQ4J8BxmuYXV5iBCu1H%2Bg%40mail.gmail.com.
FWIW, I suspect a lot of the pain of slower velocity will be felt much more in work on rule logic, as compared with work on Starlark or core logic. (The differing views within the team seem to at least partially fall along those boundaries.)
Maybe that's an argument for applying radical stability to Bazel itself before its native / "blessed" rule sets. But that doesn't solve the underlying problem, that we're still breaking users every release.
On Thu, Aug 23, 2018 at 9:58 AM 'Lukács T. Berki' via bazel-dev <baze...@googlegroups.com> wrote:@Tony: What's your opinion on the fact that removing old functionality would then take *at least* two months even if it's actually unused?
> This line of reasoning is why I like visible deprecation warnings. They tell a user that the next release will break them.So does a linter, or running with --all_incompatible_changes. The user you're protecting is the user who declines to do those things. Rather than advocate to that user by dumping on their console, we could advocate to them via friendly reminders on the release page and in the blog post ("please run with --all_incompatible_changes to ensure...").
> I suspect that the more common case is that they will have to remember that when they upgrade to Bazel n+1, they should update their third party rule sets as well.Probably. But here's my attempt at finding an overly reductive dichotomy out of this: If the ruleset is poorly maintained, then there's no upgrade to speak of.
If the ruleset is well maintained, then the maintainer could be trusted to annotate the old version as incompatible with newer Bazels, and the user gets a nice friendly failure message. (We may need some utils in a standard .bzl file to assist with this.)
But again, assuming that the user is updating frequently enough to catch the flag in a release after it's been defaulted to true, and before it's been removed, why do we need anything special? The user can just opt-out of the flag. The fail-by-default-then-opt-out workflow serves as their warning.
> I suspect that the more common case is that they will have to remember that when they upgrade to Bazel n+1, they should update their third party rule sets as well.Probably. But here's my attempt at finding an overly reductive dichotomy out of this: If the ruleset is poorly maintained, then there's no upgrade to speak of. If the ruleset is well maintained, then the maintainer could be trusted to annotate the old version as incompatible with newer Bazels, and the user gets a nice friendly failure message. (We may need some utils in a standard .bzl file to assist with this.)
But again, assuming that the user is updating frequently enough to catch the flag in a release after it's been defaulted to true, and before it's been removed, why do we need anything special? The user can just opt-out of the flag. The fail-by-default-then-opt-out workflow serves as their warning.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-dev+unsubscribe@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/CAFtxR%2BksMsNXicTr0j24fq3q%2BRj59cqa3eZair_gP%3Dc0DLHnjg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--Lukács T. Berki | Software Engineer | lbe...@google.com |Google Germany GmbH | Erika-Mann-Str. 33 | 80636 München | Germany | Geschäftsführer: Paul Manicle, Halimah DeLaine Prado | Registergericht und -nummer: Hamburg, HRB 86891
--
You received this message because you are subscribed to a topic in the Google Groups "bazel-dev" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/bazel-dev/tk3szEs1WAY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to bazel-dev+unsubscribe@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/CAOu%2B0LW%3DJn58j4fefUobbO%2BY6vijXMQ4J8BxmuYXV5iBCu1H%2Bg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
An issue was warnings on the console output is that they are spammy.
On a project with multiple contributors and multiple dependencies, a
warning is often not relevant to you. Most of the time, the warning
should be addressed by another person. So you'll stop paying attention
to the output (imagine if each time you build your project, 10-20
lines of noise appear). If your change introduces a new warning,
chances are you won't even notice it.
To make things work, there are many features we may want:
- flag to fail the build if there's a warning (like -Werror)
- flag to turn off specific warnings
- flag to filter the warnings we display based on their location
- some cleverness to avoid flooding the console. If a piece of code
is executed multiple times, it should show at most one warning. It's
not clear how to do it exactly, for example if a macro is used in many
packages.
But I'd like to point out we can't always use warnings. For example,
we're updating the "range" function. Instead of returning allocating
the whole list, it returns a lazy object. In most cases, users won't
see any difference, but it can cause subtil changes in the rest of the
code (e.g. if you convert the object to string). We're using an
--incompatible flag for this. But I don't see how to use a warning.
>
> In a sense, what we have here is a specific instance of the "how to update your transitive dependencies" problem. At Google, we just solve this by keeping everything at HEAD, but that doesn't fly with Bazel. I think in order to reduce fragmentation in the ecosystem, we should make an effort to keep everyone as close to the latest release of Bazel and the latest release of rule sets as possible. Of course, that directly contradicts our desire to make changes to Bazel :(
>
> And yes, a lot of the grief stems from the fact that we cannot know what features are being used. There is, of course, the siren song of on-by-default telemetry so that we do know what features are used, but that's a very significant change and it wouldn't be perfect either, because not all Bazel invocations are done on computers connected to the Internet... maybe we can make a rule that if you don't want to be broken by a Bazel release, you need to do some things, for example:
>
> Run your builds with release candidates and if you don't report a breakage with a release candidate, the breakage is deemed to not be release-breaking
> Run builds with the set of incompatible flags we publish and if the next release that flips an incompatible flag, breaks you, and you didn't notify us (or even just didn't update your code), you're on your own
> Submit some code to ci.bazel.build that exercises the features you use and thus we get automatic advance warning (that can easily degrade into us running the Continuous Integration For The World, though, which I don't want to sign up for)
>
> This won't change a lot when we reach 1.0, either. We may need to make stronger guarantees about not breaking people, but we'll still need to be able to make incompatible changes in some way.
I'm enjoying watching this discussion. Thanks for having it on a public list!
On Thu, Aug 23, 2018 at 12:16 PM 'Jon Brandvein' via bazel-dev <baze...@googlegroups.com> wrote:> I suspect that the more common case is that they will have to remember that when they upgrade to Bazel n+1, they should update their third party rule sets as well.Probably. But here's my attempt at finding an overly reductive dichotomy out of this: If the ruleset is poorly maintained, then there's no upgrade to speak of. If the ruleset is well maintained, then the maintainer could be trusted to annotate the old version as incompatible with newer Bazels, and the user gets a nice friendly failure message. (We may need some utils in a standard .bzl file to assist with this.)And it can be a lot of work to upgrade third_party rulesets. rules_closure can require us to modify a lot of javascript to remove linter warnings. rules_go requires us to port our changes to get hermetic compilers working back onto the new version. Upstream does not yet support our use case, and I'm not sure some of the flags we need are exposed without the bazel patches we re-apply every release. The last upgrade took 2 weeks.
But again, assuming that the user is updating frequently enough to catch the flag in a release after it's been defaulted to true, and before it's been removed, why do we need anything special? The user can just opt-out of the flag. The fail-by-default-then-opt-out workflow serves as their warning.-Werror -Wextra in gcc is similar to this. We turn those flags on by default for all code, and then do the -Wno-crazy-warning-flag for the ones which conflict with code we don't/can't update. That would be a pretty visible but give people hooks to delay a fix. That is assuming a more savvy user though who cares about the build and isn't just trying to build tensorflow and this is another blocker.
I want our code base to be on more modern bazel. I'd ideally like to see us update every release.With skylark rules, the developer gets to pick when to update, or if to update. With built-in rules, we don't get a choice and need to migrate. This has in the past blocked bazel upgrades for months for us.
Austin
On Fri, 24 Aug 2018 at 16:25, Tony Aiuto <ai...@google.com> wrote:
> On Fri, Aug 24, 2018 at 8:07 AM Laurent Le Brun <laur...@google.com> wrote:
>> An issue was warnings on the console output is that they are spammy.
>> On a project with multiple contributors and multiple dependencies, a
>> warning is often not relevant to you. Most of the time, the warning
>> should be addressed by another person. So you'll stop paying attention
>> to the output (imagine if each time you build your project, 10-20
>> lines of noise appear). If your change introduces a new warning,
>> chances are you won't even notice it.
>
> I wonder if we are looking at users in different ways. You say "multiple contributors", which seems to feel more like the point of view of one
> of us. I very much believe we have to take the point of view of an end user who is not a contributor to Bazel. Their organization is the single
> contributor to their code base, with their own organizational tolerance for warnings. Some people tree them as high priority things to fix, others ignore them for all.
I'm confused, because I was talking about end users. In a typical
project or company, multiple people work on the same code base. But
not everyone is responsible for every line of code. So showing every
warning to everyone is not a good idea. On average, when Bazel would
print a warning, it would be almost always shown to the "wrong"
person, i.e. not the person who is going to fix it. So a user will
learn to ignore the output (including the one line in the middle that
they should ideally care about).
On Thu, Aug 23, 2018 at 4:52 PM Austin Schuh <austin...@gmail.com> wrote:On Thu, Aug 23, 2018 at 12:16 PM 'Jon Brandvein' via bazel-dev <baze...@googlegroups.com> wrote:> I suspect that the more common case is that they will have to remember that when they upgrade to Bazel n+1, they should update their third party rule sets as well.Probably. But here's my attempt at finding an overly reductive dichotomy out of this: If the ruleset is poorly maintained, then there's no upgrade to speak of. If the ruleset is well maintained, then the maintainer could be trusted to annotate the old version as incompatible with newer Bazels, and the user gets a nice friendly failure message. (We may need some utils in a standard .bzl file to assist with this.)And it can be a lot of work to upgrade third_party rulesets. rules_closure can require us to modify a lot of javascript to remove linter warnings. rules_go requires us to port our changes to get hermetic compilers working back onto the new version. Upstream does not yet support our use case, and I'm not sure some of the flags we need are exposed without the bazel patches we re-apply every release. The last upgrade took 2 weeks.Can you describe that experience more? The conversation is helped by having more user context.Were you doing this as a developer of rules_closure, or a user of it?
But again, assuming that the user is updating frequently enough to catch the flag in a release after it's been defaulted to true, and before it's been removed, why do we need anything special? The user can just opt-out of the flag. The fail-by-default-then-opt-out workflow serves as their warning.-Werror -Wextra in gcc is similar to this. We turn those flags on by default for all code, and then do the -Wno-crazy-warning-flag for the ones which conflict with code we don't/can't update. That would be a pretty visible but give people hooks to delay a fix. That is assuming a more savvy user though who cares about the build and isn't just trying to build tensorflow and this is another blocker.Yes. That is what Laurent's proposed too - selective warning suppression. You get a warning, you can turn it off to avoid the noise. But if you turn if off and do not take action on it warned you about, and you break in the next release, then shame on you.I am still interested, however, in the attitudes of users towards that first notification. I find that sequence
- update a tool
- my build breaks
- set a flag to suppress the breakage
a horrible experience for me. It interrupts my excitement at getting a new version of the tool to play with. When I administered the tools repo for a few dozen developers and I introduced something that broke only a few of them, but not the rest, it was distinctly viewed as my fault by those who were broken. Maybe others weigh that cost less.
I want our code base to be on more modern bazel. I'd ideally like to see us update every release.With skylark rules, the developer gets to pick when to update, or if to update. With built-in rules, we don't get a choice and need to migrate. This has in the past blocked bazel upgrades for months for us.Can you say more about that? How did you discover the Bazel upgrade which you could not do? Was it update, fail, rollback? Testing new release in a sandbox? Testing a pre-release?
On Fri, Aug 24, 2018 at 7:47 AM Tony Aiuto <ai...@google.com> wrote:On Thu, Aug 23, 2018 at 4:52 PM Austin Schuh <austin...@gmail.com> wrote:On Thu, Aug 23, 2018 at 12:16 PM 'Jon Brandvein' via bazel-dev <baze...@googlegroups.com> wrote:> I suspect that the more common case is that they will have to remember that when they upgrade to Bazel n+1, they should update their third party rule sets as well.Probably. But here's my attempt at finding an overly reductive dichotomy out of this: If the ruleset is poorly maintained, then there's no upgrade to speak of. If the ruleset is well maintained, then the maintainer could be trusted to annotate the old version as incompatible with newer Bazels, and the user gets a nice friendly failure message. (We may need some utils in a standard .bzl file to assist with this.)And it can be a lot of work to upgrade third_party rulesets. rules_closure can require us to modify a lot of javascript to remove linter warnings. rules_go requires us to port our changes to get hermetic compilers working back onto the new version. Upstream does not yet support our use case, and I'm not sure some of the flags we need are exposed without the bazel patches we re-apply every release. The last upgrade took 2 weeks.Can you describe that experience more? The conversation is helped by having more user context.Were you doing this as a developer of rules_closure, or a user of it?For rules_closure, we are a user. We have some javascript built with rules_closure. It's code for debug webpages, so it's not mission critical code. That means it gets a lot less TLC than some of our C++ code which is mission critical and has safety of life implications.New rules_closure updates will bring in new rules_closure compilers. Those compilers will catch new warnings in our code. This puts the burden of updating code to fix the new warnings on our company's build and release folk rather than on the developers using rules_closure. The last upgrade I did of the rules took 1-2 days. Recent ones have been faster since the project seems to not be under active development.For C++ changes which change the compiler flags, we need to re-certify our compilers.
But again, assuming that the user is updating frequently enough to catch the flag in a release after it's been defaulted to true, and before it's been removed, why do we need anything special? The user can just opt-out of the flag. The fail-by-default-then-opt-out workflow serves as their warning.-Werror -Wextra in gcc is similar to this. We turn those flags on by default for all code, and then do the -Wno-crazy-warning-flag for the ones which conflict with code we don't/can't update. That would be a pretty visible but give people hooks to delay a fix. That is assuming a more savvy user though who cares about the build and isn't just trying to build tensorflow and this is another blocker.Yes. That is what Laurent's proposed too - selective warning suppression. You get a warning, you can turn it off to avoid the noise. But if you turn if off and do not take action on it warned you about, and you break in the next release, then shame on you.I am still interested, however, in the attitudes of users towards that first notification. I find that sequence
- update a tool
- my build breaks
- set a flag to suppress the breakage
a horrible experience for me. It interrupts my excitement at getting a new version of the tool to play with. When I administered the tools repo for a few dozen developers and I introduced something that broke only a few of them, but not the rest, it was distinctly viewed as my fault by those who were broken. Maybe others weigh that cost less.Let me be clear here. We version Bazel with our repository. That's the only way we can stay sane. I have a requirement from ISO 26262 for automotive functional safety that we can build old versions of code for many years reproducibly. So, when I say "update bazel", I mean update tools/bazel to point to a new version of bazel. I *can't* submit that change and roll a new bazel out until our CI passes again (presubmit CI). My experience is not a tensorflow user, but more of a corporate user. I also volunteer with a high-school robotics team who adopts the same approach as work.
Thanks for the info.On Fri, Aug 24, 2018 at 12:52 PM Austin Schuh <austin...@gmail.com> wrote:For C++ changes which change the compiler flags, we need to re-certify our compilers.I'm guessing you keep those under revision control then too. If you are using or planning for remote build execution, you probably must be making your own containers with the specific compilers you have certified, right?
But again, assuming that the user is updating frequently enough to catch the flag in a release after it's been defaulted to true, and before it's been removed, why do we need anything special? The user can just opt-out of the flag. The fail-by-default-then-opt-out workflow serves as their warning.-Werror -Wextra in gcc is similar to this. We turn those flags on by default for all code, and then do the -Wno-crazy-warning-flag for the ones which conflict with code we don't/can't update. That would be a pretty visible but give people hooks to delay a fix. That is assuming a more savvy user though who cares about the build and isn't just trying to build tensorflow and this is another blocker.Yes. That is what Laurent's proposed too - selective warning suppression. You get a warning, you can turn it off to avoid the noise. But if you turn if off and do not take action on it warned you about, and you break in the next release, then shame on you.I am still interested, however, in the attitudes of users towards that first notification. I find that sequence
- update a tool
- my build breaks
- set a flag to suppress the breakage
a horrible experience for me. It interrupts my excitement at getting a new version of the tool to play with. When I administered the tools repo for a few dozen developers and I introduced something that broke only a few of them, but not the rest, it was distinctly viewed as my fault by those who were broken. Maybe others weigh that cost less.Let me be clear here. We version Bazel with our repository. That's the only way we can stay sane. I have a requirement from ISO 26262 for automotive functional safety that we can build old versions of code for many years reproducibly. So, when I say "update bazel", I mean update tools/bazel to point to a new version of bazel. I *can't* submit that change and roll a new bazel out until our CI passes again (presubmit CI). My experience is not a tensorflow user, but more of a corporate user. I also volunteer with a high-school robotics team who adopts the same approach as work.Understood. That is the style I expect many Bazel users to adopt. I've been there myself. A small tools group owns the upgrades of common stuff for the whole company. My next question is, what is "Bazel". Do you view the update to Bazel and all the rule sets as one unit, or do you get more fine grained than that. Do you try to update rules_closure ahead of an upcoming Bazel update, or is it an all-at-once certify and publish the tool stack?
Hi,
I think this is a very important discussion.
I wanted to add that while I agree Bazel needs to advance itself the current “incompatible” cost is too large.
We (rules_scala) has it turned on for a few months and just broke down from the amount of changes and their state and we disabled these tests.
Two main issues:
1. Handling other repositories issues (I had to fix protobuf build which broke me).
2. JavaCommon added a deprecation but the replacement was broken. It took a while (which is at least a release and might have been two, don’t remember) until it was fixed which also meant we needed to ignore it for now.
--
You received this message because you are subscribed to the Google Groups "bazel-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-dev+unsubscribe@googlegroups.com.
To post to this group, send email to baze...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-dev/bd281782-86f7-49c0-bd29-00261a554de1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.