Skip to content
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

Having no artboard crashes the editor #2035

Closed
Keavon opened this issue Oct 14, 2024 · 0 comments · Fixed by #2036
Closed

Having no artboard crashes the editor #2035

Keavon opened this issue Oct 14, 2024 · 0 comments · Fixed by #2036
Assignees
Labels
Crash A panic which crashed the editor
Milestone

Comments

@Keavon
Copy link
Member

Keavon commented Oct 14, 2024

Either:

  1. Make a new document with the default artboard
  2. Open the graph, select the artboard, and delete it

or:

  1. Make a new document without an artboard by enabling "Infinite Canvas"

It looks like this regression was introduced in #2028.

Crash log:

panicked at editor/src/messages/portfolio/document/document_message_handler.rs:2235:9:
The parent targets should always be empty (since we have left all layers)

Error
    at https://dev.graphite.rs/assets/index-DuUmgc5P.js:701:1169
    at g (https://dev.graphite.rs/assets/index-DuUmgc5P.js:686:5194)
    at Object.handleJsMessage (https://dev.graphite.rs/assets/index-DuUmgc5P.js:686:5342)
    at https://dev.graphite.rs/assets/index-DuUmgc5P.js:687:66749
    at https://dev.graphite.rs/assets/index-DuUmgc5P.js:687:39724
    at rt (https://dev.graphite.rs/assets/index-DuUmgc5P.js:687:2062)
    at R0.o.wbg.__wbg_call_5fb7c8066a4a4825 (https://dev.graphite.rs/assets/index-DuUmgc5P.js:687:39690)
    at graphite_wasm.wasm._ZN13graphite_wasm10editor_api12EditorHandle27send_frontend_message_to_js17ha25fea14a03bc37dE (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[3460]:0x7a5f06)
    at graphite_wasm.wasm._ZN4core3ops8function2Fn4call17h0b6e80a882797c3eE (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[12804]:0xa52b59)
    at graphite_wasm.wasm._ZN3std9panicking20rust_panic_with_hook17h33fe77d38d305ca3E (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[6456]:0x930366)
    at graphite_wasm.wasm._ZN4core9panicking9panic_fmt17hde8b7aa66e2831e1E (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[9756]:0xa0d88a)
    at graphite_wasm.wasm._ZN146_$LT$graphite_editor..messages..portfolio..document..document_message_handler..ClickXRayIter$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hb7f34416b8af9d99E (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[688]:0x38aa6e)
    at graphite_wasm.wasm._ZN15graphite_editor8messages9portfolio8document24document_message_handler22DocumentMessageHandler5click17h0ab727e21aa2c03aE (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[1778]:0x5e8892)
    at graphite_wasm.wasm._ZN289_$LT$graphite_editor..messages..tool..tool_messages..select_tool..SelectTool$u20$as$u20$graphite_editor..utility_traits..MessageHandler$LT$graphite_editor..messages..tool..tool_message..ToolMessage$C$$RF$mut$u20$graphite_editor..messages..tool..utility_types..ToolActionHandlerData$GT$$GT$15process_message17h73ef76ac2ab60bf6E (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[2165]:0x670136)
    at graphite_wasm.wasm._ZN280_$LT$graphite_editor..messages..tool..tool_message_handler..ToolMessageHandler$u20$as$u20$graphite_editor..utility_traits..MessageHandler$LT$graphite_editor..messages..tool..tool_message..ToolMessage$C$graphite_editor..messages..tool..tool_message_handler..ToolMessageData$GT$$GT$15process_message17h3c9a67c11d1a60aaE (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[408]:0x205f97)
    at graphite_wasm.wasm._ZN15graphite_editor10dispatcher10Dispatcher14handle_message17h1ecc4f83899b780cE (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[441]:0x237227)
    at graphite_wasm.wasm._ZN13graphite_wasm10editor_api12EditorHandle8dispatch17hd95fc3cf7142e92cE (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[4082]:0x827236)
    at graphite_wasm.wasm.editorhandle_onKeyDown (https://dev.graphite.rs/assets/graphite_wasm_bg-FAZobSHR.wasm:wasm-function[6133]:0x915664)
    at ga.onKeyDown (https://dev.graphite.rs/assets/index-DuUmgc5P.js:687:8016)
    at g (https://dev.graphite.rs/assets/index-DuUmgc5P.js:690:2304)
@Keavon Keavon added Rust Crash A panic which crashed the editor labels Oct 14, 2024
@github-project-automation github-project-automation bot moved this to Short-Term in Task Board Oct 14, 2024
@Keavon Keavon changed the title Deleting a new document's artboard crashes the editor Having no artboard crashes the editor Oct 14, 2024
@github-project-automation github-project-automation bot moved this from Short-Term to Completed This Milestone in Task Board Oct 14, 2024
@Keavon Keavon added this to the Milestone 42 milestone Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Crash A panic which crashed the editor
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants