logancyang_obsidian-copilot/src
Zero Liu 05434a59df
fix(skills): eliminate Skills Settings UI lag from watcher-driven refreshes (#2508)
* fix(skills): eliminate Skills Settings UI lag from watcher-driven refreshes

Replaces the time-based watcher suppression with path-scoped expectations:
each SkillManager FS write registers predicates (exists/missing/modified/
subtree-*) and the matching vault events are dropped without triggering a
debounced reconcile. A 10s safety timer backstops never-arriving events.
Toggle/delete/rename/saveProperties now publish incremental in-memory updates
instead of re-running full discovery, so the Properties modal save returns
synchronously and the grid reflects the change on the next render.

* fix(skills): heal drift when expectations expire; preserve external reconciles

Two fixes for the watcher-suppression machinery on PR #2508:

- `armSafetyTimer`: when the 10s backstop fires with expectations still
  pending, schedule a debounced reconcile before clearing. Catches the case
  where an external process undid our change (e.g. deleted a link we expected
  to exist) — the matching event was suppressed, predicate never satisfied,
  and previously the state drifted silently until an unrelated watched event
  fired.

- `runInternalMutation`: stop cancelling pre-existing reconcile timers in
  the finally block. Events fired during the mutation are dropped by the
  depth gate, so any debounce timer left armed was scheduled by an external
  event before the mutation started and still needs servicing.

Adds two regression tests and updates the pre-existing "safety timer clears
stale expectations" test which is superseded by the new healing behavior.
2026-05-21 15:07:49 -07:00
..
__tests__ chore(types): tighten types and replace TFile/TFolder casts (W1/9) (#2403) 2026-05-12 16:18:22 -07:00
agentMode fix(skills): eliminate Skills Settings UI lag from watcher-driven refreshes (#2508) 2026-05-21 15:07:49 -07:00
cache chore(eslint): enable no-explicit-any; fix ~395 violations (#2452) 2026-05-14 02:08:45 -07:00
commands fix(agent-mode): preserve persisted enabled flag on mobile (#2484) 2026-05-20 19:05:41 -07:00
components feat(agent-mode): make note links clickable in chat and tool cards (#2503) 2026-05-21 10:05:10 -07:00
context chore(deps): remove unused deps and dead code to shrink bundle (#2460) 2026-05-14 22:25:59 -07:00
contexts feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
core feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
editor chore(deps): remove unused deps and dead code to shrink bundle (#2460) 2026-05-14 22:25:59 -07:00
hooks Support agent image and PDF context (#2483) 2026-05-20 19:05:41 -07:00
imageProcessing Improve custom command (#1942) 2025-10-20 17:52:50 -07:00
integration_tests feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
lib feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
LLMProviders feat(agent-mode): reveal full bash command on action card expand (#2479) 2026-05-20 19:05:41 -07:00
memory chore(eslint): enable no-explicit-any; fix ~395 violations (#2452) 2026-05-14 02:08:45 -07:00
mentions feat: add Firecrawl and Supadata self-host support for web search and YouTube (#2196) 2026-02-19 20:44:39 -08:00
miyo chore(eslint): enable no-explicit-any; fix ~395 violations (#2452) 2026-05-14 02:08:45 -07:00
projects Enable unsafe member access linting (#2474) 2026-05-15 18:26:40 -07:00
search feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
services chore(react): centralize React root creation via createPluginRoot helper (#2467) 2026-05-15 11:49:03 -07:00
settings feat(agent-mode): per-backend env variable overrides (#2499) 2026-05-20 22:58:57 -07:00
state feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
styles fix(agent-mode): apply status-bar clearance padding to agent chat view (#2497) 2026-05-20 22:31:51 -07:00
system-prompts Enable unsafe member access linting (#2474) 2026-05-15 18:26:40 -07:00
tests chore(deps): swap unmaintained/legacy deps per e18e module-replacements (#2447) 2026-05-14 01:12:52 -07:00
tools feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
types feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
utils feat(agent-mode): make note links clickable in chat and tool cards (#2503) 2026-05-21 10:05:10 -07:00
aiParams.ts feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00
chainType.ts chore(lint): enable obsidianmd/rule-custom-message and fix violations (#2416) 2026-05-13 01:39:35 -07:00
chainUtils.ts fix: defense-in-depth overrides to prevent tiktoken CDN timeout in Plus mode (#2283) 2026-03-13 21:48:13 -07:00
chatUtils.toolMarkers.test.ts chore(test): type test mocks to satisfy @typescript-eslint/no-unsafe-call (#2435) 2026-05-13 23:17:30 -07:00
chatUtils.ts Implement modular context compaction architecture (#2159) 2026-02-06 21:52:33 -08:00
composerUtils.ts chore(deps): remove unused deps and dead code to shrink bundle (#2460) 2026-05-14 22:25:59 -07:00
constants.ts feat(agent-mode): enable by default on desktop, force off on mobile (#2481) 2026-05-20 19:05:41 -07:00
context.ts refactor(react): replace global app with useApp() hook in React layer (#2448) 2026-05-14 00:57:38 -07:00
contextProcessor.dataview.test.ts Remove dead ChainFactory and chain validation helpers (#2469) 2026-05-15 16:02:24 -07:00
contextProcessor.embeds.test.ts Remove dead ChainFactory and chain validation helpers (#2469) 2026-05-15 16:02:24 -07:00
contextProcessor.selectedText.test.ts Address quick ask (#2146) 2026-02-03 20:04:10 -08:00
contextProcessor.ts chore(eslint): enable no-explicit-any; fix ~395 violations (#2452) 2026-05-14 02:08:45 -07:00
encryptionService.test.ts chore(react): centralize React root creation via createPluginRoot helper (#2467) 2026-05-15 11:49:03 -07:00
encryptionService.ts Enable unsafe member access linting (#2474) 2026-05-15 18:26:40 -07:00
error.ts chore(deps): remove unused deps and dead code to shrink bundle (#2460) 2026-05-14 22:25:59 -07:00
errorFormat.ts chore(eslint): enable no-explicit-any; fix ~395 violations (#2452) 2026-05-14 02:08:45 -07:00
langchainStream.test.ts chore(eslint): enable @typescript-eslint/no-unsafe-argument and fix violations (#2440) 2026-05-13 21:40:26 -07:00
langchainStream.ts feat: Improve error handling architecture across chain runners. (#1931) 2025-10-23 17:00:23 -07:00
logFileManager.ts feat(keychain): migrate API key storage to Obsidian Keychain (#2364) 2026-05-14 13:57:21 -07:00
logger.ts chore(eslint): enable @typescript-eslint/no-unsafe-argument and fix violations (#2440) 2026-05-13 21:40:26 -07:00
main.ts fix(agent-mode): preserve persisted enabled flag on mobile (#2484) 2026-05-20 19:05:41 -07:00
noteUtils.ts Throttle number of links returned (#998) 2025-01-02 18:18:56 -08:00
plusUtils.ts chore(deps): remove unused deps and dead code to shrink bundle (#2460) 2026-05-14 22:25:59 -07:00
rateLimiter.ts chore(popout): window-global API swaps — timers, globalThis, base64 (W3/9) (#2401) 2026-05-12 22:24:17 -07:00
types.ts feat(keychain): migrate API key storage to Obsidian Keychain (#2364) 2026-05-14 13:57:21 -07:00
utils.cleanMessageForCopy.test.ts Composer V2: Replace replaceInFile with editFile as the primary targeted-edit tool (#2305) 2026-03-17 18:51:39 +09:00
utils.test.ts fix(anthropic+bedrock): adaptive thinking + summarized display for claude-opus-4-7+ (#2471) 2026-05-15 17:29:36 -07:00
utils.ts feat(agent-mode): introduce Agent Mode feature 2026-05-20 19:05:41 -07:00