entry-body-missing: Missing entry response body
Cause
The HTML entry response has a null Response.body, so the loader cannot obtain a response stream for parsing.
Although the error message uses the word empty, this branch checks whether the body is null, not its length. A non-null readable stream containing zero bytes does not directly trigger this error.
Troubleshooting
- Check the request method and response status for a HEAD request or a response without a body, such as 204.
- Inspect responses returned by custom
fetchimplementations, test doubles, and preloading logic. Check fornew Response(null). - Check redirects and gateway behavior to confirm that the final response provides HTML content.
Solution
Make the entry GET request return a valid response with an HTML body. Custom fetch implementations and preloading logic must preserve the body. Use an HTML string or readable stream when mocking an entry response in tests. After correcting the response, also confirm that its HTML is the micro app entry.
