Skip to content

feat(#751): extensible settings — track handled keys, add filter, support github_pat#752

Merged
chubes4 merged 1 commit intoExtra-Chill:mainfrom
Sarai-Chinwag:feature/751-extensible-settings
Mar 9, 2026
Merged

feat(#751): extensible settings — track handled keys, add filter, support github_pat#752
chubes4 merged 1 commit intoExtra-Chill:mainfrom
Sarai-Chinwag:feature/751-extensible-settings

Conversation

@saraichinwag
Copy link
Contributor

Summary

  • Settings update ability (executeUpdateSettings) now tracks which input keys were actually processed and reports unrecognized keys as unhandled_keys in the response
  • Adds datamachine_update_settings filter so extensions can handle their own settings keys without modifying core
  • Adds github_pat and github_default_repo to core settings handler and input schema (GitHubAbilities already reads these from PluginSettings)
  • CLI set command now errors when a key was not recognized, instead of silently reporting success

Changes

  • inc/Abilities/SettingsAbilities.php — track $handled_keys, add GitHub settings, add filter hook, return unhandled_keys
  • inc/Cli/Commands/SettingsCommand.php — check unhandled_keys and error if the CLI key was ignored
  • tests/Unit/Abilities/SettingsAbilitiesTest.php — 5 new tests: github_pat, github_default_repo, unhandled keys detection, known keys have no unhandled, extension via filter

Testing

All 24 settings ability tests pass. All 4 CLI settings tests pass. 13 pre-existing failures on main unchanged.

Closes #751

…filter, support github_pat

Settings update ability now tracks which input keys were actually processed.
Unknown keys are reported as unhandled_keys in the response instead of being
silently ignored. Extensions can hook into the datamachine_update_settings
filter to handle their own keys.

- Add github_pat and github_default_repo to core settings handler + schema
- Add datamachine_update_settings filter for extension-owned keys
- CLI set command now errors when a key was not recognized
- Add 5 tests covering new behavior
@chubes4 chubes4 merged commit 67e7caf into Extra-Chill:main Mar 9, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Settings update ability silently ignores unknown keys — not extensible

2 participants