When does Spyder invalidate its completion cache after a package upgrade?
0 reputation · 27 Sept 2022, 23:57 UTC
Stale cache behavior in Spyder
Spyder’s Variable Explorer snapshots the current namespace, and its code completion relies on the Language Server Protocol. When a package in the environment is upgraded or a module on disk is modified, the IDE may still display old symbols or values until a manual refresh occurs.
The documentation does not state whether a simple kernel restart clears these caches or if a full IDE restart is required. This ambiguity leads users to guess whether they need to restart the console, the editor, or both after an environment change.
Unresolved questions
- Which actions (kernel restart, console clear, or IDE restart) are sufficient to invalidate the completion and introspection caches after a package upgrade?
- Does Spyder automatically refresh the Variable Explorer when an imported module’s file is edited, or is a manual refresh always needed?
- What triggers the Language Server to re‑index a module after its source has changed on disk?