mirror of
https://github.com/l0ng-ai/openidea.git
synced 2026-11-13 04:34:21 -10:00
Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f8c372929c | ||
|
|
4568272dc3 |
No files matched your search
@@ -76,6 +76,4 @@ the [official plugins](plugins/official). The plugin API is still a preview.
|
||||
|
||||
[Apache 2.0](LICENSE). Bundled third-party assets are listed in [`THIRD_PARTY_LICENSES.md`](THIRD_PARTY_LICENSES.md).
|
||||
|
||||
|
||||
|
||||
<sub>Not affiliated with JetBrains. IntelliJ IDEA is a trademark of JetBrains s.r.o.</sub>
|
||||
+6
-4
@@ -90,11 +90,13 @@
|
||||
if (target?.tagName === "SCRIPT" || (target?.tagName === "LINK" && target.rel === "modulepreload")) {
|
||||
show(`Could not load startup script: ${target.src || target.href}`);
|
||||
} else if (event.error || event.message) {
|
||||
// ResizeObserver defers undelivered notifications to the next frame; startup can continue.
|
||||
// ResizeObserver defers undelivered notifications to the next frame; startup can
|
||||
// continue. Blink reports the loop as a bare message, WebKit (Tauri on Linux) as an
|
||||
// Error object — ignore both. No genuine startup failure carries these engine strings.
|
||||
const message = event.error?.message ?? event.message;
|
||||
if (
|
||||
!event.error &&
|
||||
(event.message === "ResizeObserver loop completed with undelivered notifications." ||
|
||||
event.message === "ResizeObserver loop limit exceeded")
|
||||
message === "ResizeObserver loop completed with undelivered notifications." ||
|
||||
message === "ResizeObserver loop limit exceeded"
|
||||
)
|
||||
return;
|
||||
show(event.error || `${event.message}\n${event.filename || ""}:${event.lineno || 0}:${event.colno || 0}`);
|
||||
|
||||
@@ -54,10 +54,16 @@ it.each(resizeObserverMessages)("still times out an unresolved startup after %s"
|
||||
expect(document.querySelector("textarea")?.value).toContain("Startup did not finish within 30 seconds.");
|
||||
});
|
||||
|
||||
it.each(resizeObserverMessages)("keeps actual errors with the same message fatal: %s", (message) => {
|
||||
window.dispatchEvent(new ErrorEvent("error", { message, error: new Error(message) }));
|
||||
expect(document.getElementById("splash")).toBeNull();
|
||||
expect(document.querySelector("textarea")?.value).toContain(message);
|
||||
it.each(resizeObserverMessages)("ignores the loop notification delivered as an Error: %s", (message) => {
|
||||
// WebKit (Tauri on Linux) reports the loop with an Error object; Blink as a bare message.
|
||||
// No genuine startup failure carries these engine-generated strings.
|
||||
window.dispatchEvent(new ErrorEvent("error", { message, filename: "tauri://localhost", error: new Error(message) }));
|
||||
expect(document.getElementById("splash")).not.toBeNull();
|
||||
expect(document.getElementById("boot-error")).toBeNull();
|
||||
expect(document.documentElement.dataset.boot).toBeUndefined();
|
||||
window.dispatchEvent(new Event("openidea:boot-ready"));
|
||||
vi.advanceTimersByTime(30_000);
|
||||
expect(document.getElementById("boot-error")).toBeNull();
|
||||
});
|
||||
|
||||
it.each(resizeObserverMessages)("keeps rejections with the same message fatal: %s", (message) => {
|
||||
|
||||
Reference in new issue
Block a user