I have added my own system search function to *system-definition-search-functions*. It is named QL-DIST:SYSTEM-DEFINITION-SEARCHER.
It is traced in the first session I pasted.
Here is what happens:
1 Attempt to load system "xach", which depends-on alexandria
2 asdf calls find-system for "alexandria" during a resolve-dependency-name step, SYSTEM-DEFINITION-SEARCHER is called but since the project is not installed yet it returns NIL, and so does find-system overall. This NIL is cached.
3 asdf calls find-system for "alexandria" in order to find and load it, and find-system returns the cached NIL
4 asdf signals MISSING-COMPONENT error, which Quicklisp handles via handler-bind
5 Quicklisp downloads and installs alexandria in a way that is visible to SYSTEM-DEFINITION-SEARCHER
6 From the error handler, in a handler-bind, Quicklisp attempts to asdf:load-system alexandria
7 The cached NIL result inhibits discovery of the newly discovered system; SYSTEM-DEFINITION-SEARCHER is not called again
One workaround is to just gather data from the MISSING-COMPONENT and let the stack unwind, rather than recursively trying to find more stuff within the scope of the initial cache.
I have added my own system search function to *system- definition- search- functions* . It is named QL-DIST: SYSTEM- DEFINITION- SEARCHER.
It is traced in the first session I pasted.
Here is what happens:
1 Attempt to load system "xach", which depends-on alexandria
2 asdf calls find-system for "alexandria" during a resolve- dependency- name step, SYSTEM- DEFINITION- SEARCHER is called but since the project is not installed yet it returns NIL, and so does find-system overall. This NIL is cached.
3 asdf calls find-system for "alexandria" in order to find and load it, and find-system returns the cached NIL
4 asdf signals MISSING-COMPONENT error, which Quicklisp handles via handler-bind
5 Quicklisp downloads and installs alexandria in a way that is visible to SYSTEM- DEFINITION- SEARCHER
6 From the error handler, in a handler-bind, Quicklisp attempts to asdf:load-system alexandria
7 The cached NIL result inhibits discovery of the newly discovered system; SYSTEM- DEFINITION- SEARCHER is not called again
One workaround is to just gather data from the MISSING-COMPONENT and let the stack unwind, rather than recursively trying to find more stuff within the scope of the initial cache.