Repository navigation
fix: restore httpgd plot and local help rendering with EJS 7 - #1911
Conversation
eitsupi
left a comment
There was a problem hiding this comment.
ChatGPT review — Approved
The EJS import fix addresses #1910. I have two non-blocking suggestions:
-
Fail builds on all esbuild warnings. The underlying CI issue was that warnings did not cause build failures. Rather than promoting only "import-is-undefined" to an error, I suggest treating any esbuild warning as a build failure across all four build contexts (excluding watch mode).
-
Simplify the regression tests. The 135-line test harness introduces custom bundling, VM execution, and extensive mocking. Given that esbuild already detected the original problem, enforcing zero warnings should provide sufficient protection against this specific regression without the additional maintenance burden.
Neither suggestion needs to block this urgent fix.
|
Thanks for the review. Both suggestions are addressed in da213c8:
Local development and production builds, TypeScript checking, lint, formatting, and diff checks pass. Temporary probes confirmed that a general warning in each of the four contexts fails both build modes, that restoring the original EJS namespace imports also fails both modes, and that watch mode allows warnings across all four contexts. The final production bundle contains zero For this revision, hosted build and formatting checks have passed; lint and the three platform test jobs are still running. |
|
@renkun-ken Thanks for working on this. |
The EJS 7 upgrade makes the namespace imports in the httpgd viewer and local help previewer resolve
renderto undefined when bundled. Plot refreshes and added thumbnails fail, and local package index previews cannot render. Use EJS's default export in both viewers to restore these paths while retaining EJS 7.Non-watch builds now fail if any of the four esbuild contexts reports a warning. All contexts are disposed after rebuilding, including when a build fails. Watch mode continues to report warnings without treating them as build failures.
Fixes #1910.
Validation:
(void 0)(...)calls.