chore: kill deprecation warnings from workshop warnings survey - #538
Conversation
…ngs survey Swaps converse.py's standardize_lang_tag for ovos_spec_tools.standardize_lang, and restructures OVOSSkill.set_context/remove_context so the supported base class API delegates to a non-warning private path on IntentServiceInterface instead of tripping its own external-caller deprecation warning on every use. Adds scoped filterwarnings to the suites that deliberately exercise the register_adapt_*/register_padatious_* legacy facade for coverage, so their warnings stay visible everywhere else but don't pollute the summary. resource_files.py's load_dialogs/MustacheDialogRenderer path is left unmigrated: the OVOS-INTENT-2 replacement (DialogRenderer) renders one named dialog per call against a LocaleResources corpus, not a directory-wide Mustache-style renderer, so swapping it would be a behavior change rather than a mechanical fix. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Fresh off the press! I've got some check results for you. 🗞️I've aggregated the results of the automated checks for this PR below. 📋 Repo HealthI've checked the repo's balance (aka feature parity). ⚖️ ✅ All required files present. Latest Version: ✅ 🔍 LintAnother piece of the puzzle! 🧩 ❌ ruff: issues found — see job log ⚖️ License CheckEnsuring the project remains 100% open source. 🔓 ✅ No license violations found. Policy: Apache 2.0 (universal donor). StrongCopyleft / NetworkCopyleft / WeakCopyleft / Other / Error categories fail. MPL allowed. 🔒 Security (pip-audit)I've checked for any hardcoded credentials. 🔑 ✅ No known vulnerabilities found (74 packages scanned). 🔨 Build TestsThe assembly line is hummin' along nicely! 🎶 ✅ All versions pass
Signed, sealed, and delivered by the OVOS bot. 📧 |
…ling converse (#542) The #538 import swap moved converse.py to spec-tools' standardize_lang but missed the call site inside _handle_converse_request, leaving it calling the no-longer-imported standardize_lang_tag. Every live converse request raised NameError, which the handler's own except-clause swallowed into {result: False, error: NameError(...)} on the wire — converse() never ran, and the unit suite stayed green because nothing exercised the handler with a real lang payload. Caught by the harness new/new control cell. One-line fix plus a regression test that drives the real handler through the bus and asserts converse() runs and the response carries no error. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Standing rule: every repo carries a version-stamped, newest-first log of what changed since the last stable release, reset at each stable. This adds it for ovos-workshop (since 8.0.0). Every entry checked against current source and existing test coverage, not just commit subjects. > 🤖 Auto-generated by Claude Fable 5 (claude-fable-5) via Claude Code — NOT human-reviewed. Verify before acting. > Verified: entity-file auto-registration behavior (#541), converse > NameError hotfix (#542), set_context registry delegation (#535), > warnings cleanup (#538) — all checked against ovos_workshop source and > existing tests, not just commit subject lines. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Cleans up most of the deprecation warnings a recent survey found in this repo.
ConversationalSkill._get_closest_langwas calling the deprecatedstandardize_lang_tag, so it now usesovos_spec_tools.standardize_lang(the message it deprecates in favor of). The bigger one:OVOSSkill.set_context/remove_contextare supported public skill API, but they routed throughIntentServiceInterface.set_context/remove_context, which are the deprecated external-caller facade — so every normal use of the skill API was warning. Both now delegate to a new private_set_context/_remove_contextonIntentServiceInterface, and the public facade methods still warn when called directly. No wire or session-write behavior changed; the full suite still passes byte-for-byte the same as before.One item from the survey is deliberately left alone:
resource_files.py'sload_dialogs/MustacheDialogRendererpath. The suggested replacement (ovos_spec_tools.DialogRenderer) renders a single named dialog per call against aLocaleResourcescorpus, not a directory-wide Mustache-style renderer keyed by template name — that's a behavior change, not a mechanical swap, so I left the existing code (and its comment explaining why) in place rather than risk changing dialog-rendering behavior.The rest of the change is scoped
filterwarningson seven test files that deliberately exercise the deprecatedregister_adapt_*/register_padatious_*facade on purpose, as legacy-coverage regression tests. Those warnings are still real everywhere else; this only silences them in the suites that intentionally trigger them. Full-suite warning count went from 141 (measured myself,pytest -W default) down to 26 — all of what's left is out of scope: theovos_yes_nothird-party plugin, one unrelatedovos_configdeprecation, oneResourceWarningfromovos_adapt, and theload_dialogsitem described above. Test counts are unchanged: 587 passed, 1 pre-existing failure (test_dual_registration_does_not_double_fire, expected until the ovos-utils idempotency fix releases) both before and after.