View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002915 | Slicer4 | Core: GUI | public | 2013-02-05 09:34 | 2017-06-07 23:27 |
Reporter | pieper | Assigned To | finetjul | ||
Priority | normal | Severity | crash | Reproducibility | sometimes |
Status | closed | Resolution | fixed | ||
Product Version | |||||
Target Version | Slicer 4.3.0 | Fixed in Version | Slicer 4.3.0 | ||
Summary | 0002915: crash while running command line module | ||||
Description | I have gotten this crash a couple times on a fresh windows build (x64, debug, VS2008) with ITKv4 - but I don't know for sure that it has anything with ITK based on stack trace. | ||||
Steps To Reproduce | Start Slicer
First run works, but later it crashes with attached stack. | ||||
Additional Information |
| ||||
Tags | No tags attached. | ||||
I suspect that what's happened here is that the forceRender timeout is happening while the image are still being updated - on windows it seems there are several refreshes going on while the data is being loaded, and if the event loop has a chance to fire the timer while the vtk pipeline is in an inconsistent state it can lead to this crash. |
|
I did some more experimentation and found that I could click apply repeatedly for 20 or 30 times but eventually I got the crash with the same stack trace as reported above. |
|
I can't think of why there could be a refresh while the output of a CLI is being updated. Both are supposed to happen in the same thread. |
|
I'm not sure either, but there it is :) What I guess happens is that something is triggering processEvents or returning control to the event loop as a byproduct of the load process. I guess I'll try on mac also to see if I get the same behavior. <testing...> There is definitely something funny going on, because if you follow the directions on how to reproduce the issue and you repeatedly click the Apply button you can see the sliders in the slice controllers jump around, but they have no reason to do that because they should "know the right answer" before they are ever rendered. I also notice that on mac I get the following error message, which must also relate to rendering when the pipeline isn't set up yet: ERROR: In /Users/pieper/slicer4/latest/Slicer-superbuild/VTK/Filtering/vtkDemandDrivenPipeline.cxx, line 727 |
|
The crash reported by Steve is in the main thread. Here is what happens in Thread 4 at the time of the crash: |
|
Reminder sent to: millerjv Jim - Can you have a look at this and help us think through it? On the hangout yesterday we realized that the MRMLImageIDIO is running in the task thread, but it ends up calling SetAndObserveImageData and the can modify the pipeline during a render depending on the timing. We could replicate this on windows and mac, on both debug and release builds by following the instructions in this bug report (click the Apply button repeatedly as fast as possible and it eventually happens). -Steve |
|
In theory this should also have happened in slicer3, but I could not replicate it with several attempts on a mac release build. |
|
The problem is that the volume node now sends an ImageDataModified event in addition to a normal Modfied event: https://github.com/Slicer/Slicer/blob/master/Libs/MRML/Core/vtkMRMLVolumeNode.cxx#L657 The MRMLIDImageIO (running in the thread) sets the image data for a node after disabling modified events, but this doesn't disable the new ImageDataModfied event: https://github.com/Slicer/Slicer/blob/master/Libs/MRML/IDImageIO/itkMRMLIDImageIO.cxx#L587 |
|
Can you please review my suggested fix: |
|
Just scanned this briefly. I probably would have disabled the ImageDataModified event instead. But I like the idea of catching all events in the thread and then scheduling them in the main thread. Is this implementation general? Meaning any event can be caught and rescheduled in the main thread? |
|
Yes, it's (somewhat) generic: it catches (and reschedules) all the events fired by the "output" nodes. |
|
Fixed in r22196 |
|
Closing resolved issues that have not been updated in more than 3 months |
|
Slicer: 2145-support-for-installing-extension-from-file d6cce6d1 2013-07-15 11:41:05 Details Diff |
BUG: Disable Apply button when CLI has a Completing status If the user clicks frenetically on the Apply button, it was eventually generating an assert in vtkSlicerCLIModuleLogic::ProcessMRMLLogicsEvents because the button was clicked when the CLI was still "Completing". Issue 0002915 git-svn-id: http://svn.slicer.org/Slicer4/trunk@22194 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Base/QTCLI/qSlicerCLIModuleWidget.cxx | Diff File | ||
Slicer: 2145-support-for-installing-extension-from-file a3ef5585 2013-07-15 11:41:07 Details Diff |
ENH: Make vtkMRMLApplicationLogic::InvokeEventWithDelay thread-safe If InvokeEventWithDelay was called from a different thread, the AutoConnection in qSlicerCoreApplication was queuing the signal therefore the InvokeRequest was deleted before the requestInvokeEvent() slot was called. Issue 0002915 git-svn-id: http://svn.slicer.org/Slicer4/trunk@22195 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Base/QTCore/qSlicerCoreApplication.cxx | Diff File | ||
mod - Base/QTCore/qSlicerCoreApplication.h | Diff File |
Date Modified | Username | Field | Change |
---|---|---|---|
2013-02-05 09:34 | pieper | New Issue | |
2013-02-05 09:34 | pieper | Status | new => assigned |
2013-02-05 09:34 | pieper | Assigned To | => finetjul |
2013-02-05 09:39 | pieper | Note Added: 0007820 | |
2013-02-05 09:41 | pieper | Note Added: 0007821 | |
2013-02-05 10:18 | finetjul | Note Added: 0007822 | |
2013-02-05 10:29 | pieper | Note Added: 0007823 | |
2013-02-05 13:05 | finetjul | Note Added: 0007824 | |
2013-02-06 04:43 | pieper | Note Added: 0007825 | |
2013-02-06 04:43 | pieper | Note Added: 0007826 | |
2013-07-08 06:49 | pieper | Note Added: 0008878 | |
2013-07-12 15:08 | finetjul | Note Added: 0009031 | |
2013-07-12 15:09 | finetjul | Note Edited: 0009031 | |
2013-07-12 16:51 | millerjv | Note Added: 0009032 | |
2013-07-12 19:49 | finetjul | Note Added: 0009033 | |
2013-07-15 07:41 | finetjul | Note Added: 0009050 | |
2013-07-15 07:41 | finetjul | Status | assigned => resolved |
2013-07-15 07:41 | finetjul | Fixed in Version | => Slicer 4.3.0 |
2013-07-15 07:41 | finetjul | Resolution | open => fixed |
2013-07-18 06:18 | pieper | Relationship added | related to 0002966 |
2014-03-06 05:18 | jcfr | Note Added: 0011113 | |
2014-03-06 05:20 | jcfr | Status | resolved => closed |
2014-03-06 06:15 | jcfr | Target Version | => Slicer 4.3.0 |
2017-06-07 23:27 | finetjul | Changeset attached | => Slicer 2145-support-for-installing-extension-from-file a3ef5585 |
2017-06-07 23:27 | finetjul | Changeset attached | => Slicer 2145-support-for-installing-extension-from-file d6cce6d1 |