Merged
Conversation
ensure redirects are not automatically followed in test runner logic
There was a problem hiding this comment.
Pull request overview
This PR improves the FastEdge local debugger/test runner’s HTTP-WASM ergonomics and production parity by (1) adding explicit HTTP subprocess port pinning (httpPort) and (2) ensuring HTTP-WASM redirects are surfaced to callers without being followed automatically. It also expands the debugger server’s port auto-increment range and aligns the UI request method dropdown defaults.
Changes:
- Add
RunnerConfig.httpPort+ config/schema/frontend plumbing to pin the spawnedfastedge-runHTTP server port (fail-fast when busy). - Surface HTTP-WASM redirects verbatim by using
fetch({ redirect: "manual" }), with new regression tests and documentation updates. - Expand debugger port scanning attempts (10 → 50) and update UI method dropdown defaults.
Reviewed changes
Copilot reviewed 32 out of 33 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| test-applications/http-apps/rust/wasi/http-responder/src/lib.rs | Add redirect response branch driven by x-redirect-url header. |
| test-applications/http-apps/rust/basic/http-responder/src/lib.rs | Add redirect response branch driven by x-redirect-url header. |
| test-applications/http-apps/js/src/http-responder.ts | Add redirect response branch driven by x-redirect-url header. |
| server/test-framework/suite-runner.ts | Document redirect behavior for runHttpRequest. |
| server/server.ts | Forward httpPort through /api/load; expand debugger port scan range to 50. |
| server/schemas/config.ts | Extend HTTP config schema with optional httpPort. |
| server/schemas/api.ts | Extend /api/load request schema with optional httpPort. |
| server/runner/PortManager.ts | Make isPortFree() public for pinned-port checks. |
| server/runner/IWasmRunner.ts | Add RunnerConfig.httpPort and document redirect semantics for execute(). |
| server/runner/HttpWasmRunner.ts | Implement httpPort pinning and surface redirects via redirect: "manual". |
| server/tests/integration/http-apps/http-responder/http-responder.test.ts | Add redirect regression tests across HTTP app variants. |
| server/tests/integration/http-apps/http-port-pin/http-port-pin.test.ts | Add integration tests covering pinned-port success/fail-fast behavior. |
| schemas/fastedge-config.test.schema.json | Add httpPort to the HTTP-WASM config variant schema. |
| schemas/api-load.schema.json | Add httpPort to /api/load JSON schema. |
| schemas/api-config.schema.json | Add httpPort to HTTP-WASM config schema used by API config endpoints. |
| frontend/src/views/HttpWasmView/HttpWasmView.tsx | Remove redundant method list prop so view uses RequestBar defaults. |
| frontend/src/stores/types.ts | Add httpPort to config state and test config typing. |
| frontend/src/stores/slices/wasmSlice.ts | Forward httpPort from config state into WASM upload calls. |
| frontend/src/stores/slices/wasmSlice.test.ts | Update expectations for the new uploadWasm(..., httpPort) argument. |
| frontend/src/stores/slices/configSlice.ts | Load/export httpPort only for HTTP-WASM configs; clear it for CDN configs. |
| frontend/src/components/common/RequestPanel/RequestBar/RequestBar.tsx | Expand default method dropdown to full standard method set. |
| frontend/src/api/index.ts | Include optional httpPort in /api/load request bodies. |
| fastedge-plugin-source/generate-docs.sh | Pass large prompts via stdin to avoid Linux argv size limits. |
| fastedge-plugin-source/.generation-config.md | Teach doc generator about redirect/manual semantics and httpPort. |
| docs/TEST_FRAMEWORK.md | Document redirect behavior for runHttpRequest; update flow result typing. |
| docs/TEST_CONFIG.md | Document new config field httpPort and its intent. |
| docs/RUNNER.md | Document httpPort and redirect behavior for execute(). |
| docs/INDEX.md | Formatting adjustments to export tables. |
| docs/DEBUGGER.md | Update debugger port auto-increment range from 10 → 50. |
| docs/API.md | Document new /api/load body field httpPort and provide an example. |
| context/CHANGELOG.md | Add changelog entries describing new UI + runner behaviors. |
| .gitignore | Ignore .fastedge-debug/ debugger artifact directories. |
qrdl
approved these changes
Apr 22, 2026
Collaborator
Author
|
🎉 This PR is included in version 0.1.7 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
No description provided.