It looks like the partial Commits are coming from the build breakages mails.
If you have commit A newer than commit B, then there are two code
paths depending on which reports its build result first.
For slow development, B finishes before A is committed, so when
A notices a failure it checks to see if B was okay.
That code path seems to be okay.
For submit of back-to-back changes, typically A finishes before B,
so when B notices an okay it checks to see if A failed.
That code path seems to zero the Commit for A while
trying to set its FailNotificationSent to true.
It does (did) succeed in setting FailNotificationSent to true,
it just zeroed everything else.
This CL adds code to refuse to do the datastore.Put to
update FailNotificationSent if the Commit info is incomplete.
It also tries to ignore Num=0 records, but that may not be
as important anymore.
LGTM=cmang
R=cmang
CC=golang-codereviews
https://golang.org/cl/154080043
The UI template iterates over ResultGoHashes to display the Commit
rows. This was done for the sub-repository build view, where it
only makes sense to show a row when there's build data for it.
However, in the main page UI we do want to see if a commit has hit
the dashboard but has not yet been built.
This change causes the dashboard to show the commit row even if
there are no build results for it yet.
LGTM=bradfitz
R=bradfitz
CC=golang-codereviews
https://golang.org/cl/153010043
Only gccgo should be using this now, and hopefully not for too long.
Turn it off by default, and make it the only thing that happens
when it's switched on.
LGTM=bradfitz, cmang
R=bradfitz, cmang
CC=golang-codereviews
https://golang.org/cl/153940043
Fixesgolang/go#8792.
This is a simple change that fixes the issue. It may be desireable
to opt for a larger code change that makes this problem less likely
to be inadvertedly reintroduced in the future. For instance, a vetMain()
func can be used similar to gofmtMain(), or the os.Exit call can be
deferred.
LGTM=r
R=golang-codereviews, r
CC=golang-codereviews
https://golang.org/cl/150850043
The type-checker depended on (token.Pos) position information of
the presented files to determine source order. That information
is determined by the parse order of the files rather than the
order in which the files are presented to the type-checker.
Introduced an order number strictly determined by the file
order as presented to the type-checker and the AST structure
of each file; thus providing source order information even in
the absence of (token.Pos) position information.
Added test case (provided by adonovan).
LGTM=adonovan
R=adonovan
CC=golang-codereviews
https://golang.org/cl/151160043
So the optimization to avoid hg clone works again. The
builder looks at buildroot+"goroot" for an hg clone repo. If
it finds it, it can just "hg pull" instead of a slow "hg
clone".
LGTM=cmang
R=cmang, proppy
CC=golang-codereviews
https://golang.org/cl/147960044
Windows doesn't regard "/go/src" as an absolute path,
so we must explicitly define the virtual IsAbsPath method.
LGTM=gri
R=gri, sameer
CC=golang-codereviews
https://golang.org/cl/147100043
...by using buildutil.ContainingPackage instead of guessImportPath.
The former should be more portable.
(I meant to do this earlier, so this is also a nice cleanup.)
LGTM=gri
R=gri, sameer
CC=golang-codereviews
https://golang.org/cl/148050043
The 'parents' field is documented to be blank if there's only one
simple parent. We want 'p1node', which is the hex commit of the
first parent.
LGTM=adg
R=adg
CC=golang-codereviews
https://golang.org/cl/142530043
Also add a added=true addition that I seemed to think was
previously missing.
Breaking this out of previous big CL.
LGTM=adg
R=adg
CC=golang-codereviews
https://golang.org/cl/146080043
See the usage message in main.go for orientation.
To the best of my knowledge, the tool implements all required
soundness checks, except:
- the dynamic behaviour of reflection is obviously undecidable.
- it rejects method renamings that change the "implements" relation.
It should probably be more aggressive.
- actually it only checks the part of the "implements" relation
needed for compilation. Understanding the dynamic behaviour
of interfaces is obviously undecidable.
- a couple of minor gaps are indicated by TODO comments.
Also:
- Emacs integration.
- tests of all safety checks and (some) successful rewrites.
LGTM=dominik.honnef, sameer
R=gri, sameer, dominik.honnef
CC=golang-codereviews
https://golang.org/cl/139150044
- ParseFile (core of go/loader's parseFiles(); also used by refactor/rename)
- ContainingPackage (core of Oracle's guessImportPath; also used by refactor/rename)
- Accessors for effective "methods" of build.Context:
FileExists, OpenFile, IsAbsPath, JoinPath.
LGTM=sameer
R=dave, sameer
CC=golang-codereviews, gri
https://golang.org/cl/146120043
The type checker does not currently report the set of pairs of
types that are tested for assignability (though gri and I
agree that it should). This information is useful for many
applications. For example, refactoring tool needs to know the
minimal set of interface satisfaction constraints that must be
preserved during a refactoring.
This package is a stopgap measure to deduce the same
information using another pass. Unlike go/types, it is not
robust against inputs containing type errors.
LGTM=sameer
R=gri, sameer
CC=golang-codereviews
https://golang.org/cl/136470043
The Uses, Defs and Scope information provided by go/types is
inadequate for answering "what if?" queries about the
structure of the lexical environment.
In this code, for example,
var x int
func f() {
print(x)
x := ""
print(x)
}
the two referring Idents x appear at the same lexical depth,
inside the function f's Scope object, yet they resolve to
different objects.
This package associates a lexical.Environment instance with
every reference to capture these differences. Each
environment is a linked list of enclosing Blocks, and for each
block, a number indicating what prefix of its bindings are
visible. (Zero for the first 'x' reference above, 1 for the
second.)
+ Smoke test over stdlib.
This functionality could be integrated with the type checker
in lieu of the not-so-useful types.Info.Scopes data, at little
extra cost in code or in running time/space. We should talk
about that.
LGTM=sameer
R=gri, sameer
CC=golang-codereviews
https://golang.org/cl/143790043
Nodes in a strongly connected component (which includes most
stdlib packages) appear in results of both "forward" and
"reverse" searches from any other node in the same SCC.
LGTM=sameer
R=sameer
CC=golang-codereviews, gri
https://golang.org/cl/136470044
This was a hold-over from when we removed install counts years ago.
All the Package entities are well-formed these days.
LGTM=dsymonds
R=dsymonds
CC=golang-codereviews
https://golang.org/cl/138620043
Previously type errors were reported via the web interface but
not logged, but this led to confusion as to why SSA
construction and/or pointer analysis were not attempted.
LGTM=gri
R=gri, bradfitz
CC=golang-codereviews
https://golang.org/cl/136660043
Today I learned that getElementByClass returns an
HTMLContainer, not an array, so the for loop was iterating its
properties, which include:
- the methods of the type, which were filtered out by the condition;
- the array-like integer indices of the elements, which we want;
- the ids of the same elements (!), which we weren't expecting.
The net result is that various functions were called twice,
causing the tree to be double-populated and clicks to cause
and expand+collapse.
It's a miracle to me that any JS program even approximately works.
Fixesgolang/go#8237
LGTM=bradfitz
R=gri, bradfitz
CC=golang-codereviews
https://golang.org/cl/141540043