Add v3 to v4 migration guide#288
Merged
Merged
Conversation
New docs/user/migrating-from-v3.md with rename tables for constructors, methods, and utilities, the unified NegationRule mapping with before/after examples, the typed exception hierarchy, the config-view mixin transition (isinstance instead of NotImplementedError), behavior changes to review (future() negation resolution, structured-input rejection, driver registration), and pointers to the new v4 features. Every import and API name in the guide is verified against the package. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
docs/user/migrating-from-v3.md(nav: User Guide → Migrating from v3, right after Getting Started) — the missing piece for existing 3.x users, since v4 renames or removes nearly every entry point.Contents:
get_hconfig→HConfig.from_text, etc.), methods (config_to_get_to→remediation(),dump_simple→to_lines(), ...), and utilities (load_hconfig_v2_options→load_driver_rules, removed v2 mappers).NegationRule+NegationStrategy, and a note thatload_driver_rules()still accepts the old dict keys.ValueError/TypeError→HierConfigErrorsubclasses) for updatingexceptclauses.isinstance(view, InterfaceVlanViewMixin)replacingNotImplementedErrorcatching.future()negation resolution (future() negation edge cases: value-carrying negation on idempotent lines leaves a literal 'no ...' line; bare shorthand negation never matches; empty parents not pruned #269), structured-input rejection, registry-based custom driver wiring.Test plan
InterfaceVlanViewMixin,HierConfigError,NegationRule/NegationStrategy,load_driver_rules/load_tag_rules, ...).poetry run mkdocs build --strict— zero warnings.poetry run ./scripts/build.py lint-and-test— "No issues found".🤖 Generated with Claude Code