rbumm / SlicerLungCTAnalyzer

This is a 3D Slicer extension for segmentation and spatial reconstruction of infiltrated, collapsed, and emphysematous areas in lung CT.
Apache License 2.0
71 stars 23 forks source link

QT warnings with Lung CT Segmenter in Slicer 5.2.1 stable #39

Closed rbumm closed 1 year ago

rbumm commented 1 year ago

These warnings occur frequently in Lung CT Segmenter and after adapting it to 3D Slicer 5.2.1

[Qt] QLayout::addChildLayout: layout "" already has a parent
[Qt] ctkSliderWidget::setSingleStep()  0 is out of bounds. 0 1000 1

@lassoan May they be related to SegmentEditorWidget calls and can they be avoided?

lassoan commented 1 year ago

These errors have always been there, but only appeared in the error log, not in the console. We unified logging to make it easier to see all errors resulting from a command (not just at Python level but from VTK, Qt, CTK as well), therefore these errors now show up in the console.

They seem harmless, but we should eventually fix them. If you specify objectName for all the Qt layouts you create and the layout error is in Slicer core. We would need to add logging of the object name to ctkSliderWidget::setSingleStep() and then we'll hopefully see where the error is coming from exactly.

rbumm commented 1 year ago

Including

self.layout.objectName = "Lung CT Segmenter layout"

and they are still there in their initial form, so probably they are generated elsewhere.