Change:
Comments that the PR bot adds solely to trigger email notification of a label change, should be immediately deleted by the bot after it adds them. I have no idea what team to assign this to... cc/
, David Oppenheimer wrote:
(Motivation, of course, is to avoid having PR threads that are 90% bot comments...)
should really be an issue over in that's where (some of) the bots live. Lets make a list of which comments we want deleted immediately. [x] Label size. [x] Needs rebase. [x] test this stale CI [x] test this pending CI [x] PR changed after LGTM, removing LGTM. [x] Comment about blocking based on the paths touched (old docs) [x] unapproved cherrypick comment [x] cherrypicks must set a milestone [x] ok to test from bot I don't want to make it all comments. There are way too many times people have asked me "Why did the bot add 'do-not-merge'?" and I can just link them the comment 2 lines above which tells exactly why....
"Test this" with an issue is also useful, isn't it? On Apr 7, 2016 6:30 PM, "Eric Paris" wrote:
OK to test Add to whitelist On Apr 7, 2016 6:30 PM, "Eric Paris" wrote:
I was envisioning deleting the by the bot. (every 48 hours after LGTM, when retesting right before merge) not those by users (with an issue) After LGTM the bot will add , that one I can remove. The request to comes from the jenkins bot. And in that I am clueless...
any interest in a review (I'm trying to not just self merge all my own bot changes). This deleted hundreds and hundreds of comments.
Looks like reviewed it since your last message:

Discussion:
List(filter string) ([]string, error) } <ins> // Zone represents the location of a particular machine type Zone struct { FailureDomain string Region        string } </ins> // Zones is an abstract, pluggable interface for zone enumeration. type Zones interface { <del> // GetZone returns the name of the current failure zone that the program is running in GetZone() (string, error) </del> <ins> // GetZone returns the Zone containing the current failure zone and locality region that the program is running in GetZone() (Zone, error) </ins> }

Calls    []string IP       net.IP Machines []string <del> Zone     string </del> <ins> Zone </ins> } func (f *FakeCloud) addCall(desc string) {

return result, f.Err } <del> func (f *FakeCloud) GetZone() (string, error) { </del> <ins> func (f *FakeCloud) GetZone() (Zone, error) { </ins> f.addCall("get-zone") return f.Zone, f.Err }

return instances, nil } <del> func (gce *GCECloud) GetZone() (string, error) { return gce.zone, nil </del> <ins> func (gce *GCECloud) GetZone() (Zone, error) { region, err := getGceRegion(gce.zone) if err != nil { return Zone{}, err } return Zone{ FailureDomain: gce.zone, Region:        region, }, nil } // gce zone names are of the form: ${region-name}-${ix}. // For example "us-central1-b" has a region of "us-central1". // So we look for the last '-' and trim to just before that. func getGceRegion(zone string) (string, error) { ix := strings.LastIndex(zone, "-") if ix == -1 { return "", fmt.Errorf("unexpected zone: %s", zone) } return zone[:ix], nil </ins> }

<ins> /* Copyright 2014 Google Inc. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ package cloudprovider import ( "testing" ) func TestGetRegion(t *testing.T) { gce := &GCECloud{ zone: "us-central1-b", } zones, ok := gce.Zones() if !ok { t.Fatalf("Unexpected missing zones impl") } zone, err := zones.GetZone() if err != nil { t.Fatalf("unexpected error %v", err) } if zone.Region != "us-central1" { t.Errorf("Unexpected region: %s", zone.Region) } } </ins>

return err } <del> if err := balancer.DeleteTCPLoadBalancer(service.JSONBase.ID, zone); err != nil { </del> <ins> if err := balancer.DeleteTCPLoadBalancer(service.JSONBase.ID, zone.Region); err != nil { </ins> return err }

if err != nil { return nil, err } <del> err = balancer.CreateTCPLoadBalancer(srv.ID, zone, srv.Port, hosts) </del> <ins> err = balancer.CreateTCPLoadBalancer(srv.ID, zone.Region, srv.Port, hosts) </ins> if err != nil { return nil, err }