-
Notifications
You must be signed in to change notification settings - Fork 0
Fix webpack error handling in GDU build process #332
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
Conversation
Co-authored-by: skinread <[email protected]>
Co-authored-by: skinread <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make sure to generate a change set for GDU so that it is versioned.
The CI uses changeset library
Co-authored-by: skinread <[email protected]>
Added changeset for GDU package in commit 9a3db28. The changeset will ensure proper versioning when the webpack error handling fix is released. Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
The webpack build errors in the GDU package were not being properly displayed in the console due to incorrect promise resolution logic in
runWebpack.ts.The Problem
The
runfunction in/packages/gdu/lib/runWebpack.tshad a race condition where:compiler.run()would execute and receive compilation errorscompiler.close()would be called, and its callback would immediately resolve the promisedone()function would then try to reject the promise, but it was already resolvedThis meant that webpack compilation errors were silently swallowed and never displayed to developers.
The Solution
Fixed the promise resolution flow by:
done(resolve, reject)call now happens inside thecompiler.close()callback, ensuring errors are handled before the promise is settleddonefunction to log compilation errors to the console usingconsole.error()before rejectingerr) and close errors (err2) are now properly combinedBefore
After
Now webpack compilation errors will be clearly visible in the console with detailed error messages, making debugging much easier for developers.
Fixes #331.
Warning
Firewall rules blocked me from connecting to one or more addresses
I tried to connect to the following addresses, but was blocked by firewall rules:
http://168.63.129.16:80/machine//usr/bin/python3 -u bin/WALinuxAgent-2.13.1.1-py3.9.egg -collect-logs(http block)If you need me to access, download, or install something from one of these locations, you can either:
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.