Skip to content

Commit c33e59e

Browse files
committed
Eagerly reject cache files that could not resolve their depots
This prevents the unlikely but annoying scenario where the user has a `@depot/packages/Foo/QRSTV/src/Foo.jl` file in the current working directory.
1 parent c57dcee commit c33e59e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

base/loading.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3273,6 +3273,10 @@ end
32733273
end
32743274
for chi in includes
32753275
f, fsize_req, hash_req, ftime_req = chi.filename, chi.fsize, chi.hash, chi.mtime
3276+
if startswith(f, "@depot/")
3277+
@debug("Rejecting stale cache file $cachefile because its depot could not be resolved")
3278+
return true
3279+
end
32763280
if !ispath(f)
32773281
_f = fixup_stdlib_path(f)
32783282
if isfile(_f) && startswith(_f, Sys.STDLIB)

0 commit comments

Comments
 (0)