Fix #401: import hint parity #406

Merged
crueber merged 1 commit from fix/issue-401 into main 2026-09-12 19:10:30 +00:00
Owner

SPA-only fix: normalizeSource (web/sdk/src/import.js) now mirrors the server canonicalGenericURL rules (internal/repoimport/url.go:196-208) for non-GitHub URLs — lowercase host, default-port strip, trailing-slash trim, one trailing .git removed — so the import form canonical hint + owner/name prefill match what the server gates/clones. GitHub behavior unchanged; server untouched. Law-12 decision in docs/features/10. Tests: node sdk-import 8/8, full web suite delta +1 pass with 13 pre-existing unrelated failures (identical on origin/main), go test repoimport ok, vite+esbuild green. Fixes #401.

SPA-only fix: `normalizeSource` (web/sdk/src/import.js) now mirrors the server canonicalGenericURL rules (internal/repoimport/url.go:196-208) for non-GitHub URLs — lowercase host, default-port strip, trailing-slash trim, one trailing .git removed — so the import form canonical hint + owner/name prefill match what the server gates/clones. GitHub behavior unchanged; server untouched. Law-12 decision in docs/features/10. Tests: node sdk-import 8/8, full web suite delta +1 pass with 13 pre-existing unrelated failures (identical on origin/main), go test repoimport ok, vite+esbuild green. Fixes #401.
normalizeSource (web/sdk/src/import.js) now applies the server
canonicalGenericURL rules (internal/repoimport/url.go:196-208) to
non-GitHub URLs for the hint + owner/name prefill: lowercase host,
default-port strip, trailing-slash trim, one trailing .git removed.
GitHub-path behavior unchanged; server untouched (already correct).
Decision appended to docs/features/10 §Decisions (law 12).
Sign in to join this conversation.
No description provided.