From 6b14f59d1b0e873b777ab913f775a8039749e96d Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 15 Nov 2026 07:29:33 +0000 Subject: [PATCH 1/5] fix(projectgraph): resolve the wildcard imports of a scope once The lookup of a name in a unit reads the wildcard imports of its scope. The resolution of each import can walk a unit whose lookup reads the same imports again. src/sys.rs of time 0.1.45 has eight glob uses, and the resolving guard of resolveRust stops only the keys on the stack. So the work grew with the orders of the eight imports. The glob candidates of each Rust path made each step wider, and the method measure on the lettre_email project ran for more than an hour. wildcardModules now keeps the modules of the imports of each scope. A read of a scope that a resolution reads now gets the modules of the last whole pass, and the passes repeat until the modules stay the same. The table keeps no modules that read a scope further up the chain. The lettre_email project now links in less than one second. The case rust/glob-use-many copies the shape of src/sys.rs and does not end without the change. With projectgraph.Version at 18 and the new case out, the graph and result hashes of the cases are those of 16/18 and 16/18/5. The bump to 19 adds the rows for the new case. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01PFQbqPqd9xn1fT6hBsyoUm Signed-off-by: Claude --- projectgraph/graph.go | 2 +- projectgraph/link.go | 7 +++ projectgraph/resolve.go | 62 ++++++++++++++++++- .../javascript/barrel-chain/graph.golden.json | 2 +- .../commonjs-require/graph.golden.json | 2 +- .../default-import/graph.golden.json | 2 +- .../esm-named-import/graph.golden.json | 2 +- .../javascript/export-star/graph.golden.json | 2 +- .../exports-conditions/graph.golden.json | 2 +- .../unknown-receiver/graph.golden.json | 2 +- .../javascript/workspaces/graph.golden.json | 2 +- .../python/all-hides/graph.golden.json | 2 +- .../python/assignment/graph.golden.json | 2 +- .../python/class-body/graph.golden.json | 2 +- .../python/decorators/graph.golden.json | 2 +- .../python/external/graph.golden.json | 2 +- .../python/local-receiver/graph.golden.json | 2 +- .../python/member-call/graph.golden.json | 2 +- .../python/missing-file/graph.golden.json | 2 +- .../python/package-init/graph.golden.json | 2 +- .../python/reexport-cycle/graph.golden.json | 2 +- .../python/relative-imports/graph.golden.json | 2 +- .../python/sibling-import/graph.golden.json | 2 +- .../python/src-layout/graph.golden.json | 2 +- .../python/sys-path/graph.golden.json | 2 +- .../python/wildcard/graph.golden.json | 2 +- .../roots/extra-rules/graph.golden.json | 2 +- .../roots/library-surface/graph.golden.json | 2 +- .../roots/main-guard/graph.golden.json | 2 +- .../roots/package-json-bin/graph.golden.json | 2 +- .../roots/package-json-main/graph.golden.json | 2 +- .../procfile-dockerfile/graph.golden.json | 2 +- .../roots/pyproject-scripts/graph.golden.json | 2 +- .../testdata/roots/setup-py/graph.golden.json | 2 +- .../roots/test-file/graph.golden.json | 2 +- .../typescript/js-specifier/graph.golden.json | 2 +- .../tsconfig-paths/graph.golden.json | 2 +- .../typescript/type-only/graph.golden.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_srv_v1.0.0.json | 2 +- .../go_example.com_markup_v1.0.0.json | 2 +- .../summaries/go_std_go1.25.1.json | 2 +- .../go_github.com_acme_srv_v1.0.0.json | 2 +- .../go_github.com_acme_a_v1.0.0.json | 2 +- .../go_github.com_acme_b_v1.0.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_dep_v1.0.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_yamlish_v1.2.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_example.com_markup_v1.0.0.json | 2 +- .../summaries/go_std_go1.25.1.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../summaries/go_std_go1.25.1.json | 2 +- .../go_github.com_acme_kit_v1.0.0.json | 2 +- .../go_github.com_acme_ws_v1.0.0.json | 2 +- .../summaries/npm_plug_1.0.0.json | 2 +- .../summaries/npm_store-kit_1.0.0.json | 2 +- .../summaries/npm_kit_1.0.0.json | 2 +- .../summaries/npm_kit_1.0.0.json | 2 +- .../summaries/npm_plug_1.0.0.json | 2 +- .../summaries/npm_util-kit_1.0.0.json | 2 +- .../npm_lodash._reinterpolate_3.0.0.json | 2 +- .../summaries/npm_lodash_4.17.21.json | 2 +- .../summaries/pypi_speedy_1.0.0.json | 2 +- .../summaries/pypi_PyYAML_6.0.1.json | 2 +- .../summaries/pypi_PyYAML_6.0.1.json | 2 +- .../summaries/pypi_badpkg_1.0.0.json | 2 +- .../summaries/pypi_okpkg_1.0.0.json | 2 +- .../summaries/pypi_badpkg_1.0.0.json | 2 +- .../summaries/pypi_okpkg_1.0.0.json | 2 +- .../summaries/pypi_google-auth_2.0.0.json | 2 +- .../pypi_google-cloud-storage_2.1.0.json | 2 +- .../summaries/pypi_outer_1.0.0.json | 2 +- .../summaries/pypi_PyYAML_6.0.1.json | 2 +- .../summaries/pypi_requests_2.31.0.json | 2 +- .../summaries/pypi_urllib3_2.0.7.json | 2 +- .../summaries/python_std_3.12.3.json | 2 +- .../summaries/pypi_dep_1.0.0.json | 2 +- .../summaries/pypi_dep_1.0.0.json | 2 +- .../summaries/cargo_kit_1.0.0.json | 2 +- .../summaries/cargo_kit_1.0.0.json | 2 +- .../summaries/cargo_kit_1.0.0.json | 2 +- .../summaries/cargo_kit_1.0.0.json | 2 +- .../cases/rust/glob-use-many/expect.yaml | 55 ++++++++++++++++ .../rust/glob-use-many/project/Cargo.toml | 4 ++ .../rust/glob-use-many/project/src/main.rs | 5 ++ .../rust/glob-use-many/project/src/sys.rs | 29 +++++++++ .../glob-use/summaries/cargo_dep_1.2.0.json | 2 +- .../summaries/cargo_kit_1.0.0.json | 2 +- .../summaries/cargo_kit_1.0.0.json | 2 +- .../summaries/cargo_dep_1.2.0.json | 2 +- .../summaries/cargo_dep_1.2.0.json | 2 +- .../summaries/cargo_dep_1.2.0.json | 2 +- .../summaries/cargo_dep_1.0.0.json | 2 +- .../summaries/cargo_dep_1.0.0.json | 2 +- test/projectgraph/version_test.go | 3 + 101 files changed, 256 insertions(+), 97 deletions(-) create mode 100644 test/projectgraph/cases/rust/glob-use-many/expect.yaml create mode 100644 test/projectgraph/cases/rust/glob-use-many/project/Cargo.toml create mode 100644 test/projectgraph/cases/rust/glob-use-many/project/src/main.rs create mode 100644 test/projectgraph/cases/rust/glob-use-many/project/src/sys.rs diff --git a/projectgraph/graph.go b/projectgraph/graph.go index aac7e573..cb561324 100644 --- a/projectgraph/graph.go +++ b/projectgraph/graph.go @@ -18,7 +18,7 @@ import ( // Version is the version of the link rules. Bump it when a rule that makes a // node, an edge, a root or an unresolved site changes, so a diff of two // reports shows the change. -const Version = "18" +const Version = "19" type NodeKind string diff --git a/projectgraph/link.go b/projectgraph/link.go index 4232e21c..c6cc1a7e 100644 --- a/projectgraph/link.go +++ b/projectgraph/link.go @@ -134,6 +134,12 @@ type builder struct { // walk of a unit reads now for the result type of an external key. reading map[string]bool stepping map[nameKey]bool + // wildcardMods holds the modules of the wildcard imports of each scope. + // wildcardDepth and wildcardLow track the scopes whose modules a + // resolution reads now, as wildcardModules describes. + wildcardMods map[*scope]*wildcardModules + wildcardDepth int + wildcardLow int // unitTypes holds the type that a unit of dependency code gives for // each external key, or "". unitTypes map[string]string @@ -274,6 +280,7 @@ func newTables(indexes []*fileindex.Index, opts Options) *builder { defs: make(map[string]*fileindex.Definition, defs), reading: map[string]bool{}, stepping: map[nameKey]bool{}, + wildcardMods: map[*scope]*wildcardModules{}, unitTypes: map[string]string{}, findingBases: map[string]bool{}, state: map[langcode.Code]any{}, diff --git a/projectgraph/resolve.go b/projectgraph/resolve.go index 7c2c60c0..010fa5dd 100644 --- a/projectgraph/resolve.go +++ b/projectgraph/resolve.go @@ -478,10 +478,8 @@ func (b *builder) resolveScope(sc *scope, caller, target string) []resolution { // exactly, so its edge is direct. func (b *builder) wildcardImported(sc *scope, name string) []string { var keys []string - for _, imp := range sc.wildcards { - mod, _, ok := b.resolveModule(sc.ix, imp.Module) + for _, mod := range b.wildcardModules(sc) { switch { - case !ok: case b.units[mod] != nil: keys = append(keys, b.units[mod].names[name]...) case b.isType(mod): @@ -493,6 +491,64 @@ func (b *builder) wildcardImported(sc *scope, name string) []string { return keys } +// wildcardModules holds the modules of the wildcard imports of a scope. +// depth is the depth of the scope among the scopes that a resolution reads +// now, or 0 when the modules are whole. read marks a pass whose +// resolutions read the modules of the scope itself. +type wildcardModules struct { + mods []string + depth int + read bool +} + +// wildcardModules returns the modules of the wildcard imports of a scope, +// in the order of the imports. The resolution of a module can walk a unit +// whose name lookup reads the wildcard imports of the same scope, as the +// eight glob uses of src/sys.rs of time 0.1.45 do. Without the table each +// such lookup resolves every import again, and the work grows with the +// orders of the imports. +// +// A read of a scope that a resolution reads now gets the modules of the +// last whole pass. So the passes repeat until the modules stay the same, +// and a module that only an import after it brings into scope resolves. +// The table keeps no modules that read a scope further up the chain. Such +// a chain of scopes across files resolves again on each read. +func (b *builder) wildcardModules(sc *scope) []string { + if w := b.wildcardMods[sc]; w != nil { + if w.depth > 0 { + w.read = true + b.wildcardLow = min(b.wildcardLow, w.depth) + } + return w.mods + } + b.wildcardDepth++ + w := &wildcardModules{depth: b.wildcardDepth} + b.wildcardMods[sc] = w + outer := b.wildcardLow + b.wildcardLow = w.depth + for range len(sc.wildcards) + 1 { + w.read = false + var mods []string + for _, imp := range sc.wildcards { + if mod, _, ok := b.resolveModule(sc.ix, imp.Module); ok { + mods = append(mods, mod) + } + } + same := slices.Equal(mods, w.mods) + w.mods = mods + if !w.read || same { + break + } + } + b.wildcardDepth-- + if b.wildcardLow < w.depth { + delete(b.wildcardMods, sc) + } + w.depth = 0 + b.wildcardLow = min(outer, b.wildcardLow) + return w.mods +} + // superKeyword is the receiver of a call of a method of the base class, as // super().load() in Python and super.load() in JavaScript. A bare call of it // in JavaScript calls the constructor of the base class. diff --git a/projectgraph/testdata/javascript/barrel-chain/graph.golden.json b/projectgraph/testdata/javascript/barrel-chain/graph.golden.json index 865bbc47..a4e90ffe 100644 --- a/projectgraph/testdata/javascript/barrel-chain/graph.golden.json +++ b/projectgraph/testdata/javascript/barrel-chain/graph.golden.json @@ -178,7 +178,7 @@ "src/main.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 4, "nodes": 7, "edges": 6, diff --git a/projectgraph/testdata/javascript/commonjs-require/graph.golden.json b/projectgraph/testdata/javascript/commonjs-require/graph.golden.json index 505db74a..8836aa06 100644 --- a/projectgraph/testdata/javascript/commonjs-require/graph.golden.json +++ b/projectgraph/testdata/javascript/commonjs-require/graph.golden.json @@ -141,7 +141,7 @@ "main.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 5, "edges": 4, diff --git a/projectgraph/testdata/javascript/default-import/graph.golden.json b/projectgraph/testdata/javascript/default-import/graph.golden.json index 8778c03b..15e7c262 100644 --- a/projectgraph/testdata/javascript/default-import/graph.golden.json +++ b/projectgraph/testdata/javascript/default-import/graph.golden.json @@ -141,7 +141,7 @@ "make.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 5, "edges": 4, diff --git a/projectgraph/testdata/javascript/esm-named-import/graph.golden.json b/projectgraph/testdata/javascript/esm-named-import/graph.golden.json index 0b8d3473..20ecfee1 100644 --- a/projectgraph/testdata/javascript/esm-named-import/graph.golden.json +++ b/projectgraph/testdata/javascript/esm-named-import/graph.golden.json @@ -169,7 +169,7 @@ "src/util.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 6, "edges": 5, diff --git a/projectgraph/testdata/javascript/export-star/graph.golden.json b/projectgraph/testdata/javascript/export-star/graph.golden.json index eeb6e5e1..67c4e5c3 100644 --- a/projectgraph/testdata/javascript/export-star/graph.golden.json +++ b/projectgraph/testdata/javascript/export-star/graph.golden.json @@ -281,7 +281,7 @@ "main.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 5, "nodes": 11, "edges": 10, diff --git a/projectgraph/testdata/javascript/exports-conditions/graph.golden.json b/projectgraph/testdata/javascript/exports-conditions/graph.golden.json index 7f9522d1..f78a5bde 100644 --- a/projectgraph/testdata/javascript/exports-conditions/graph.golden.json +++ b/projectgraph/testdata/javascript/exports-conditions/graph.golden.json @@ -148,7 +148,7 @@ "lib/src/feature/y.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 4, "nodes": 7, "edges": 4, diff --git a/projectgraph/testdata/javascript/unknown-receiver/graph.golden.json b/projectgraph/testdata/javascript/unknown-receiver/graph.golden.json index 769f397f..fdb2512d 100644 --- a/projectgraph/testdata/javascript/unknown-receiver/graph.golden.json +++ b/projectgraph/testdata/javascript/unknown-receiver/graph.golden.json @@ -125,7 +125,7 @@ "main.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 5, "edges": 3, diff --git a/projectgraph/testdata/javascript/workspaces/graph.golden.json b/projectgraph/testdata/javascript/workspaces/graph.golden.json index 38a159e4..67a6463f 100644 --- a/projectgraph/testdata/javascript/workspaces/graph.golden.json +++ b/projectgraph/testdata/javascript/workspaces/graph.golden.json @@ -130,7 +130,7 @@ "packages/core/util.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 6, "edges": 5, diff --git a/projectgraph/testdata/python/all-hides/graph.golden.json b/projectgraph/testdata/python/all-hides/graph.golden.json index 54549440..1734e12b 100644 --- a/projectgraph/testdata/python/all-hides/graph.golden.json +++ b/projectgraph/testdata/python/all-hides/graph.golden.json @@ -177,7 +177,7 @@ "pkg/a.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 7, "edges": 6, diff --git a/projectgraph/testdata/python/assignment/graph.golden.json b/projectgraph/testdata/python/assignment/graph.golden.json index 1036affb..1578e2a6 100644 --- a/projectgraph/testdata/python/assignment/graph.golden.json +++ b/projectgraph/testdata/python/assignment/graph.golden.json @@ -71,7 +71,7 @@ "main.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 3, "edges": 2, diff --git a/projectgraph/testdata/python/class-body/graph.golden.json b/projectgraph/testdata/python/class-body/graph.golden.json index 7b4cf804..47bbcdc2 100644 --- a/projectgraph/testdata/python/class-body/graph.golden.json +++ b/projectgraph/testdata/python/class-body/graph.golden.json @@ -225,7 +225,7 @@ "config.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 12, "edges": 7, diff --git a/projectgraph/testdata/python/decorators/graph.golden.json b/projectgraph/testdata/python/decorators/graph.golden.json index aeeb6bc2..2548a8f2 100644 --- a/projectgraph/testdata/python/decorators/graph.golden.json +++ b/projectgraph/testdata/python/decorators/graph.golden.json @@ -195,7 +195,7 @@ "app.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 9, "edges": 5, diff --git a/projectgraph/testdata/python/external/graph.golden.json b/projectgraph/testdata/python/external/graph.golden.json index 9bd2b241..09ebfb11 100644 --- a/projectgraph/testdata/python/external/graph.golden.json +++ b/projectgraph/testdata/python/external/graph.golden.json @@ -109,7 +109,7 @@ "main.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 5, "edges": 3, diff --git a/projectgraph/testdata/python/local-receiver/graph.golden.json b/projectgraph/testdata/python/local-receiver/graph.golden.json index 2e904a4f..53d28704 100644 --- a/projectgraph/testdata/python/local-receiver/graph.golden.json +++ b/projectgraph/testdata/python/local-receiver/graph.golden.json @@ -146,7 +146,7 @@ "main.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 5, "edges": 3, diff --git a/projectgraph/testdata/python/member-call/graph.golden.json b/projectgraph/testdata/python/member-call/graph.golden.json index d33e98aa..ba99aec7 100644 --- a/projectgraph/testdata/python/member-call/graph.golden.json +++ b/projectgraph/testdata/python/member-call/graph.golden.json @@ -261,7 +261,7 @@ "parser.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 9, "edges": 10, diff --git a/projectgraph/testdata/python/missing-file/graph.golden.json b/projectgraph/testdata/python/missing-file/graph.golden.json index dc98a83c..655943b8 100644 --- a/projectgraph/testdata/python/missing-file/graph.golden.json +++ b/projectgraph/testdata/python/missing-file/graph.golden.json @@ -56,7 +56,7 @@ "main.py": "cached" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 2, "edges": 2, diff --git a/projectgraph/testdata/python/package-init/graph.golden.json b/projectgraph/testdata/python/package-init/graph.golden.json index 6739ceea..79cd482e 100644 --- a/projectgraph/testdata/python/package-init/graph.golden.json +++ b/projectgraph/testdata/python/package-init/graph.golden.json @@ -147,7 +147,7 @@ "pkg/loader.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 6, "edges": 5, diff --git a/projectgraph/testdata/python/reexport-cycle/graph.golden.json b/projectgraph/testdata/python/reexport-cycle/graph.golden.json index 402dc9f1..940e627c 100644 --- a/projectgraph/testdata/python/reexport-cycle/graph.golden.json +++ b/projectgraph/testdata/python/reexport-cycle/graph.golden.json @@ -108,7 +108,7 @@ "main.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 3, "edges": 3, diff --git a/projectgraph/testdata/python/relative-imports/graph.golden.json b/projectgraph/testdata/python/relative-imports/graph.golden.json index ff016eb1..11e53ed3 100644 --- a/projectgraph/testdata/python/relative-imports/graph.golden.json +++ b/projectgraph/testdata/python/relative-imports/graph.golden.json @@ -157,7 +157,7 @@ "pkg/sub/b.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 6, "edges": 4, diff --git a/projectgraph/testdata/python/sibling-import/graph.golden.json b/projectgraph/testdata/python/sibling-import/graph.golden.json index 22296c2b..63d16527 100644 --- a/projectgraph/testdata/python/sibling-import/graph.golden.json +++ b/projectgraph/testdata/python/sibling-import/graph.golden.json @@ -100,7 +100,7 @@ "main.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 4, "edges": 3, diff --git a/projectgraph/testdata/python/src-layout/graph.golden.json b/projectgraph/testdata/python/src-layout/graph.golden.json index 426b2304..7373e1be 100644 --- a/projectgraph/testdata/python/src-layout/graph.golden.json +++ b/projectgraph/testdata/python/src-layout/graph.golden.json @@ -102,7 +102,7 @@ "services/api/src/api/core.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 4, "edges": 2, diff --git a/projectgraph/testdata/python/sys-path/graph.golden.json b/projectgraph/testdata/python/sys-path/graph.golden.json index 15cfe389..de34821d 100644 --- a/projectgraph/testdata/python/sys-path/graph.golden.json +++ b/projectgraph/testdata/python/sys-path/graph.golden.json @@ -84,7 +84,7 @@ "lib/shared.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 3, "edges": 2, diff --git a/projectgraph/testdata/python/wildcard/graph.golden.json b/projectgraph/testdata/python/wildcard/graph.golden.json index a163f008..d7824985 100644 --- a/projectgraph/testdata/python/wildcard/graph.golden.json +++ b/projectgraph/testdata/python/wildcard/graph.golden.json @@ -114,7 +114,7 @@ "util.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 4, "edges": 3, diff --git a/projectgraph/testdata/roots/extra-rules/graph.golden.json b/projectgraph/testdata/roots/extra-rules/graph.golden.json index 7f7b79fe..e4e11268 100644 --- a/projectgraph/testdata/roots/extra-rules/graph.golden.json +++ b/projectgraph/testdata/roots/extra-rules/graph.golden.json @@ -108,7 +108,7 @@ "views.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 7, "edges": 0, diff --git a/projectgraph/testdata/roots/library-surface/graph.golden.json b/projectgraph/testdata/roots/library-surface/graph.golden.json index da844439..8a6ac8b6 100644 --- a/projectgraph/testdata/roots/library-surface/graph.golden.json +++ b/projectgraph/testdata/roots/library-surface/graph.golden.json @@ -84,7 +84,7 @@ "lib/test_api.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 5, "edges": 0, diff --git a/projectgraph/testdata/roots/main-guard/graph.golden.json b/projectgraph/testdata/roots/main-guard/graph.golden.json index 0fc5c998..0673501b 100644 --- a/projectgraph/testdata/roots/main-guard/graph.golden.json +++ b/projectgraph/testdata/roots/main-guard/graph.golden.json @@ -62,7 +62,7 @@ "lib.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 4, "edges": 1, diff --git a/projectgraph/testdata/roots/package-json-bin/graph.golden.json b/projectgraph/testdata/roots/package-json-bin/graph.golden.json index 1859dd4b..f2c54528 100644 --- a/projectgraph/testdata/roots/package-json-bin/graph.golden.json +++ b/projectgraph/testdata/roots/package-json-bin/graph.golden.json @@ -66,7 +66,7 @@ "lib/run.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 3, "edges": 2, diff --git a/projectgraph/testdata/roots/package-json-main/graph.golden.json b/projectgraph/testdata/roots/package-json-main/graph.golden.json index 4ab3c13a..da558b55 100644 --- a/projectgraph/testdata/roots/package-json-main/graph.golden.json +++ b/projectgraph/testdata/roots/package-json-main/graph.golden.json @@ -158,7 +158,7 @@ "parser.js": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 4, "nodes": 9, "edges": 3, diff --git a/projectgraph/testdata/roots/procfile-dockerfile/graph.golden.json b/projectgraph/testdata/roots/procfile-dockerfile/graph.golden.json index 210bb426..0dc095cf 100644 --- a/projectgraph/testdata/roots/procfile-dockerfile/graph.golden.json +++ b/projectgraph/testdata/roots/procfile-dockerfile/graph.golden.json @@ -114,7 +114,7 @@ "worker.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 6, "nodes": 7, "edges": 0, diff --git a/projectgraph/testdata/roots/pyproject-scripts/graph.golden.json b/projectgraph/testdata/roots/pyproject-scripts/graph.golden.json index a799a608..f26e273c 100644 --- a/projectgraph/testdata/roots/pyproject-scripts/graph.golden.json +++ b/projectgraph/testdata/roots/pyproject-scripts/graph.golden.json @@ -151,7 +151,7 @@ "src/app/tool.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 5, "nodes": 10, "edges": 0, diff --git a/projectgraph/testdata/roots/setup-py/graph.golden.json b/projectgraph/testdata/roots/setup-py/graph.golden.json index 0ad976ef..54508411 100644 --- a/projectgraph/testdata/roots/setup-py/graph.golden.json +++ b/projectgraph/testdata/roots/setup-py/graph.golden.json @@ -76,7 +76,7 @@ "tool/main.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 4, "edges": 0, diff --git a/projectgraph/testdata/roots/test-file/graph.golden.json b/projectgraph/testdata/roots/test-file/graph.golden.json index d355f567..9456863f 100644 --- a/projectgraph/testdata/roots/test-file/graph.golden.json +++ b/projectgraph/testdata/roots/test-file/graph.golden.json @@ -69,7 +69,7 @@ "tests/test_app.py": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 1, "nodes": 4, "edges": 0, diff --git a/projectgraph/testdata/typescript/js-specifier/graph.golden.json b/projectgraph/testdata/typescript/js-specifier/graph.golden.json index 22cb2426..de92b13e 100644 --- a/projectgraph/testdata/typescript/js-specifier/graph.golden.json +++ b/projectgraph/testdata/typescript/js-specifier/graph.golden.json @@ -84,7 +84,7 @@ "src/util.ts": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 2, "nodes": 3, "edges": 2, diff --git a/projectgraph/testdata/typescript/tsconfig-paths/graph.golden.json b/projectgraph/testdata/typescript/tsconfig-paths/graph.golden.json index c1e90122..41601674 100644 --- a/projectgraph/testdata/typescript/tsconfig-paths/graph.golden.json +++ b/projectgraph/testdata/typescript/tsconfig-paths/graph.golden.json @@ -141,7 +141,7 @@ "src/main.ts": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 5, "edges": 4, diff --git a/projectgraph/testdata/typescript/type-only/graph.golden.json b/projectgraph/testdata/typescript/type-only/graph.golden.json index a0be7328..2b8a3af9 100644 --- a/projectgraph/testdata/typescript/type-only/graph.golden.json +++ b/projectgraph/testdata/typescript/type-only/graph.golden.json @@ -100,7 +100,7 @@ "src/types.ts": "indexed" }, "stats": { - "version": "18", + "version": "19", "files": 3, "nodes": 5, "edges": 2, diff --git a/test/projectgraph/cases/go/dependency-build-files/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-build-files/summaries/go_github.com_acme_kit_v1.0.0.json index d887082e..b87df19c 100644 --- a/test/projectgraph/cases/go/dependency-build-files/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-build-files/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-callback/summaries/go_github.com_acme_srv_v1.0.0.json b/test/projectgraph/cases/go/dependency-callback/summaries/go_github.com_acme_srv_v1.0.0.json index b9294936..fe5ebda6 100644 --- a/test/projectgraph/cases/go/dependency-callback/summaries/go_github.com_acme_srv_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-callback/summaries/go_github.com_acme_srv_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/srv@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-data-reads/summaries/go_example.com_markup_v1.0.0.json b/test/projectgraph/cases/go/dependency-data-reads/summaries/go_example.com_markup_v1.0.0.json index bb22ae07..3367ae13 100644 --- a/test/projectgraph/cases/go/dependency-data-reads/summaries/go_example.com_markup_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-data-reads/summaries/go_example.com_markup_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:example.com/markup@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-data-reads/summaries/go_std_go1.25.1.json b/test/projectgraph/cases/go/dependency-data-reads/summaries/go_std_go1.25.1.json index 7c352d86..12040ab2 100644 --- a/test/projectgraph/cases/go/dependency-data-reads/summaries/go_std_go1.25.1.json +++ b/test/projectgraph/cases/go/dependency-data-reads/summaries/go_std_go1.25.1.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:std@go1.25.1", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-failed-callback/summaries/go_github.com_acme_srv_v1.0.0.json b/test/projectgraph/cases/go/dependency-failed-callback/summaries/go_github.com_acme_srv_v1.0.0.json index 45cfa721..d7ea90bb 100644 --- a/test/projectgraph/cases/go/dependency-failed-callback/summaries/go_github.com_acme_srv_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-failed-callback/summaries/go_github.com_acme_srv_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/srv@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_a_v1.0.0.json b/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_a_v1.0.0.json index f8674b04..da9cc6d1 100644 --- a/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_a_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_a_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/a@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_b_v1.0.0.json b/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_b_v1.0.0.json index be8b4d52..84bf2d3d 100644 --- a/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_b_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-function-table/summaries/go_github.com_acme_b_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/b@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-generated-code/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-generated-code/summaries/go_github.com_acme_kit_v1.0.0.json index 522906e2..989ceb3e 100644 --- a/test/projectgraph/cases/go/dependency-generated-code/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-generated-code/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-generated-table/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-generated-table/summaries/go_github.com_acme_kit_v1.0.0.json index acd42af3..69e5a026 100644 --- a/test/projectgraph/cases/go/dependency-generated-table/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-generated-table/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-implements-interface/summaries/go_github.com_acme_dep_v1.0.0.json b/test/projectgraph/cases/go/dependency-implements-interface/summaries/go_github.com_acme_dep_v1.0.0.json index ddf7042e..9048c967 100644 --- a/test/projectgraph/cases/go/dependency-implements-interface/summaries/go_github.com_acme_dep_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-implements-interface/summaries/go_github.com_acme_dep_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/dep@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-internal-call/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-internal-call/summaries/go_github.com_acme_kit_v1.0.0.json index 50b88ae8..b4d95adb 100644 --- a/test/projectgraph/cases/go/dependency-internal-call/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-internal-call/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-internal-package/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-internal-package/summaries/go_github.com_acme_kit_v1.0.0.json index 3e6c48d2..f2135c1e 100644 --- a/test/projectgraph/cases/go/dependency-internal-package/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-internal-package/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-module/summaries/go_github.com_acme_yamlish_v1.2.0.json b/test/projectgraph/cases/go/dependency-module/summaries/go_github.com_acme_yamlish_v1.2.0.json index e285c37d..b8911ade 100644 --- a/test/projectgraph/cases/go/dependency-module/summaries/go_github.com_acme_yamlish_v1.2.0.json +++ b/test/projectgraph/cases/go/dependency-module/summaries/go_github.com_acme_yamlish_v1.2.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/yamlish@v1.2.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-no-unit/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-no-unit/summaries/go_github.com_acme_kit_v1.0.0.json index aaa90ac4..222bc432 100644 --- a/test/projectgraph/cases/go/dependency-no-unit/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-no-unit/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-platform-files/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-platform-files/summaries/go_github.com_acme_kit_v1.0.0.json index 522906e2..989ceb3e 100644 --- a/test/projectgraph/cases/go/dependency-platform-files/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-platform-files/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-platform-results/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/dependency-platform-results/summaries/go_github.com_acme_kit_v1.0.0.json index d77e0b19..4504b1f5 100644 --- a/test/projectgraph/cases/go/dependency-platform-results/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-platform-results/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-result-types/summaries/go_example.com_markup_v1.0.0.json b/test/projectgraph/cases/go/dependency-result-types/summaries/go_example.com_markup_v1.0.0.json index 6e5f7d2e..f2a787c6 100644 --- a/test/projectgraph/cases/go/dependency-result-types/summaries/go_example.com_markup_v1.0.0.json +++ b/test/projectgraph/cases/go/dependency-result-types/summaries/go_example.com_markup_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:example.com/markup@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/dependency-result-types/summaries/go_std_go1.25.1.json b/test/projectgraph/cases/go/dependency-result-types/summaries/go_std_go1.25.1.json index ac5cfad1..6ac542fd 100644 --- a/test/projectgraph/cases/go/dependency-result-types/summaries/go_std_go1.25.1.json +++ b/test/projectgraph/cases/go/dependency-result-types/summaries/go_std_go1.25.1.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:std@go1.25.1", "symbols": [ { diff --git a/test/projectgraph/cases/go/panic-value/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/panic-value/summaries/go_github.com_acme_kit_v1.0.0.json index 3a3c78da..c165d791 100644 --- a/test/projectgraph/cases/go/panic-value/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/panic-value/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/plugin-lookup-std/summaries/go_std_go1.25.1.json b/test/projectgraph/cases/go/plugin-lookup-std/summaries/go_std_go1.25.1.json index f978ead0..5c50028c 100644 --- a/test/projectgraph/cases/go/plugin-lookup-std/summaries/go_std_go1.25.1.json +++ b/test/projectgraph/cases/go/plugin-lookup-std/summaries/go_std_go1.25.1.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:std@go1.25.1", "symbols": [ { diff --git a/test/projectgraph/cases/go/stdlib-callback-scope/summaries/go_github.com_acme_kit_v1.0.0.json b/test/projectgraph/cases/go/stdlib-callback-scope/summaries/go_github.com_acme_kit_v1.0.0.json index bcb0ba67..08655323 100644 --- a/test/projectgraph/cases/go/stdlib-callback-scope/summaries/go_github.com_acme_kit_v1.0.0.json +++ b/test/projectgraph/cases/go/stdlib-callback-scope/summaries/go_github.com_acme_kit_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/kit@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/go/stdlib-callback/summaries/go_github.com_acme_ws_v1.0.0.json b/test/projectgraph/cases/go/stdlib-callback/summaries/go_github.com_acme_ws_v1.0.0.json index 014417f5..27d42dbb 100644 --- a/test/projectgraph/cases/go/stdlib-callback/summaries/go_github.com_acme_ws_v1.0.0.json +++ b/test/projectgraph/cases/go/stdlib-callback/summaries/go_github.com_acme_ws_v1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "go:github.com/acme/ws@v1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/builtin-chain/summaries/npm_plug_1.0.0.json b/test/projectgraph/cases/javascript/builtin-chain/summaries/npm_plug_1.0.0.json index 7b95c886..c4c68898 100644 --- a/test/projectgraph/cases/javascript/builtin-chain/summaries/npm_plug_1.0.0.json +++ b/test/projectgraph/cases/javascript/builtin-chain/summaries/npm_plug_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:plug@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-candidates/summaries/npm_store-kit_1.0.0.json b/test/projectgraph/cases/javascript/dependency-candidates/summaries/npm_store-kit_1.0.0.json index b8b95a3f..a52e9868 100644 --- a/test/projectgraph/cases/javascript/dependency-candidates/summaries/npm_store-kit_1.0.0.json +++ b/test/projectgraph/cases/javascript/dependency-candidates/summaries/npm_store-kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:store-kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-exports-import/summaries/npm_kit_1.0.0.json b/test/projectgraph/cases/javascript/dependency-exports-import/summaries/npm_kit_1.0.0.json index b6fd33e3..c59cf4f8 100644 --- a/test/projectgraph/cases/javascript/dependency-exports-import/summaries/npm_kit_1.0.0.json +++ b/test/projectgraph/cases/javascript/dependency-exports-import/summaries/npm_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-exports-require/summaries/npm_kit_1.0.0.json b/test/projectgraph/cases/javascript/dependency-exports-require/summaries/npm_kit_1.0.0.json index b6fd33e3..c59cf4f8 100644 --- a/test/projectgraph/cases/javascript/dependency-exports-require/summaries/npm_kit_1.0.0.json +++ b/test/projectgraph/cases/javascript/dependency-exports-require/summaries/npm_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-method-name/summaries/npm_plug_1.0.0.json b/test/projectgraph/cases/javascript/dependency-method-name/summaries/npm_plug_1.0.0.json index fb9f4de1..a14fade4 100644 --- a/test/projectgraph/cases/javascript/dependency-method-name/summaries/npm_plug_1.0.0.json +++ b/test/projectgraph/cases/javascript/dependency-method-name/summaries/npm_plug_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:plug@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-same-path/summaries/npm_util-kit_1.0.0.json b/test/projectgraph/cases/javascript/dependency-same-path/summaries/npm_util-kit_1.0.0.json index ff8dc49b..2e8d0346 100644 --- a/test/projectgraph/cases/javascript/dependency-same-path/summaries/npm_util-kit_1.0.0.json +++ b/test/projectgraph/cases/javascript/dependency-same-path/summaries/npm_util-kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:util-kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash._reinterpolate_3.0.0.json b/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash._reinterpolate_3.0.0.json index 6da5f9d8..f3b26e6c 100644 --- a/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash._reinterpolate_3.0.0.json +++ b/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash._reinterpolate_3.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:lodash._reinterpolate@3.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash_4.17.21.json b/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash_4.17.21.json index a10bbbcc..584208a0 100644 --- a/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash_4.17.21.json +++ b/test/projectgraph/cases/javascript/dependency-transitive/summaries/npm_lodash_4.17.21.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "npm:lodash@4.17.21", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-compiled-module/summaries/pypi_speedy_1.0.0.json b/test/projectgraph/cases/python/dependency-compiled-module/summaries/pypi_speedy_1.0.0.json index 78254678..0d53d13f 100644 --- a/test/projectgraph/cases/python/dependency-compiled-module/summaries/pypi_speedy_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-compiled-module/summaries/pypi_speedy_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:speedy@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-dark-unit-record/summaries/pypi_PyYAML_6.0.1.json b/test/projectgraph/cases/python/dependency-dark-unit-record/summaries/pypi_PyYAML_6.0.1.json index c185c149..0a8677f0 100644 --- a/test/projectgraph/cases/python/dependency-dark-unit-record/summaries/pypi_PyYAML_6.0.1.json +++ b/test/projectgraph/cases/python/dependency-dark-unit-record/summaries/pypi_PyYAML_6.0.1.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:PyYAML@6.0.1", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-dark-unit/summaries/pypi_PyYAML_6.0.1.json b/test/projectgraph/cases/python/dependency-dark-unit/summaries/pypi_PyYAML_6.0.1.json index 2fd267bc..71bf9342 100644 --- a/test/projectgraph/cases/python/dependency-dark-unit/summaries/pypi_PyYAML_6.0.1.json +++ b/test/projectgraph/cases/python/dependency-dark-unit/summaries/pypi_PyYAML_6.0.1.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:PyYAML@6.0.1", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_badpkg_1.0.0.json b/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_badpkg_1.0.0.json index b82d1f86..65724707 100644 --- a/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_badpkg_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_badpkg_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:badpkg@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_okpkg_1.0.0.json b/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_okpkg_1.0.0.json index 571e973e..c6085da1 100644 --- a/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_okpkg_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-failed-reached/summaries/pypi_okpkg_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:okpkg@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_badpkg_1.0.0.json b/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_badpkg_1.0.0.json index b82d1f86..65724707 100644 --- a/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_badpkg_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_badpkg_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:badpkg@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_okpkg_1.0.0.json b/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_okpkg_1.0.0.json index 571e973e..c6085da1 100644 --- a/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_okpkg_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-failed-unreached/summaries/pypi_okpkg_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:okpkg@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-auth_2.0.0.json b/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-auth_2.0.0.json index cb2b0b6b..9a94e4f5 100644 --- a/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-auth_2.0.0.json +++ b/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-auth_2.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:google-auth@2.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-cloud-storage_2.1.0.json b/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-cloud-storage_2.1.0.json index c7329383..312a4125 100644 --- a/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-cloud-storage_2.1.0.json +++ b/test/projectgraph/cases/python/dependency-namespace-two-dists/summaries/pypi_google-cloud-storage_2.1.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:google-cloud-storage@2.1.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-package-dir/summaries/pypi_outer_1.0.0.json b/test/projectgraph/cases/python/dependency-package-dir/summaries/pypi_outer_1.0.0.json index 65c4753a..ec7f1191 100644 --- a/test/projectgraph/cases/python/dependency-package-dir/summaries/pypi_outer_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-package-dir/summaries/pypi_outer_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:outer@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-record-import-name/summaries/pypi_PyYAML_6.0.1.json b/test/projectgraph/cases/python/dependency-record-import-name/summaries/pypi_PyYAML_6.0.1.json index 2fd267bc..71bf9342 100644 --- a/test/projectgraph/cases/python/dependency-record-import-name/summaries/pypi_PyYAML_6.0.1.json +++ b/test/projectgraph/cases/python/dependency-record-import-name/summaries/pypi_PyYAML_6.0.1.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:PyYAML@6.0.1", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_requests_2.31.0.json b/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_requests_2.31.0.json index a22d03c2..18461637 100644 --- a/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_requests_2.31.0.json +++ b/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_requests_2.31.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:requests@2.31.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_urllib3_2.0.7.json b/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_urllib3_2.0.7.json index f7671ddd..22b9b6ff 100644 --- a/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_urllib3_2.0.7.json +++ b/test/projectgraph/cases/python/dependency-site-packages/summaries/pypi_urllib3_2.0.7.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:urllib3@2.0.7", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-stdlib/summaries/python_std_3.12.3.json b/test/projectgraph/cases/python/dependency-stdlib/summaries/python_std_3.12.3.json index a8ed36ca..720fcc94 100644 --- a/test/projectgraph/cases/python/dependency-stdlib/summaries/python_std_3.12.3.json +++ b/test/projectgraph/cases/python/dependency-stdlib/summaries/python_std_3.12.3.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "python:std@3.12.3", "symbols": [ { diff --git a/test/projectgraph/cases/python/dependency-typed-return/summaries/pypi_dep_1.0.0.json b/test/projectgraph/cases/python/dependency-typed-return/summaries/pypi_dep_1.0.0.json index 33e4eca4..4021d152 100644 --- a/test/projectgraph/cases/python/dependency-typed-return/summaries/pypi_dep_1.0.0.json +++ b/test/projectgraph/cases/python/dependency-typed-return/summaries/pypi_dep_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:dep@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/python/typed-base-subclass/summaries/pypi_dep_1.0.0.json b/test/projectgraph/cases/python/typed-base-subclass/summaries/pypi_dep_1.0.0.json index 33e4eca4..4021d152 100644 --- a/test/projectgraph/cases/python/typed-base-subclass/summaries/pypi_dep_1.0.0.json +++ b/test/projectgraph/cases/python/typed-base-subclass/summaries/pypi_dep_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "pypi:dep@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/crate-bindings/summaries/cargo_kit_1.0.0.json b/test/projectgraph/cases/rust/crate-bindings/summaries/cargo_kit_1.0.0.json index 49d0517f..3e168d70 100644 --- a/test/projectgraph/cases/rust/crate-bindings/summaries/cargo_kit_1.0.0.json +++ b/test/projectgraph/cases/rust/crate-bindings/summaries/cargo_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/dependency-crate/summaries/cargo_kit_1.0.0.json b/test/projectgraph/cases/rust/dependency-crate/summaries/cargo_kit_1.0.0.json index 0fc6f041..1ef40a7f 100644 --- a/test/projectgraph/cases/rust/dependency-crate/summaries/cargo_kit_1.0.0.json +++ b/test/projectgraph/cases/rust/dependency-crate/summaries/cargo_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/dependency-internal-call/summaries/cargo_kit_1.0.0.json b/test/projectgraph/cases/rust/dependency-internal-call/summaries/cargo_kit_1.0.0.json index 8308d1c4..d5029bbf 100644 --- a/test/projectgraph/cases/rust/dependency-internal-call/summaries/cargo_kit_1.0.0.json +++ b/test/projectgraph/cases/rust/dependency-internal-call/summaries/cargo_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/dependency-renamed/summaries/cargo_kit_1.0.0.json b/test/projectgraph/cases/rust/dependency-renamed/summaries/cargo_kit_1.0.0.json index 8308d1c4..d5029bbf 100644 --- a/test/projectgraph/cases/rust/dependency-renamed/summaries/cargo_kit_1.0.0.json +++ b/test/projectgraph/cases/rust/dependency-renamed/summaries/cargo_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/glob-use-many/expect.yaml b/test/projectgraph/cases/rust/glob-use-many/expect.yaml new file mode 100644 index 00000000..aa5d7059 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-many/expect.yaml @@ -0,0 +1,55 @@ +source: safedep:hand +description: >- + src/sys.rs has eight glob uses, as src/sys.rs of time 0.1.45 has. The glob use of the module inner + brings now of the inline module unix into scope through a second glob use, so main calls + sys::now, and std::fs::remove_file is found. The six glob uses of crates in unix and the two in mac + name no crate that the project gives. The lookup of each name that the file does not define reads + the glob uses of the file, and the resolution of each glob use walks the file again. A link step + that resolves the glob uses again on each such read does work that grows with the orders of the + eight glob uses, and the case does not end. The calls of names that only a glob use of a crate can + bring stay records. +roots: + - key: src/main.rs + kind: main + rule: rust.main + - key: src/main.rs//main + kind: main + rule: rust.main +exact_edges: true +edges: + - from: src/main.rs//main + to: src/sys.rs//inner//unix//now + kind: direct + confidence: high + site: src/main.rs:4 + - from: src/sys.rs//inner//unix//now + to: std//fs//remove_file + kind: direct + confidence: high + site: src/sys.rs:26 +unresolved: + - caller: src/sys.rs//inner//mac//ticks + site: src/sys.rs:12 + reason: unknown-receiver + method: mach_absolute_time + - caller: src/sys.rs//inner//unix//now + site: src/sys.rs:25 + reason: unknown-receiver + method: clock_gettime +results: + - target: std//fs//remove_file + status: found + path: + - key: src/main.rs//main + - key: src/sys.rs//inner//unix//now + site: src/main.rs:4 + kind: direct + confidence: high + - key: std//fs//remove_file + site: src/sys.rs:26 + kind: direct + confidence: high + call_sites: + - caller: src/sys.rs//inner//unix//now + site: src/sys.rs:26 + reached: true diff --git a/test/projectgraph/cases/rust/glob-use-many/project/Cargo.toml b/test/projectgraph/cases/rust/glob-use-many/project/Cargo.toml new file mode 100644 index 00000000..0d44349a --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-many/project/Cargo.toml @@ -0,0 +1,4 @@ +[package] +name = "app" +version = "0.1.0" +edition = "2021" diff --git a/test/projectgraph/cases/rust/glob-use-many/project/src/main.rs b/test/projectgraph/cases/rust/glob-use-many/project/src/main.rs new file mode 100644 index 00000000..bc8c370c --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-many/project/src/main.rs @@ -0,0 +1,5 @@ +mod sys; + +fn main() { + sys::now(); +} diff --git a/test/projectgraph/cases/rust/glob-use-many/project/src/sys.rs b/test/projectgraph/cases/rust/glob-use-many/project/src/sys.rs new file mode 100644 index 00000000..e71c8466 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-many/project/src/sys.rs @@ -0,0 +1,29 @@ +pub use self::inner::*; + +mod inner { + pub use self::mac::*; + pub use self::unix::*; + + mod mac { + use libc::mach::*; + use libc::time::*; + + pub fn ticks() -> u64 { + mach_absolute_time() + } + } + + mod unix { + use libc::clock::*; + use libc::posix::*; + use libc::signal::*; + use libc::stat::*; + use libc::types::*; + use libc::wait::*; + + pub fn now() { + clock_gettime(); + let _ = std::fs::remove_file("x"); + } + } +} diff --git a/test/projectgraph/cases/rust/glob-use/summaries/cargo_dep_1.2.0.json b/test/projectgraph/cases/rust/glob-use/summaries/cargo_dep_1.2.0.json index a88279ec..9e9f91b1 100644 --- a/test/projectgraph/cases/rust/glob-use/summaries/cargo_dep_1.2.0.json +++ b/test/projectgraph/cases/rust/glob-use/summaries/cargo_dep_1.2.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:dep@1.2.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/into-dependency/summaries/cargo_kit_1.0.0.json b/test/projectgraph/cases/rust/into-dependency/summaries/cargo_kit_1.0.0.json index 6fac9200..61ee1f2d 100644 --- a/test/projectgraph/cases/rust/into-dependency/summaries/cargo_kit_1.0.0.json +++ b/test/projectgraph/cases/rust/into-dependency/summaries/cargo_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/library-build-script/summaries/cargo_kit_1.0.0.json b/test/projectgraph/cases/rust/library-build-script/summaries/cargo_kit_1.0.0.json index 1109a3ed..892b7283 100644 --- a/test/projectgraph/cases/rust/library-build-script/summaries/cargo_kit_1.0.0.json +++ b/test/projectgraph/cases/rust/library-build-script/summaries/cargo_kit_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:kit@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/macro-import/summaries/cargo_dep_1.2.0.json b/test/projectgraph/cases/rust/macro-import/summaries/cargo_dep_1.2.0.json index 48a89996..58d56bc3 100644 --- a/test/projectgraph/cases/rust/macro-import/summaries/cargo_dep_1.2.0.json +++ b/test/projectgraph/cases/rust/macro-import/summaries/cargo_dep_1.2.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:dep@1.2.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/trait-object-shadowed/summaries/cargo_dep_1.2.0.json b/test/projectgraph/cases/rust/trait-object-shadowed/summaries/cargo_dep_1.2.0.json index 7eca2165..a0c68e22 100644 --- a/test/projectgraph/cases/rust/trait-object-shadowed/summaries/cargo_dep_1.2.0.json +++ b/test/projectgraph/cases/rust/trait-object-shadowed/summaries/cargo_dep_1.2.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:dep@1.2.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/trait-object/summaries/cargo_dep_1.2.0.json b/test/projectgraph/cases/rust/trait-object/summaries/cargo_dep_1.2.0.json index a74e9419..37ffff09 100644 --- a/test/projectgraph/cases/rust/trait-object/summaries/cargo_dep_1.2.0.json +++ b/test/projectgraph/cases/rust/trait-object/summaries/cargo_dep_1.2.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:dep@1.2.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/use-binding-path/summaries/cargo_dep_1.0.0.json b/test/projectgraph/cases/rust/use-binding-path/summaries/cargo_dep_1.0.0.json index beaba435..5bdf2f40 100644 --- a/test/projectgraph/cases/rust/use-binding-path/summaries/cargo_dep_1.0.0.json +++ b/test/projectgraph/cases/rust/use-binding-path/summaries/cargo_dep_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:dep@1.0.0", "symbols": [ { diff --git a/test/projectgraph/cases/rust/use-dependency-item/summaries/cargo_dep_1.0.0.json b/test/projectgraph/cases/rust/use-dependency-item/summaries/cargo_dep_1.0.0.json index f209d93e..ed1c0b55 100644 --- a/test/projectgraph/cases/rust/use-dependency-item/summaries/cargo_dep_1.0.0.json +++ b/test/projectgraph/cases/rust/use-dependency-item/summaries/cargo_dep_1.0.0.json @@ -1,7 +1,7 @@ { "version": "3", "index_version": "16", - "link_version": "18", + "link_version": "19", "unit": "cargo:dep@1.0.0", "symbols": [ { diff --git a/test/projectgraph/version_test.go b/test/projectgraph/version_test.go index 78446241..2d4bd847 100644 --- a/test/projectgraph/version_test.go +++ b/test/projectgraph/version_test.go @@ -33,6 +33,7 @@ var graphHashes = map[string]string{ "14/16": "823b1f82c4aed8ba27d19275505c8d1dee755086be48fcda64d323f55b4c62a5", "15/17": "d823ce8ba221c534ab062f7e48abfe91d1c90d50b2a2fdb00d41183dc0e9da09", "16/18": "bb92620bf9903e8d19b52b62198a0bfd69d67856f9db226112b2cedf537b312b", + "16/19": "549a5a1d06d56a5486327a2ebdacbff3ed31c84ab32831b8a88f3361d5631122", } // resultHashes records the hash of the reach results of every case for @@ -50,6 +51,7 @@ var resultHashes = map[string]string{ "14/16/3": "13b6eecb686ddec3c2ba470fc9752ea66cff445d5e18e0772a71b15ae7fe1c9c", "15/17/4": "1b32d7c1dbb0a4637853eb7a00b0db91a0a4e1a31f221b37ed0d0654a66ed13e", "16/18/5": "e0c6093df3a85353ee15c8a90ef7c2a441f23348ce80c9d49793c256bddeffc5", + "16/19/5": "b5fd9465c0ae869e3b7d9595221940882f8484c1bc9c2eb375a86f701b02c734", } // summaryHashes records the hash of the golden summaries of the cases for @@ -68,6 +70,7 @@ var summaryHashes = map[string]string{ "14/16/2": "fb678202978212aae932e50a56a0d3dc7f0f794ce908988bf605ce9a6e04bc51", "15/17/2": "00a6bd5871f70459a617079f431939ef7c92e4b3f360013c1dedd017fe1146be", "16/18/3": "694efb5f72075356359031d449d7b4ecbdca2ddd5099dacbcd2adad745ac6e19", + "16/19/3": "13c72bf9eb60fc0a38bc600906fc02028d5cb60cb2aefbec0f0721779c429d80", } func TestGraphHashFollowsVersion(t *testing.T) { From 7e6b8cce6584b5cc87e75410f0b3edea5757233a Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 15 Nov 2026 08:20:08 +0000 Subject: [PATCH 2/5] fix(projectgraph): keep no table of the wildcard modules of a scope The table of the modules of the wildcard imports of each scope kept a list that a resolution gave under the resolving guard of a Rust path. app/src/prelude.rs has pub use core_lib::*. The link step resolved the path core_lib of that glob use, walked the unit of the file, and read its glob use again. The guard gave no module there, and the table kept the empty list for the whole build. A call of crate::prelude::helper then went to the external key crate//prelude//helper with no record, and a target under helper read not-found. wildcardModules now keeps the modules only while a resolution reads the scope. A read of that scope gets the modules of the last whole pass, and the passes repeat until the modules stay the same. The single file with many glob uses stays fast, as each nested read of the scope gets the modules of the pass at once. A fuzz of 1500 generated crates gives the same graph as the code before the table. The table gave 24 graphs that differ. The case rust/glob-use-workspace-crate fails with the table. With projectgraph.Version at 18 and the two new cases out, the graph and result hashes of the cases are those of 16/18 and 16/18/5. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01PFQbqPqd9xn1fT6hBsyoUm Signed-off-by: Claude --- projectgraph/link.go | 11 +-- projectgraph/resolve.go | 75 +++++++++---------- .../rust/glob-use-workspace-crate/expect.yaml | 54 +++++++++++++ .../project/Cargo.toml | 2 + .../project/app/Cargo.toml | 7 ++ .../project/app/src/main.rs | 6 ++ .../project/app/src/prelude.rs | 1 + .../project/app/src/work.rs | 3 + .../project/core_lib/Cargo.toml | 7 ++ .../project/core_lib/src/lib.rs | 3 + test/projectgraph/version_test.go | 4 +- 11 files changed, 123 insertions(+), 50 deletions(-) create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/expect.yaml create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/Cargo.toml create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/Cargo.toml create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/main.rs create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/prelude.rs create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/work.rs create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/Cargo.toml create mode 100644 test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/src/lib.rs diff --git a/projectgraph/link.go b/projectgraph/link.go index c6cc1a7e..d9419eed 100644 --- a/projectgraph/link.go +++ b/projectgraph/link.go @@ -134,12 +134,9 @@ type builder struct { // walk of a unit reads now for the result type of an external key. reading map[string]bool stepping map[nameKey]bool - // wildcardMods holds the modules of the wildcard imports of each scope. - // wildcardDepth and wildcardLow track the scopes whose modules a - // resolution reads now, as wildcardModules describes. - wildcardMods map[*scope]*wildcardModules - wildcardDepth int - wildcardLow int + // expanding holds the scopes whose wildcard imports a resolution reads + // now, with the modules of the last whole pass. + expanding map[*scope]*wildcardRead // unitTypes holds the type that a unit of dependency code gives for // each external key, or "". unitTypes map[string]string @@ -280,7 +277,7 @@ func newTables(indexes []*fileindex.Index, opts Options) *builder { defs: make(map[string]*fileindex.Definition, defs), reading: map[string]bool{}, stepping: map[nameKey]bool{}, - wildcardMods: map[*scope]*wildcardModules{}, + expanding: map[*scope]*wildcardRead{}, unitTypes: map[string]string{}, findingBases: map[string]bool{}, state: map[langcode.Code]any{}, diff --git a/projectgraph/resolve.go b/projectgraph/resolve.go index 010fa5dd..5727f6d5 100644 --- a/projectgraph/resolve.go +++ b/projectgraph/resolve.go @@ -472,8 +472,9 @@ func (b *builder) resolveScope(sc *scope, caller, target string) []resolution { } // wildcardImported returns the definitions of the name in the packages -// that the file imports with a Go dot import or a Java wildcard import, and -// the members of the name in the classes of a Java static wildcard import. +// that the file imports with a Go dot import, a Java wildcard import or a +// Rust glob use, and the members of the name in the classes of a Java +// static wildcard import. // A Java wildcard import of a package of the project names its class // exactly, so its edge is direct. func (b *builder) wildcardImported(sc *scope, name string) []string { @@ -491,62 +492,54 @@ func (b *builder) wildcardImported(sc *scope, name string) []string { return keys } -// wildcardModules holds the modules of the wildcard imports of a scope. -// depth is the depth of the scope among the scopes that a resolution reads -// now, or 0 when the modules are whole. read marks a pass whose -// resolutions read the modules of the scope itself. -type wildcardModules struct { - mods []string - depth int - read bool +// wildcardRead is a read of the wildcard imports of a scope that a +// resolution makes now. mods holds the modules of the last whole pass, and +// read marks a pass whose resolutions read the same scope again. +type wildcardRead struct { + mods []string + read bool } // wildcardModules returns the modules of the wildcard imports of a scope, // in the order of the imports. The resolution of a module can walk a unit // whose name lookup reads the wildcard imports of the same scope, as the -// eight glob uses of src/sys.rs of time 0.1.45 do. Without the table each -// such lookup resolves every import again, and the work grows with the -// orders of the imports. +// eight glob uses of src/sys.rs of time 0.1.45 do. If each such read +// resolved every import again, the work would grow with the orders of the +// imports, and the link step of a project with that file would not end. // -// A read of a scope that a resolution reads now gets the modules of the -// last whole pass. So the passes repeat until the modules stay the same, -// and a module that only an import after it brings into scope resolves. -// The table keeps no modules that read a scope further up the chain. Such -// a chain of scopes across files resolves again on each read. +// So a read of a scope that a resolution reads now gets the modules of the +// last whole pass, and the passes repeat until the modules stay the same. +// A module that only an import after it brings into scope thus resolves. +// No table keeps the modules after the read. A resolution under the +// resolving guard of a Rust path gives a part of the modules, and a table +// would keep that part for the whole build. +// +// A cycle of wildcard imports across files still costs time that grows +// with the number of files. A file that each other file of the cycle reads +// with a glob use of a name that no file defines is such a cycle. func (b *builder) wildcardModules(sc *scope) []string { - if w := b.wildcardMods[sc]; w != nil { - if w.depth > 0 { - w.read = true - b.wildcardLow = min(b.wildcardLow, w.depth) - } - return w.mods - } - b.wildcardDepth++ - w := &wildcardModules{depth: b.wildcardDepth} - b.wildcardMods[sc] = w - outer := b.wildcardLow - b.wildcardLow = w.depth + if r := b.expanding[sc]; r != nil { + r.read = true + return r.mods + } + r := &wildcardRead{} + b.expanding[sc] = r + defer delete(b.expanding, sc) for range len(sc.wildcards) + 1 { - w.read = false + r.read = false var mods []string for _, imp := range sc.wildcards { if mod, _, ok := b.resolveModule(sc.ix, imp.Module); ok { mods = append(mods, mod) } } - same := slices.Equal(mods, w.mods) - w.mods = mods - if !w.read || same { + same := slices.Equal(mods, r.mods) + r.mods = mods + if !r.read || same { break } } - b.wildcardDepth-- - if b.wildcardLow < w.depth { - delete(b.wildcardMods, sc) - } - w.depth = 0 - b.wildcardLow = min(outer, b.wildcardLow) - return w.mods + return r.mods } // superKeyword is the receiver of a call of a method of the base class, as diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/expect.yaml b/test/projectgraph/cases/rust/glob-use-workspace-crate/expect.yaml new file mode 100644 index 00000000..979251b6 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/expect.yaml @@ -0,0 +1,54 @@ +source: safedep:hand +description: >- + The workspace has the crates app and core_lib. app/src/prelude.rs has pub use core_lib::*, and + run in app/src/work.rs calls crate::prelude::helper. helper of core_lib calls dep::danger, so + dep::danger is found. The link step reads the glob use of prelude.rs while it resolves the path + core_lib of that same glob use. The guard of that resolution gives no module for the glob use at + that point. A link step that keeps such a list of modules for the whole build sends the call to + the external key crate//prelude//helper with no record, and dep::danger reads not-found. +roots: + - key: app/src/main.rs + kind: main + rule: rust.main + - key: app/src/main.rs//main + kind: main + rule: rust.main +exact_edges: true +edges: + - from: app/src/main.rs//main + to: app/src/work.rs//run + kind: direct + confidence: high + site: app/src/main.rs:5 + - from: app/src/work.rs//run + to: core_lib/src/lib.rs//helper + kind: direct + confidence: high + site: app/src/work.rs:2 + - from: core_lib/src/lib.rs//helper + to: dep//danger + kind: direct + confidence: high + site: core_lib/src/lib.rs:2 +unresolved: [] +results: + - target: dep//danger + status: found + path: + - key: app/src/main.rs//main + - key: app/src/work.rs//run + site: app/src/main.rs:5 + kind: direct + confidence: high + - key: core_lib/src/lib.rs//helper + site: app/src/work.rs:2 + kind: direct + confidence: high + - key: dep//danger + site: core_lib/src/lib.rs:2 + kind: direct + confidence: high + call_sites: + - caller: core_lib/src/lib.rs//helper + site: core_lib/src/lib.rs:2 + reached: true diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/Cargo.toml b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/Cargo.toml new file mode 100644 index 00000000..b5eaf363 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/Cargo.toml @@ -0,0 +1,2 @@ +[workspace] +members = ["app", "core_lib"] diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/Cargo.toml b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/Cargo.toml new file mode 100644 index 00000000..110f096f --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/Cargo.toml @@ -0,0 +1,7 @@ +[package] +name = "app" +version = "0.1.0" +edition = "2021" + +[dependencies] +core_lib = { path = "../core_lib" } diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/main.rs b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/main.rs new file mode 100644 index 00000000..27d9ee8f --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/main.rs @@ -0,0 +1,6 @@ +mod prelude; +mod work; + +fn main() { + work::run(); +} diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/prelude.rs b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/prelude.rs new file mode 100644 index 00000000..ce2e50e4 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/prelude.rs @@ -0,0 +1 @@ +pub use core_lib::*; diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/work.rs b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/work.rs new file mode 100644 index 00000000..c25f0736 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/app/src/work.rs @@ -0,0 +1,3 @@ +pub fn run() { + crate::prelude::helper(); +} diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/Cargo.toml b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/Cargo.toml new file mode 100644 index 00000000..29ce900c --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/Cargo.toml @@ -0,0 +1,7 @@ +[package] +name = "core_lib" +version = "0.1.0" +edition = "2021" + +[dependencies] +dep = "1.0.0" diff --git a/test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/src/lib.rs b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/src/lib.rs new file mode 100644 index 00000000..1a000e8c --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-workspace-crate/project/core_lib/src/lib.rs @@ -0,0 +1,3 @@ +pub fn helper() { + dep::danger(); +} diff --git a/test/projectgraph/version_test.go b/test/projectgraph/version_test.go index 2d4bd847..a056f44c 100644 --- a/test/projectgraph/version_test.go +++ b/test/projectgraph/version_test.go @@ -33,7 +33,7 @@ var graphHashes = map[string]string{ "14/16": "823b1f82c4aed8ba27d19275505c8d1dee755086be48fcda64d323f55b4c62a5", "15/17": "d823ce8ba221c534ab062f7e48abfe91d1c90d50b2a2fdb00d41183dc0e9da09", "16/18": "bb92620bf9903e8d19b52b62198a0bfd69d67856f9db226112b2cedf537b312b", - "16/19": "549a5a1d06d56a5486327a2ebdacbff3ed31c84ab32831b8a88f3361d5631122", + "16/19": "8d9b986814d74ff539a1a3e7d808a8ce8afff886040cbab890d3ee071cd99d8d", } // resultHashes records the hash of the reach results of every case for @@ -51,7 +51,7 @@ var resultHashes = map[string]string{ "14/16/3": "13b6eecb686ddec3c2ba470fc9752ea66cff445d5e18e0772a71b15ae7fe1c9c", "15/17/4": "1b32d7c1dbb0a4637853eb7a00b0db91a0a4e1a31f221b37ed0d0654a66ed13e", "16/18/5": "e0c6093df3a85353ee15c8a90ef7c2a441f23348ce80c9d49793c256bddeffc5", - "16/19/5": "b5fd9465c0ae869e3b7d9595221940882f8484c1bc9c2eb375a86f701b02c734", + "16/19/5": "a11bd5ddff2a96ccaebeccf4f449f85d9b34ade8dd3f59d5763e3d021a1ffd34", } // summaryHashes records the hash of the golden summaries of the cases for From c70236e2cc44ed5c1db5e7612952b9ba77ca36da Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 15 Nov 2026 13:33:01 +0000 Subject: [PATCH 3/5] fix(projectgraph): stop the link step inside a file when the context ends Build checked its context only between files. A cycle of glob uses across Rust files makes the resolutions of one file grow with the orders of the files, so a build with a deadline ran on for minutes or hours past it. A scan gives the link step a budget, and the budget did not stop it. Build now sets a stop flag when its context ends. Each step of a walk and each read of the wildcard imports of a scope end at once on the flag. Build checks the context again before it returns a graph, so the graph of a stopped build goes to no caller. TestBuildStopsAtTheDeadline links ten files that glob use one another with a deadline of 200 ms. The build ends in about 0.2 s. Without the flag the test ran for more than two minutes. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01PFQbqPqd9xn1fT6hBsyoUm Signed-off-by: Claude --- projectgraph/link.go | 12 +++++++ projectgraph/resolve.go | 3 ++ projectgraph/walk.go | 3 ++ test/projectgraph/deadline_test.go | 56 ++++++++++++++++++++++++++++++ 4 files changed, 74 insertions(+) create mode 100644 test/projectgraph/deadline_test.go diff --git a/projectgraph/link.go b/projectgraph/link.go index d9419eed..360ff820 100644 --- a/projectgraph/link.go +++ b/projectgraph/link.go @@ -7,6 +7,7 @@ import ( "io/fs" "slices" "strings" + "sync/atomic" "time" "github.com/safedep/code/fileindex" @@ -78,12 +79,18 @@ func Build(ctx context.Context, indexes []*fileindex.Index, opts Options) (*Grap if err != nil { return nil, err } + defer context.AfterFunc(ctx, func() { b.stopped.Store(true) })() if err := b.linkAll(ctx); err != nil { return nil, err } if err := b.markRoots(ctx); err != nil { return nil, err } + // A stop cuts the resolutions short, so the graph of a stopped build + // lacks edges and goes to no caller. + if err := ctx.Err(); err != nil { + return nil, err + } g := b.finish() g.Stats.Duration = time.Since(start) return g, nil @@ -137,6 +144,11 @@ type builder struct { // expanding holds the scopes whose wildcard imports a resolution reads // now, with the modules of the last whole pass. expanding map[*scope]*wildcardRead + // stopped marks a build whose context ended. The walk and the reads of + // wildcard imports then end at once. A context check only between files + // lets the resolutions of one file run on past the budget of the caller, + // and a cycle of glob uses can keep them running for hours. + stopped atomic.Bool // unitTypes holds the type that a unit of dependency code gives for // each external key, or "". unitTypes map[string]string diff --git a/projectgraph/resolve.go b/projectgraph/resolve.go index 5727f6d5..177a23c5 100644 --- a/projectgraph/resolve.go +++ b/projectgraph/resolve.go @@ -518,6 +518,9 @@ type wildcardRead struct { // with the number of files. A file that each other file of the cycle reads // with a glob use of a name that no file defines is such a cycle. func (b *builder) wildcardModules(sc *scope) []string { + if b.stopped.Load() { + return nil + } if r := b.expanding[sc]; r != nil { r.read = true return r.mods diff --git a/projectgraph/walk.go b/projectgraph/walk.go index 0d29fd49..46e4bf69 100644 --- a/projectgraph/walk.go +++ b/projectgraph/walk.go @@ -57,6 +57,9 @@ func (b *builder) walkFrom(r resolution, names []string) resolution { instance := r.virtual for i := 0; i < len(names); { name := names[i] + if b.stopped.Load() { + return resolution{fail: &failure{reason: fileindex.UnresolvedLimit, name: name, cut: true}} + } var consumed, done bool switch kind := b.kindOf(r.key); { case b.units[r.key] != nil: diff --git a/test/projectgraph/deadline_test.go b/test/projectgraph/deadline_test.go new file mode 100644 index 00000000..4dd72c1c --- /dev/null +++ b/test/projectgraph/deadline_test.go @@ -0,0 +1,56 @@ +package projectgraph + +import ( + "context" + "fmt" + "os" + "path/filepath" + "strings" + "testing" + "time" + + codefs "github.com/safedep/code/fs" + "github.com/safedep/code/plugin/indexer" + "github.com/safedep/code/projectgraph" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" +) + +// TestBuildStopsAtTheDeadline links ten Rust files that each glob use a +// name of every other file that no file defines. Each lookup of a name that +// a file does not define walks the glob uses of the other files, and the +// work grows with the orders of the files. The build must end soon after +// its deadline, as a scan gives the link step a budget. +func TestBuildStopsAtTheDeadline(t *testing.T) { + const files = 10 + dir := t.TempDir() + write := func(name, text string) { + require.NoError(t, os.MkdirAll(filepath.Dir(filepath.Join(dir, name)), 0o755)) + require.NoError(t, os.WriteFile(filepath.Join(dir, name), []byte(text), 0o644)) + } + write("Cargo.toml", "[package]\nname = \"app\"\nversion = \"0.1.0\"\n") + var lib strings.Builder + for i := range files { + fmt.Fprintf(&lib, "pub mod f%d;\n", i) + var file strings.Builder + for j := range files { + if j != i { + fmt.Fprintf(&file, "pub use crate::f%d::E::*;\n", j) + } + } + file.WriteString("pub fn run() {\n missing();\n}\n") + write(fmt.Sprintf("src/f%d.rs", i), file.String()) + } + write("src/lib.rs", lib.String()) + + fsys, err := codefs.NewLocalFileSystem(codefs.LocalFileSystemConfig{AppDirectories: []string{dir}}) + require.NoError(t, err) + indexed := indexProject(t, fsys, indexer.Options{Languages: caseLanguages(t)}) + + ctx, cancel := context.WithTimeout(context.Background(), 200*time.Millisecond) + defer cancel() + start := time.Now() + _, err = projectgraph.Build(ctx, indexed.Indexes, projectgraph.Options{Root: os.DirFS(dir), Files: indexed.Statuses(), Languages: indexed.Languages}) + assert.ErrorIs(t, err, context.DeadlineExceeded) + assert.Less(t, time.Since(start), 10*time.Second) +} From 10a3388e25ff016ae79decb807ea9cca71ca085c Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 15 Nov 2026 16:06:10 +0000 Subject: [PATCH 4/5] perf(projectgraph): keep the wildcard modules of a scope that no guard cut wildcardModules resolved the wildcard imports of a scope again on each read. src/sys.rs of time 0.1.45 has eight glob uses, and the link step of the lettre_email project read them 12,000 times in 1.6 s. A table now keeps the modules of a scope. The earlier table kept a list that the resolving guard of a Rust path had cut, and a target read not-found. So one check, uncut, decides both the store and the hit. A read records each path that it asks the resolving guard for. uncut holds when no such path is in progress, and no other cycle guard, MRO lookup or read of wildcard imports is in progress. At the end of a read the paths in progress are those from before the read, so a recorded path among them means that the guard cut the read. At a hit the same check means that a new read would get the same answers from the guard. Any other read resolves the imports as before and stores nothing. uncut compares only the paths of the resolving guard. The reads under any other guard cost less than 3% of the read time on the Rust corpus. The table starts after the alias step, because a read before it can miss a class. The graphs do not change. projectgraph.Version stays 19, and the hash rows of the cases stay as they are. - Fuzz, table against no table in one process: 3000 Rust, 3000 Java and 3000 Go generated projects, 0 diffs. 39 Rust seeds ran out of time and do not count. - Fuzz, this commit against its parent by graph hash: 2965 more Rust crates and workspaces, 0 diffs. 35 more seeds ran out of time. - A build that resolves again at each hit and compares the lists: 4.79 million hits in three builds of the 30 corpus projects, 0 mismatches. - Both method reports are byte-identical to those of the parent. - A table without the path check gives 36 diffs in 300 seeds and fails the case rust/glob-use-workspace-crate. Link time of seven Rust projects, best of three, in ms: project no table cut table this table postgres 822 627 763 native-tls 576 340 367 cookie 184 106 120 imageproc 645 423 496 tokio-postgres 773 633 709 lettre_email 1644 73 194 rusqlite_migration 124 113 144 sum 4768 2315 2793 Known limit: the tables of the build grow during the link step. A read at a later time can see more of them than the stored read did. The checks above found no such case. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01PFQbqPqd9xn1fT6hBsyoUm Signed-off-by: Claude --- projectgraph/cha.go | 2 ++ projectgraph/link.go | 15 +++++++++-- projectgraph/resolve.go | 57 ++++++++++++++++++++++++++++++++++++++--- projectgraph/rust.go | 3 +++ 4 files changed, 71 insertions(+), 6 deletions(-) diff --git a/projectgraph/cha.go b/projectgraph/cha.go index 0cfba62f..0da914ee 100644 --- a/projectgraph/cha.go +++ b/projectgraph/cha.go @@ -66,6 +66,7 @@ func (b *builder) mro(class string) []string { return order } b.mros[class] = []string{class} + b.ordering++ var order []string if rec, ok := b.classes[class]; ok && profileOf(rec.ix.Language).c3 { order = b.c3(class) @@ -73,6 +74,7 @@ func (b *builder) mro(class string) []string { if order == nil { order = b.depthFirst(class, 0, map[string]bool{}) } + b.ordering-- b.mros[class] = order return order } diff --git a/projectgraph/link.go b/projectgraph/link.go index 360ff820..c8d62ff3 100644 --- a/projectgraph/link.go +++ b/projectgraph/link.go @@ -149,6 +149,12 @@ type builder struct { // lets the resolutions of one file run on past the budget of the caller, // and a cycle of glob uses can keep them running for hours. stopped atomic.Bool + // wildcardMods holds the modules of the wildcard imports of each scope + // whose read no cycle guard cut, as wildcardModules describes. asked + // holds the Rust paths that the read whose modules can go to the table + // asks the resolving guard for, and is nil with no such read. + wildcardMods map[*scope]*wildcardMods + asked map[[2]string]bool // unitTypes holds the type that a unit of dependency code gives for // each external key, or "". unitTypes map[string]string @@ -172,7 +178,10 @@ type builder struct { // files declare a package or a namespace. namespaces map[langcode.Code]*namespaces - mros map[string][]string + mros map[string][]string + // ordering counts the classes whose MRO a lookup reads now. A read of + // such a class gets the class alone. + ordering int children map[string][]string // aliases holds the definitions of each class that the language joins // to one class, the class too. @@ -362,10 +371,12 @@ func (b *builder) linkAll(ctx context.Context) error { } } // The classes are whole from here, so the members of a group of - // aliases can be one table. + // aliases can be one table. A read of the wildcard imports of a scope + // before this point can miss a class, so wildcardMods starts here. b.groupMembers = map[string]map[string]string{} b.groupRecords = map[string][]classRecord{} b.externalBases = map[string]string{} + b.wildcardMods = map[*scope]*wildcardMods{} for _, p := range b.paths { if err := ctx.Err(); err != nil { diff --git a/projectgraph/resolve.go b/projectgraph/resolve.go index 177a23c5..b993ea43 100644 --- a/projectgraph/resolve.go +++ b/projectgraph/resolve.go @@ -500,6 +500,13 @@ type wildcardRead struct { read bool } +// wildcardMods holds the modules of the wildcard imports of a scope, and +// the Rust paths that the read of them asked the resolving guard for. +type wildcardMods struct { + mods []string + asked map[[2]string]bool +} + // wildcardModules returns the modules of the wildcard imports of a scope, // in the order of the imports. The resolution of a module can walk a unit // whose name lookup reads the wildcard imports of the same scope, as the @@ -510,9 +517,13 @@ type wildcardRead struct { // So a read of a scope that a resolution reads now gets the modules of the // last whole pass, and the passes repeat until the modules stay the same. // A module that only an import after it brings into scope thus resolves. -// No table keeps the modules after the read. A resolution under the -// resolving guard of a Rust path gives a part of the modules, and a table -// would keep that part for the whole build. +// +// A cycle guard that an outer resolution holds can cut a read short. +// app/src/prelude.rs has pub use core_lib::*, and the resolution of that +// path reads the glob use again under its own resolving guard. A table +// that kept that list gave no module for the whole build, and a target +// under the crate read not-found. So the table keeps and gives a list only +// where uncut holds, and any other read resolves the imports again. // // A cycle of wildcard imports across files still costs time that grows // with the number of files. A file that each other file of the cycle reads @@ -525,9 +536,17 @@ func (b *builder) wildcardModules(sc *scope) []string { r.read = true return r.mods } + if w := b.wildcardMods[sc]; w != nil && b.uncut(w.asked) { + return w.mods + } + // A read inside another read adds the paths that it asks for to the + // record of the outer one. + outer := b.wildcardMods != nil && b.asked == nil + if outer { + b.asked = map[[2]string]bool{} + } r := &wildcardRead{} b.expanding[sc] = r - defer delete(b.expanding, sc) for range len(sc.wildcards) + 1 { r.read = false var mods []string @@ -542,9 +561,39 @@ func (b *builder) wildcardModules(sc *scope) []string { break } } + delete(b.expanding, sc) + if outer { + if b.uncut(b.asked) { + b.wildcardMods[sc] = &wildcardMods{mods: r.mods, asked: b.asked} + } + b.asked = nil + } return r.mods } +// uncut reports whether a read of the wildcard imports of a scope that +// asks the resolving guard for the paths gets no answer from a resolution +// in progress. Such a read gives the same modules each time. The guards +// are set and cleared in the order of a stack. So at the end of a read, a +// path in progress was set before the read, and the guard cut the read if +// the read asked for it. +// +// uncut compares the paths of the resolving guard only. On the Rust +// corpus, the reads under any other guard cost less than 3% of the read +// time. So any other state in progress fails the check. +func (b *builder) uncut(asked map[[2]string]bool) bool { + s := b.rustState() + if len(b.expanding)+len(b.visiting)+len(b.reading)+len(b.stepping)+len(b.findingBases)+len(s.routing)+b.ordering > 0 { + return false + } + for k := range s.resolving { + if asked[k] { + return false + } + } + return true +} + // superKeyword is the receiver of a call of a method of the base class, as // super().load() in Python and super.load() in JavaScript. A bare call of it // in JavaScript calls the constructor of the base class. diff --git a/projectgraph/rust.go b/projectgraph/rust.go index 9047eaed..786d07f8 100644 --- a/projectgraph/rust.go +++ b/projectgraph/rust.go @@ -448,6 +448,9 @@ func joinPath(module string, parts []string) string { func (b *builder) resolveRust(importer, written string) (string, bool) { s := b.rustState() k := [2]string{importer, written} + if b.asked != nil { + b.asked[k] = true + } if s.resolving[k] { return "", false } From b165b13745425f17ca99ee72d50604e6b0faa50b Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 15 Nov 2026 16:47:21 +0000 Subject: [PATCH 5/5] fix(projectgraph): undo the memo writes of a glob pass that does not settle A read of the wildcard imports of a scope that a resolution reads now gets the modules of the last pass. A memo that the pass writes from that list can lack a module for the whole build. In the case rust/glob-use-enum-variants, the MRO of a type misses its trait, and the call k.area() gets a no-definition record and no edge. main resolves every import again on each read, so it finds the edge. Each memo write made while a read is in progress now logs an undo step. A pass whose modules change undoes its writes, and the next pass writes them again. A write of a settled pass stays, unless an outer pass undoes it. The log covers the names, MRO, external base and alias binding memos. The routes of Rust crates read no glob use, so they need no step. A memo that skips each write after a pass read gives the same graphs, but the Rust link time of seven corpus projects goes from 2.4 s to 6.7 s. With the undo log it is 2.3 s. Build also checks the context after finish. finish resolves the external keys of the units, and a stop inside it changed the External of a node with a nil error. The two new cases fail on the parent commit and pass on main. Without them the hash rows of version 19 stay as they were, so no other case changes. The rows of version 19 change for the new cases. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01PFQbqPqd9xn1fT6hBsyoUm Signed-off-by: Claude --- projectgraph/cha.go | 2 + projectgraph/link.go | 10 ++- projectgraph/names.go | 2 + projectgraph/resolve.go | 27 +++++++ .../static-wildcard-nested-class/expect.yaml | 75 +++++++++++++++++++ .../project/com/x/A.java | 11 +++ .../project/com/x/Outer.java | 15 ++++ .../project/com/y/Base.java | 7 ++ .../project/com/y/Danger.java | 7 ++ .../rust/glob-use-enum-variants/expect.yaml | 71 ++++++++++++++++++ .../glob-use-enum-variants/project/Cargo.toml | 7 ++ .../glob-use-enum-variants/project/src/app.rs | 7 ++ .../project/src/kinds.rs | 11 +++ .../project/src/main.rs | 9 +++ .../project/src/traits.rs | 5 ++ test/projectgraph/version_test.go | 4 +- 16 files changed, 265 insertions(+), 5 deletions(-) create mode 100644 test/projectgraph/cases/java/static-wildcard-nested-class/expect.yaml create mode 100644 test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/A.java create mode 100644 test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/Outer.java create mode 100644 test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Base.java create mode 100644 test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Danger.java create mode 100644 test/projectgraph/cases/rust/glob-use-enum-variants/expect.yaml create mode 100644 test/projectgraph/cases/rust/glob-use-enum-variants/project/Cargo.toml create mode 100644 test/projectgraph/cases/rust/glob-use-enum-variants/project/src/app.rs create mode 100644 test/projectgraph/cases/rust/glob-use-enum-variants/project/src/kinds.rs create mode 100644 test/projectgraph/cases/rust/glob-use-enum-variants/project/src/main.rs create mode 100644 test/projectgraph/cases/rust/glob-use-enum-variants/project/src/traits.rs diff --git a/projectgraph/cha.go b/projectgraph/cha.go index 0da914ee..219483e8 100644 --- a/projectgraph/cha.go +++ b/projectgraph/cha.go @@ -76,6 +76,7 @@ func (b *builder) mro(class string) []string { } b.ordering-- b.mros[class] = order + b.memo(func() { delete(b.mros, class) }) return order } @@ -183,6 +184,7 @@ func (b *builder) externalBase(class string) (string, bool) { if !ok { base, _ = b.findExternalBase(class) b.externalBases[class] = base + b.memo(func() { delete(b.externalBases, class) }) } return base, base != "" } diff --git a/projectgraph/link.go b/projectgraph/link.go index c8d62ff3..cdc4c1a3 100644 --- a/projectgraph/link.go +++ b/projectgraph/link.go @@ -86,12 +86,13 @@ func Build(ctx context.Context, indexes []*fileindex.Index, opts Options) (*Grap if err := b.markRoots(ctx); err != nil { return nil, err } + g := b.finish() // A stop cuts the resolutions short, so the graph of a stopped build - // lacks edges and goes to no caller. + // lacks edges and goes to no caller. finish resolves the external keys + // of the units, so the check comes after it. if err := ctx.Err(); err != nil { return nil, err } - g := b.finish() g.Stats.Duration = time.Since(start) return g, nil } @@ -182,7 +183,10 @@ type builder struct { // ordering counts the classes whose MRO a lookup reads now. A read of // such a class gets the class alone. ordering int - children map[string][]string + // tentative holds an undo step for each memo write made while a read + // of wildcard imports is in progress, as wildcardModules describes. + tentative []func() + children map[string][]string // aliases holds the definitions of each class that the language joins // to one class, the class too. aliases map[string][]string diff --git a/projectgraph/names.go b/projectgraph/names.go index d80b77c0..b8dc2e20 100644 --- a/projectgraph/names.go +++ b/projectgraph/names.go @@ -29,6 +29,7 @@ func (b *builder) resolveName(module, name string, hops int) (string, *failure) delete(b.visiting, k) if fail == nil || !fail.cut { b.names[k] = resolution{key: key, fail: fail} + b.memo(func() { delete(b.names, k) }) } return key, fail } @@ -223,6 +224,7 @@ func (b *builder) bound(key string) (string, bool) { return "", false } b.bindings[key] = target + b.memo(func() { delete(b.bindings, key) }) if b.g.Nodes[target] != nil { b.link(sc.ix.Language, key, target, b.siteOf(key), EdgeExport, ruleAlias) } diff --git a/projectgraph/resolve.go b/projectgraph/resolve.go index b993ea43..96a64aee 100644 --- a/projectgraph/resolve.go +++ b/projectgraph/resolve.go @@ -517,6 +517,10 @@ type wildcardMods struct { // So a read of a scope that a resolution reads now gets the modules of the // last whole pass, and the passes repeat until the modules stay the same. // A module that only an import after it brings into scope thus resolves. +// A memo that a pass writes from the modules of the last pass can lack a +// module for the whole build. The MRO of a class whose base only the next +// pass brings into scope is such a memo, and a call of a method of the base +// then gets no edge. So a pass whose modules change undoes its memo writes. // // A cycle guard that an outer resolution holds can cut a read short. // app/src/prelude.rs has pub use core_lib::*, and the resolution of that @@ -549,6 +553,7 @@ func (b *builder) wildcardModules(sc *scope) []string { b.expanding[sc] = r for range len(sc.wildcards) + 1 { r.read = false + mark := len(b.tentative) var mods []string for _, imp := range sc.wildcards { if mod, _, ok := b.resolveModule(sc.ix, imp.Module); ok { @@ -560,8 +565,13 @@ func (b *builder) wildcardModules(sc *scope) []string { if !r.read || same { break } + b.undo(mark) } delete(b.expanding, sc) + if len(b.expanding) == 0 { + clear(b.tentative) + b.tentative = b.tentative[:0] + } if outer { if b.uncut(b.asked) { b.wildcardMods[sc] = &wildcardMods{mods: r.mods, asked: b.asked} @@ -571,6 +581,23 @@ func (b *builder) wildcardModules(sc *scope) []string { return r.mods } +// memo logs the undo step of a memo write while a read of wildcard imports +// is in progress. +func (b *builder) memo(undo func()) { + if len(b.expanding) > 0 { + b.tentative = append(b.tentative, undo) + } +} + +// undo reverts the memo writes after the mark, newest first. +func (b *builder) undo(mark int) { + for i := len(b.tentative) - 1; i >= mark; i-- { + b.tentative[i]() + } + clear(b.tentative[mark:]) + b.tentative = b.tentative[:mark] +} + // uncut reports whether a read of the wildcard imports of a scope that // asks the resolving guard for the paths gets no answer from a resolution // in progress. Such a read gives the same modules each time. The guards diff --git a/test/projectgraph/cases/java/static-wildcard-nested-class/expect.yaml b/test/projectgraph/cases/java/static-wildcard-nested-class/expect.yaml new file mode 100644 index 00000000..aa874511 --- /dev/null +++ b/test/projectgraph/cases/java/static-wildcard-nested-class/expect.yaml @@ -0,0 +1,75 @@ +source: safedep:hand +description: >- + Outer extends Base of com.y, and Outer.java has import com.y.* and import static + com.x.Outer.Inner.*. A extends Outer, and A.java comes first. The read of the static import + resolves Outer.Inner, which builds the MRO of Outer. The MRO looks up the base Base through the same + wildcard imports while that read is in progress. The call baseMethod() in Outer.run has a member edge + to Base.baseMethod. A link step that keeps the MRO made from the imports of a pass that has not + ended gives a cha edge and a no-definition record instead. +roots: + - key: com/x/A.java//A//main + kind: main + rule: java.main +exact_edges: true +edges: + - from: com/x/A.java//A//main + to: com/x/A.java//A + kind: direct + confidence: high + site: com/x/A.java:5 + - from: com/x/A.java//A//main + to: com/x/A.java//A//go + kind: member + confidence: high + site: com/x/A.java:5 + - from: com/x/A.java//A//go + to: com/y/Base.java//Base//baseMethod + kind: member + confidence: high + site: com/x/A.java:9 + - from: com/x/Outer.java//Outer//run + to: com/y/Base.java//Base//baseMethod + kind: member + confidence: high + site: com/x/Outer.java:12 + - from: com/x/Outer.java//Outer//run + to: com/x/Outer.java//Outer//Inner//help + kind: direct + confidence: high + site: com/x/Outer.java:13 + - from: com/y/Base.java//Base//baseMethod + to: com/y/Danger.java//Danger//run + kind: member + confidence: high + site: com/y/Base.java:5 + - from: com/y/Danger.java//Danger//run + to: org//danger//Lib//call + kind: direct + confidence: high + site: com/y/Danger.java:5 +unresolved: [] +results: + - target: org//danger//Lib//call + status: found + path: + - key: com/x/A.java//A//main + - key: com/x/A.java//A//go + site: com/x/A.java:5 + kind: member + confidence: high + - key: com/y/Base.java//Base//baseMethod + site: com/x/A.java:9 + kind: member + confidence: high + - key: com/y/Danger.java//Danger//run + site: com/y/Base.java:5 + kind: member + confidence: high + - key: org//danger//Lib//call + site: com/y/Danger.java:5 + kind: direct + confidence: high + call_sites: + - caller: com/y/Danger.java//Danger//run + site: com/y/Danger.java:5 + reached: true diff --git a/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/A.java b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/A.java new file mode 100644 index 00000000..4ee2abac --- /dev/null +++ b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/A.java @@ -0,0 +1,11 @@ +package com.x; + +public class A extends Outer { + public static void main(String[] args) { + new A().go(); + } + + void go() { + baseMethod(); + } +} diff --git a/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/Outer.java b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/Outer.java new file mode 100644 index 00000000..f3426720 --- /dev/null +++ b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/x/Outer.java @@ -0,0 +1,15 @@ +package com.x; + +import com.y.*; +import static com.x.Outer.Inner.*; + +public class Outer extends Base { + public static class Inner { + public static void help() {} + } + + void run() { + baseMethod(); + help(); + } +} diff --git a/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Base.java b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Base.java new file mode 100644 index 00000000..7b33f426 --- /dev/null +++ b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Base.java @@ -0,0 +1,7 @@ +package com.y; + +public class Base { + public void baseMethod() { + Danger.run(); + } +} diff --git a/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Danger.java b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Danger.java new file mode 100644 index 00000000..f6c5a8de --- /dev/null +++ b/test/projectgraph/cases/java/static-wildcard-nested-class/project/com/y/Danger.java @@ -0,0 +1,7 @@ +package com.y; + +public class Danger { + public static void run() { + org.danger.Lib.call(); + } +} diff --git a/test/projectgraph/cases/rust/glob-use-enum-variants/expect.yaml b/test/projectgraph/cases/rust/glob-use-enum-variants/expect.yaml new file mode 100644 index 00000000..65ccb733 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-enum-variants/expect.yaml @@ -0,0 +1,71 @@ +source: safedep:hand +description: >- + src/main.rs has pub use kinds::* and pub use kinds::Kind::*. src/kinds.rs has pub use + crate::Mode::*, so a read of the glob uses of kinds.rs reads the glob uses of main.rs, and that read + reads kinds.rs again. Kind implements the trait Tr of src/traits.rs, and run calls k.area(), so the + call has a member edge to Tr::area, and dep::danger is found. A link step that keeps a result made + from the modules of a pass that has not ended loses the module of traits.rs for the build. The call + then gets a no-definition record and no edge. +roots: + - key: src/main.rs + kind: main + rule: rust.main + - key: src/main.rs//main + kind: main + rule: rust.main +exact_edges: true +edges: + - from: src/main.rs//main + to: src/app.rs//start + kind: direct + confidence: high + site: src/main.rs:8 + - from: src/app.rs//start + to: crate//kinds//Fast + kind: reference + confidence: low + site: src/app.rs:5 + - from: src/app.rs//start + to: src/kinds.rs//run + kind: direct + confidence: high + site: src/app.rs:6 + - from: src/kinds.rs//run + to: src/traits.rs//Tr//area + kind: member + confidence: high + site: src/kinds.rs:10 + - from: src/traits.rs//Tr//area + to: dep//danger + kind: direct + confidence: high + site: src/traits.rs:3 +unresolved: + - caller: src/app.rs + site: src/app.rs:1 + reason: no-definition +results: + - target: dep//danger + status: found + path: + - key: src/main.rs//main + - key: src/app.rs//start + site: src/main.rs:8 + kind: direct + confidence: high + - key: src/kinds.rs//run + site: src/app.rs:6 + kind: direct + confidence: high + - key: src/traits.rs//Tr//area + site: src/kinds.rs:10 + kind: member + confidence: high + - key: dep//danger + site: src/traits.rs:3 + kind: direct + confidence: high + call_sites: + - caller: src/traits.rs//Tr//area + site: src/traits.rs:3 + reached: true diff --git a/test/projectgraph/cases/rust/glob-use-enum-variants/project/Cargo.toml b/test/projectgraph/cases/rust/glob-use-enum-variants/project/Cargo.toml new file mode 100644 index 00000000..730014fa --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-enum-variants/project/Cargo.toml @@ -0,0 +1,7 @@ +[package] +name = "app" +version = "0.1.0" +edition = "2021" + +[dependencies] +dep = "1.0.0" diff --git a/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/app.rs b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/app.rs new file mode 100644 index 00000000..09e4cfad --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/app.rs @@ -0,0 +1,7 @@ +use crate::kinds::Fast; +use crate::kinds::Kind; + +pub fn start(k: Kind) { + let _m = Fast; + crate::kinds::run(k); +} diff --git a/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/kinds.rs b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/kinds.rs new file mode 100644 index 00000000..907b206d --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/kinds.rs @@ -0,0 +1,11 @@ +use crate::traits::*; +pub use crate::Mode::*; + +pub enum Mode { Fast, Slow } +pub enum Kind { A, B } + +impl Tr for Kind {} + +pub fn run(k: Kind) { + k.area(); +} diff --git a/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/main.rs b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/main.rs new file mode 100644 index 00000000..0443d719 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/main.rs @@ -0,0 +1,9 @@ +mod app; +mod kinds; +mod traits; +pub use kinds::*; +pub use kinds::Kind::*; + +fn main() { + app::start(Kind::A); +} diff --git a/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/traits.rs b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/traits.rs new file mode 100644 index 00000000..174d5502 --- /dev/null +++ b/test/projectgraph/cases/rust/glob-use-enum-variants/project/src/traits.rs @@ -0,0 +1,5 @@ +pub trait Tr { + fn area(&self) { + dep::danger(); + } +} diff --git a/test/projectgraph/version_test.go b/test/projectgraph/version_test.go index a056f44c..b65348dc 100644 --- a/test/projectgraph/version_test.go +++ b/test/projectgraph/version_test.go @@ -33,7 +33,7 @@ var graphHashes = map[string]string{ "14/16": "823b1f82c4aed8ba27d19275505c8d1dee755086be48fcda64d323f55b4c62a5", "15/17": "d823ce8ba221c534ab062f7e48abfe91d1c90d50b2a2fdb00d41183dc0e9da09", "16/18": "bb92620bf9903e8d19b52b62198a0bfd69d67856f9db226112b2cedf537b312b", - "16/19": "8d9b986814d74ff539a1a3e7d808a8ce8afff886040cbab890d3ee071cd99d8d", + "16/19": "51ba3e925c628602b3a53c1a6e68b379022a410bb5b749062b3045fef082ac8f", } // resultHashes records the hash of the reach results of every case for @@ -51,7 +51,7 @@ var resultHashes = map[string]string{ "14/16/3": "13b6eecb686ddec3c2ba470fc9752ea66cff445d5e18e0772a71b15ae7fe1c9c", "15/17/4": "1b32d7c1dbb0a4637853eb7a00b0db91a0a4e1a31f221b37ed0d0654a66ed13e", "16/18/5": "e0c6093df3a85353ee15c8a90ef7c2a441f23348ce80c9d49793c256bddeffc5", - "16/19/5": "a11bd5ddff2a96ccaebeccf4f449f85d9b34ade8dd3f59d5763e3d021a1ffd34", + "16/19/5": "a935650f8e4d01c0abdceeefb3332bf779927693a1c48b28263da5365db752cd", } // summaryHashes records the hash of the golden summaries of the cases for