Repository navigation
issue#203: Fix HP Comware username prompt typo (usernmae -> username) - #205
Merged
Merged
Conversation
|
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The migration’s collation-sensitive comparison can overwrite customized prompts, so it needs a binary comparison to replace only the original seeded value.
1 open issue
What changed in this PR
Addresses #203 by correcting the HP Comware Telnet username prompt in the built-in device type and adding an upgrade migration for existing installations. SSH behavior is unchanged.
Changes:
- Corrects the seeded prompt from
usernmae:tousername:. - Adds a pre-2.0 migration intended to preserve admin-customized prompts.
- Documents the fix in the 2.0 changelog.
| File | Description |
|---|---|
| setup.php | Corrects the HP Comware seed and adds the guarded upgrade migration. |
| CHANGELOG.md | Records the Telnet prompt fix and migration under version 2.0. |
Review effort: Balanced
xmacan
approved these changes
Nov 16, 2026
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
Fixes #203. The built-in HP Comware device type seeded its Telnet username prompt as the misspelled
usernmae:.PHPConnectionmatches this value as a case-insensitive regex against the Telnet output, so a device that printsUsername:never matched and Telnet logins gave up after their retries. SSH logins are unaffected.Changes
setup.php— seed fix (AddDeviceTypes()): corrected the HP Comware username prompt fromusernmae:tousername:, matching the Cisco types. Fixes fresh installs.setup.php— upgrade migration (new< 2.0gate inrouterconfigs_check_upgrade()): a conditionalUPDATEthat rewrites the HP Comwarepromptusertousername:only while it is still exactlyusernmae:, so any value an admin changed is left alone. This is needed becauseAddDeviceType()skips a type whose name already exists, so changing the seed alone would not fix existing installs.CHANGELOG.md: added anissue#203entry under the existing--- 2.0 ---section.Notes
< 2.0gate covers all affected installs and fresh 2.0 installs get the corrected seed.php -l setup.phppasses.