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

Server panic when shuffling a mixed of code and markdown cells #575

Open
dhruvmanila opened this issue Aug 7, 2024 · 1 comment
Open
Labels
bug Something isn't working

Comments

@dhruvmanila
Copy link
Member

Huh, this did give me the following (unrelated) panic though:

2024-08-07 15:37:33.967 [info] panicked at crates/ruff_server/src/server/api/requests/format.rs:67:10:
format should only be called on text documents or notebook cells

2024-08-07 15:37:33.975 [info]    0: std::backtrace::Backtrace::force_capture
   1: ruff_server::server::Server::run
   2: std::panicking::rust_panic_with_hook
   3: <std::panicking::begin_panic_handler::StaticStrPayload as core::panic::PanicPayload>::take_box
   4: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt
   5: _rust_begin_unwind
   6: core::panicking::panic_fmt
   7: core::option::expect_failed
   8: <ruff_server::server::api::requests::format::Format as ruff_server::server::api::traits::BackgroundDocumentRequestHandler>::run_with_snapshot
   9: ruff_server::session::Session::take_snapshot
  10: ruff_python_trivia::pragmas::is_pragma_comment
  11: <ruff_server::server::api::requests::hover::Hover as ruff_server::server::api::traits::BackgroundDocumentRequestHandler>::run_with_snapshot
  12: <ruff_server::server::api::requests::hover::Hover as ruff_server::server::api::traits::BackgroundDocumentRequestHandler>::run_with_snapshot
  13: std::sys::pal::unix::thread::Thread::new
  14: __pthread_joiner_wake

And, then the editor hangs at "Saving 'issue.ipynb'"

Originally posted by @dhruvmanila in #573 (comment)

@dhruvmanila
Copy link
Member Author

I'm able to reproduce this every time but it's just reliably know the order in which to move the cells.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant