Skip to content

Commit d89d133

Browse files
committed
Refine eager-imports rule to document lazy-import exceptions
1 parent 84d7c20 commit d89d133

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

.github/copilot-instructions.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,9 @@
5858

5959
## Architecture
6060

61-
- Eager imports unless profiling proves a lazy alternative is needed.
61+
- Eager imports at the top of the module by default. Use lazy imports (inside a
62+
method body) only when necessary to break circular dependencies or to keep
63+
`core/` free of heavy utility imports on rarely-called paths (e.g. `help()`).
6264
- No `pkgutil` / `importlib` auto-discovery patterns.
6365
- No background/daemon threads.
6466
- No monkey-patching or runtime class mutation.

0 commit comments

Comments
 (0)