You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: detect port-like segment in SCP shorthand and suggest ssh:// form (#787)
* fix: detect port-like segment in SCP shorthand and suggest ssh:// form (#784)
When a user writes `git@host:7999/project/repo.git` (SCP shorthand
intending port 7999), the parser silently treats `7999/project/repo`
as the repo path. The subsequent git clone fails with a 404 — no
actionable error from APM.
Detect when the first path segment after `:` in SCP shorthand is a
valid TCP port number (1-65535) and raise a ValueError with a
suggested ssh:// URL that preserves the port correctly.
* fix: preserve #ref and @alias in suggested ssh:// URL; add CHANGELOG entry
Address review feedback:
- Thread reference and alias into the suggested ssh:// URL so users
don't have to re-add them manually after switching from SCP form.
- Add CHANGELOG entry under [Unreleased] -> Fixed for #784.
- Add test for combined #ref@alias preservation.
* fix: treat empty remaining path as no-path case; use pytest.raises style
Address Copilot review:
- git@host:7999/ (trailing slash, empty remaining path) now falls into
the "no repository path follows" branch instead of building a
suggestion ending with '/'.
- Switch test_suggestion_omits_git_suffix_when_absent from try/except
to pytest.raises for consistency with the rest of the file.
Copy file name to clipboardExpand all lines: CHANGELOG.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,6 +27,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
27
27
28
28
-`apm install` no longer silently drops skills, agents, and commands when a Claude Code plugin also ships `hooks/*.json`. The package-type detection cascade now classifies plugin-shaped packages as `MARKETPLACE_PLUGIN` (which already maps hooks via the plugin synthesizer) before falling back to the hook-only classification, and emits a default-visibility `[!]` warning when a hook-only classification disagrees with the package's directory contents (#780)
29
29
- Preserve custom git ports across protocols: non-default ports on `ssh://` and `https://` dependency URLs (e.g. Bitbucket Datacenter on SSH port 7999, self-hosted GitLab on HTTPS port 8443) are now captured as a first-class `port` field on `DependencyReference` and threaded through all clone URL builders. When the SSH clone fails, the HTTPS fallback reuses the same port instead of silently dropping it (#661, #731)
30
+
- Detect port-like first path segment in SCP shorthand (`git@host:7999/path`) and raise an actionable error suggesting the `ssh://` URL form, instead of silently misparsing the port as part of the repository path (#784)
0 commit comments