Skip to main content

importlib-reload-class-identity

Diagnose and fix the silent class-identity drift caused by `importlib.reload()` on modules that define classes whose instances live elsewhere. Use when: (1) a pytest fixture uses `importlib.reload(some_module)` to "flush caches" and downstream tests then fail with `isinstance` checks rejecting objects that LOOK correct; (2) you see a diagnostic warning of the form "expected X, got X" — same class name, different class identity (`type(obj).__name__ == "X"` but `obj is not isinstance(X)`); (3) one fragile test fixture causes dozens-to-hundreds of cascading failures in unrelated test files; (4) tests pass in isolation but fail when run as part of the full suite, with order dependence pointing at the reload site; (5) you have an entry-point / plugin / discovery system whose post-reload registry is empty even though the underlying entries still exist. Covers root cause (Python class objects are first-class identities; reload mints new ones; pre-reload instances keep old identity), the diagnostic signature, and the

Ir a la instalación

Datos de origen

Repositorio
cajias/claude-skills
Última actividad en el origen
20 de julio de 2026 a las 07:29
Idioma detectado de SKILL.md
inglés
Estrellas
0
Forks
0

Opciones de instalación

De forma predeterminada está seleccionado el prompt que primero revisa el origen. Puedes cambiar a un comando directo o descargar una copia local.

Revisa los archivos de origen

Lee SKILL.md y los archivos complementarios que muestra SkillsMP antes de decidir si quieres instalarlo.