Skip to content

Bug: Error pop-ups don't appear when loading non-existent files #290

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

Closed
coderabbitai bot opened this issue May 22, 2025 · 0 comments
Closed

Bug: Error pop-ups don't appear when loading non-existent files #290

coderabbitai bot opened this issue May 22, 2025 · 0 comments
Assignees

Comments

@coderabbitai
Copy link

coderabbitai bot commented May 22, 2025

Description

When attempting to load a non-existent file, the application should display an error pop-up, but currently nothing is shown.

Reproduction Steps

  1. Visit https://y-scope.github.io/yscope-log-viewer/?filePath=does_not_exist
  2. Notice that no error pop-up appears, even though a 404 error should be displayed

Root Cause

In the AppController component, setPostPopUp() is called in a useEffect hook, but this happens after the file loading attempt. Any errors that occur during file loading won't show a UI pop-up because the pop-up function reference hasn't been updated in the contextStore yet.

Proposed Solution

Move the setPostPopUp() call before loading a file to ensure that error pop-ups can be displayed for any errors during the file loading process.

References

cc @junhaoliao

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant