961 B
961 B
smartupdate improvement plan
Status: implemented.
Goal
Make update checks predictable, cache-safe, and testable without changing the core public API shape.
Implementation
- Fix CLI cache behavior so cached update information still reports an available update and time-based cache entries expire.
- Cache both
update-availableandup-to-dateresults so normal repeated CLI runs do not keep hitting the registry. - Store cache context with each entry and only reuse cache entries for the same package, current version, and registry.
- Preserve more useful error types for invalid package names, invalid versions, package lookup failures, and registry failures.
- Await and catch changelog opening so browser failures do not become unhandled promise rejections.
- Replace live npm tests with deterministic registry stubs and ephemeral cache storage.
- Remove unused dependency surface.
Verification
- Run
pnpm test. - Run
pnpm run build.