-
Notifications
You must be signed in to change notification settings - Fork 12k
vite dev server crashes when server return 502 #26192
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
area: @angular-devkit/build-angular
devkit/build-angular:dev-server
freq1: low
Only reported by a handful of users who observe it rarely
severity3: broken
type: bug/fix
Comments
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Nov 2, 2023
…n using Vite The commit introduces dependencies prebundling and optimisation for SSR dependencies. This is primarily needed for Angular linking and async/await downlevelling. To enable this, we need to use the undocumented `optimizeDeps` setting under the `ssr` option. This is because, the top level `optimizeDeps` vite config option only controls browser dependencies. For the above mentioned option to take effect and transform node packages, we also need to use `noExternal` and use a catch all `RegExp`. Note: setting this option to `true` has a different effect from a catch all `RegExp`, as the former will cause the `external` option to be ignored. Additionally together with `externalMetadata.explicit` we add Node.js build-ins as `external`. Closes: angular#26192
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Nov 2, 2023
…n using Vite The commit introduces dependencies prebundling and optimisation for SSR dependencies. This is primarily needed for Angular linking and async/await downlevelling. To enable this, we need to use the undocumented `optimizeDeps` setting under the `ssr` option. This is because, the top level `optimizeDeps` vite config option only controls browser dependencies. For the above mentioned option to take effect and transform node packages, we also need to use `noExternal` and use a catch all `RegExp`. Note: setting this option to `true` has a different effect from a catch all `RegExp`, as the former will cause the `external` option to be ignored. Additionally together with `externalMetadata.explicit` we add Node.js build-ins as `external`. Closes: angular#26192
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Nov 2, 2023
…en using Vite The commit introduces dependencies prebundling and optimisation for SSR dependencies. This is primarily needed for Angular linking and async/await downlevelling. To enable this, we need to use the undocumented `optimizeDeps` setting under the `ssr` option. This is because, the top level `optimizeDeps` vite config option only controls browser dependencies. For the above mentioned option to take effect and transform node packages, we also need to use `noExternal` and use a catch all `RegExp`. Note: setting this option to `true` has a different effect from a catch all `RegExp`, as the former will cause the `external` option to be ignored. Additionally together with `externalMetadata.explicit` we add Node.js build-ins as `external`. Closes: angular#26192
alan-agius4
added a commit
that referenced
this issue
Nov 2, 2023
…en using Vite The commit introduces dependencies prebundling and optimisation for SSR dependencies. This is primarily needed for Angular linking and async/await downlevelling. To enable this, we need to use the undocumented `optimizeDeps` setting under the `ssr` option. This is because, the top level `optimizeDeps` vite config option only controls browser dependencies. For the above mentioned option to take effect and transform node packages, we also need to use `noExternal` and use a catch all `RegExp`. Note: setting this option to `true` has a different effect from a catch all `RegExp`, as the former will cause the `external` option to be ignored. Additionally together with `externalMetadata.explicit` we add Node.js build-ins as `external`. Closes: #26192
alan-agius4
added a commit
that referenced
this issue
Nov 2, 2023
…en using Vite The commit introduces dependencies prebundling and optimisation for SSR dependencies. This is primarily needed for Angular linking and async/await downlevelling. To enable this, we need to use the undocumented `optimizeDeps` setting under the `ssr` option. This is because, the top level `optimizeDeps` vite config option only controls browser dependencies. For the above mentioned option to take effect and transform node packages, we also need to use `noExternal` and use a catch all `RegExp`. Note: setting this option to `true` has a different effect from a catch all `RegExp`, as the former will cause the `external` option to be ignored. Additionally together with `externalMetadata.explicit` we add Node.js build-ins as `external`. Closes: #26192 (cherry picked from commit 4c1265a)
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
area: @angular-devkit/build-angular
devkit/build-angular:dev-server
freq1: low
Only reported by a handful of users who observe it rarely
severity3: broken
type: bug/fix
Command
serve
Is this a regression?
The previous version in which this bug was not present was
No response
Description
Hi.
My dev server crashes when HttpClient receives 502 error from backend REST api.
If you need repro - please let me know.
Minimal Reproduction
ng serve
Exception or Error
Your Environment
Anything else relevant?
No response
The text was updated successfully, but these errors were encountered: