I guess given that I see file metadata in marginalia correctly, project-find-file-in does call find-file with appropriate dynamic binding for default-directory, so I suspect the way embark works (or due to other stuffs, perhaps /u/oantolin can explain), it cannot continue from that scope, so by the time embark starts the old dynamic scope has already been unwound?
Anyway, you can just wrap that function call with your own binding that covers embark:
I guess given that I see file metadata in marginalia correctly,
project-find-file-in
does call find-file with appropriate dynamic binding fordefault-directory
, so I suspect the way embark works (or due to other stuffs, perhaps /u/oantolin can explain), it cannot continue from that scope, so by the time embark starts the old dynamic scope has already been unwound?Anyway, you can just wrap that function call with your own binding that covers embark: