Skip to content

Opening a file from the recent file list crashes the launcher. #3

@Smithor

Description

@Smithor

If a file has changed names, and is no longer accessible at the previous location, the application will crash.

Solution to this problem is to scan the list when the program opens and make sure that all paths are valid. If that is not an option, then when an invalid path is detected, it should give a popup saying that the file is no longer accessible at the given location, and ask if the list item should be removed from the list.

Stacktrace included below:

java.lang.RuntimeException: XMLArchiver.readXmlFromUrl: Cannot read url: WebURL: file:/{path to file being loaded}
at snap.util.XMLArchiver.readXmlFromUrl(XMLArchiver.java:156)
at snap.view.UILoader.loadViewForControllerAndUrl(UILoader.java:30)
at snap.view.UILoader.loadViewForUrl(UILoader.java:52)
at snapbuild.app.EditorPane.getParentViewForUrl(EditorPane.java:192)
at snapbuild.app.EditorPane.openEditorForUrl(EditorPane.java:163)
at snapbuild.app.EditorPane.openEditorForFile(EditorPane.java:154)
at snapbuild.app.WelcomePanel.openFile(WelcomePanel.java:245)
at snapbuild.app.WelcomePanel.respondUI(WelcomePanel.java:180)
at snap.view.ViewController.invokeRespondUI(ViewController.java:589)
at snap.view.ViewController.dispatchEventToController(ViewController.java:608)
at snap.view.View.processEventHandlers(View.java:2601)
at snap.view.View.processEventAll(View.java:2567)
at snap.view.EventDispatcher.dispatchActionEvent(EventDispatcher.java:404)
at snap.view.EventDispatcher.dispatchEvent(EventDispatcher.java:139)
at snap.view.WindowView.dispatchEventToWindow(WindowView.java:757)
at snap.view.View.fireActionEvent(View.java:2640)
at snap.view.ButtonBase.fireActionEvent(ButtonBase.java:290)
at snap.view.ButtonBase.processEvent(ButtonBase.java:269)
at snap.view.View.processEventHandlers(View.java:2597)
at snap.view.EventDispatcher.dispatchMouseEvent(EventDispatcher.java:207)
at snap.view.EventDispatcher.dispatchEvent(EventDispatcher.java:131)
at snap.view.WindowView.dispatchEventToWindow(WindowView.java:757)
at snap.swing.SWRootView.processEvent(SWRootView.java:158)
at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:4958)
at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2318)
at java.desktop/java.awt.Component.dispatchEvent(Component.java:4790)
at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4917)
at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4560)
at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4501)
at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2304)
at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2671)
at java.desktop/java.awt.Component.dispatchEvent(Component.java:4790)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:725)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:702)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions