dmf-get: fallback to public manifest when module not found in provided manifest#273
Conversation
Co-authored-by: JohnAmadis <17320783+JohnAmadis@users.noreply.github.com>
|
@copilot chciałbym się upewnić, że to działa tak jak oczekuję - ten fallback nie ma być permanentny, tylko na potrzeby tych modułów, których brakuje. Czyli w sumie musimy mieć cały czas 2 przeparsowane manifesty i szukać w lokalnym modułu, a jeśli nie możemy go znaleźć to wtedy w tym publicznym. I potem następny moduł znowu najpierw w lokalnym |
…odule Co-authored-by: JohnAmadis <17320783+JohnAmadis@users.noreply.github.com>
Dokładnie tak to teraz działa – obydwa manifesty są utrzymywane równocześnie. Refaktoryzacja w commicie
W przypadku pliku |
When a local/custom manifest is provided via
-m, auto-discovered, or set viaDMOD_MANIFEST,dmf-getnow searches that manifest first and transparently falls back to the public registry manifest if the module isn't found. Both manifests remain alive throughout the session — the provided manifest is always the first choice for every module lookup, with the public manifest consulted only as a secondary source. A--no-fallbackflag disables this behavior to enforce strict use of the provided manifest.Changes
GetContextForModule()helper — probes the primary (provided) manifest context for the requested module; if absent, lazily initialises and returns the public manifest fallback context without freeing the primary contextheaders/docsresource extraction.dmddependencies file (shared fallback context across all loop iterations)--no-fallbackCLI flag — disables the fallback; module lookup stops at the provided manifestExample
Fallback is skipped when the provided manifest IS the public manifest (no redundant double-fetch).
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.