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

Editing a file twice in VIM on OSX causes a panic #101

Closed
cetra3 opened this issue Nov 24, 2016 · 1 comment
Closed

Editing a file twice in VIM on OSX causes a panic #101

cetra3 opened this issue Nov 24, 2016 · 1 comment

Comments

@cetra3
Copy link

cetra3 commented Nov 24, 2016

On OSX, When watching a Directory using the standard code in the readme, if you edit a file in VIM twice, you will receive a panic:

Create("/Users/cetra/Desktop/test/a_file")
NoticeRemove("/Users/cetra/Desktop/test/4913")
Remove("/Users/cetra/Desktop/test/4913")
Create("/Users/cetra/Desktop/test/a_file")
thread '<unnamed>' panicked at 'rename_path is set but not present in operations_buffer 1', ../src/libcore/option.rs:705
stack backtrace:
   1:        0x10192bc08 - std::sys::backtrace::tracing::imp::write::h6f1d53a70916b90d
   2:        0x10192eb0f - std::panicking::default_hook::{{closure}}::h137e876f7d3b5850
   3:        0x10192da85 - std::panicking::default_hook::h0ac3811ec7cee78c
   4:        0x10192e096 - std::panicking::rust_panic_with_hook::hc303199e04562edf
   5:        0x10192df34 - std::panicking::begin_panic::h6ed03353807cf54d
   6:        0x10192de52 - std::panicking::begin_panic_fmt::hc321cece241bb2f5
   7:        0x10192ddb7 - rust_begin_unwind
   8:        0x101959620 - core::panicking::panic_fmt::h27224b181f9f037f
   9:        0x10195968d - core::option::expect_failed::h8606bc228cd3f504
  10:        0x10174ad03 - <core::option::Option<T>>::expect::hf5b09477b4671fcd
  11:        0x1017b3e2e - notify::debounce::Debounce::check_partial_rename::h21ee7ede26b20766
  12:        0x1017b49e2 - notify::debounce::Debounce::event::h2419ccbe62b5ab92
  13:        0x1017b2e86 - notify::debounce::EventTx::send::h152c2dceaf42a036
  14:        0x1017afe83 - notify::fsevent::callback::he2e1ef2d83315289
  15:     0x7fff90726b0a - implementation_callback_rpc
  16:     0x7fff907246c9 - _Xcallback_rpc
  17:     0x7fff9072479d - FSEventsD2F_server
  18:     0x7fff90729fd8 - FSEventsClientProcessMessageCallback
  19:     0x7fff946bb12b - __CFMachPortPerform
  20:     0x7fff946bb018 - __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__
  21:     0x7fff946baf88 - __CFRunLoopDoSource1
  22:     0x7fff946b29ba - __CFRunLoopRun
  23:     0x7fff946b1ed7 - CFRunLoopRunSpecific
  24:     0x7fff946f39b0 - CFRunLoopRun
  25:        0x1017b99a8 - notify::fsevent::FsEventWatcher::run::{{closure}}::h4f46b41cc2f19b31
  26:        0x1017aca8a - <std::panic::AssertUnwindSafe<F> as core::ops::FnOnce<()>>::call_once::hcf84c8244c5eae82
  27:        0x101756d23 - std::panicking::try::do_call::h48d766d41966c5a9
  28:        0x10192f0ca - __rust_maybe_catch_panic
  29:        0x101756952 - std::panicking::try::hbe278a19a1197288
  30:        0x1017548be - std::panic::catch_unwind::h03c775351675d8db
  31:        0x1017b900a - std::thread::Builder::spawn::{{closure}}::ha08cc323ee8b26c3
  32:        0x101786d53 - <F as alloc::boxed::FnBox<A>>::call_box::hf5e4e39f9a88e223
  33:        0x10192d254 - std::sys::thread::Thread::new::thread_start::h759e10bc4abc7e72
  34:     0x7fff9d95399c - _pthread_body
  35:     0x7fff9d953919 - _pthread_start
@cetra3
Copy link
Author

cetra3 commented Nov 24, 2016

Using the Raw events instead, It appears that VIM creates the following events when writing out the file:

RawEvent { path: Some("/Users/cetra/Desktop/test/4913"), op: Ok(CHMOD | CREATE | REMOVE), cookie: None }
RawEvent { path: Some("/Users/cetra/Desktop/test/new_file"), op: Ok(CHMOD | CREATE | RENAME | WRITE), cookie: None }

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