View Issue Details

IDProjectCategoryView StatusLast Update
0004515Slicer4Core: Base Codepublic2018-03-09 08:46
ReporterkikinisAssigned Tojcfr 
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Version 
Target VersionSlicer 4.9.0Fixed in VersionSlicer 4.9.0 
Summary0004515: Style plugin not loaded in macOS installer
Description

The associated shared library is packaged but fail to be discovered or loaded by the application.

Under Menu -> Edit -> Settings -> Appearance, there are no style listed

TagsNo tags attached.

Activities

jcfr

jcfr

2018-03-05 00:41

administrator   ~0015533

Fixed in r27004

pieper

pieper

2018-03-06 11:26

administrator   ~0015535

Last edited: 2018-03-06 11:27

View 2 revisions

Tested today's nightly and the "mac" style is still being used because slicer style is not found.

Workaround confirmed below is to set the QT_PLUGIN_PATH so that the style shared library can be found. Discussed with Jc on today's developer hangout and a fix is needed so this is detected and loaded automatically.

0000001 ~ $ nm  /Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins/styles/libqSlicerBaseQTGUIStylePlugins.so  | grep plugin
0000000000040208 b __ZGVZ18qt_plugin_instanceE9_instance
000000000003fe40 s __ZL17qt_pluginMetaData
00000000000401f8 b __ZZ18qt_plugin_instanceE9_instance
000000000003f9c0 T _qt_plugin_instance
000000000003f9b0 T _qt_plugin_query_metadata

0000002 ~ $ QT_PLUGINS_DEBUG=1 /Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/MacOS/Slicer 
Failed to set "Slicer" style:  Available styles are ""
libpng warning: iCCP: known incorrect sRGB profile
Switch to module:  "Welcome"
Switch to module:  ""
Switch to module:  ""

0000003 ~ $ export QT_PLUGIN_PATH=/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins/styles

0000004 ~ $ QT_PLUGINS_DEBUG=1 /Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/MacOS/Slicer
Failed to set "Slicer" style:  Available styles are ""
^C

0000005 ~ $ export QT_PLUGIN_PATH=/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins

0000006 ~ $ QT_PLUGINS_DEBUG=1 /Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/MacOS/Slicer
libpng warning: iCCP: known incorrect sRGB profile
Switch to module:  "Welcome"
jcfr

jcfr

2018-03-07 01:37

administrator   ~0015537

Thanks for the report.

Since I wasn't able to reproduce the issue, could you also give a try setting the env. variable QT_DEBBUG_PLUGINS=1 instead, that should give us more information and help understand what is the root problem.

Here is a partial copy of the output I got:

$ QT_DEBUG_PLUGINS=1 /Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/MacOS/Slicer --disable-modules
[...]
qt.network.ssl: Error receiving trust for a CA certificate
qt.network.ssl: Error receiving trust for a CA certificate
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins/bearer" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/MacOS/bearer" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/Extensions-27006/styles" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins/styles" ...
QFactoryLoader::QFactoryLoader() looking at "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins/styles/libqSlicerBaseQTGUIStylePlugins.so"
Found metadata in lib /Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/lib/QtPlugins/styles/libqSlicerBaseQTGUIStylePlugins.so, metadata=
{
    "IID": "org.qt-project.Qt.QStyleFactoryInterface",
    "MetaData": {
        "Keys": [
            "slicer",
            "dark slicer"
        ]
    },
    "className": "qSlicerStylePlugin",
    "debug": false,
    "version": 330240
}

Got keys from plugin meta data ("slicer", "dark slicer")
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/MacOS/styles" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/Extensions-27006/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Slicer-4.9.0-2018-03-05-macosx-amd64/Slicer.app/Contents/Extensions-27006/platformthemes" ...

[...]

Here also some useful references:

jcfr

jcfr

2018-03-09 02:26

administrator   ~0015539

Here is the output obtained on Ron workstation:

Need:~ rkikinis$ ~/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/MacOS/Slicer
Failed to set "Slicer" style:  Available styles are ""
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/platforms/libqcocoa.dylib"
Found metadata in lib /Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/platforms/

[...]

QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/MacOS/platformthemes" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/iconengines" ...
QFactoryLoader::QFactoryLoader() looking at "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/iconengines/libqSlicerIconEnginePlugin.so"
QMachOParser: '/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/iconengines/libqSlicerIconEnginePlugin.so' is not a Qt plugin
"'/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/iconengines/libqSlicerIconEnginePlugin.so' is not a Qt plugin"
         not a plugin
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/MacOS/iconengines" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/imageformats" ...
QFactoryLoader::QFactoryLoader() looking at "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/imageformats/libqgif.dylib"
Found metadata in lib /Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/imageformats/

[... ]

loaded library "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/imageformats/libqwebp.dylib"
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/accessible" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/MacOS/accessible" ...
Cannot load library crypto: (dlopen(crypto, 5): image not found)
loaded library "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/Slicer-4.9/libcrypto.dylib"
loaded library "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/Slicer-4.9/libssl.dylib"
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/bearer" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/MacOS/bearer" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/Extensions-27021/styles" ...
QFactoryLoader::QFactoryLoader() checking directory path "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/styles" ...
QFactoryLoader::QFactoryLoader() looking at "/Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/styles/libqSlicerBaseQTGUIStylePlugins.so"
Found metadata in lib /Users/rkikinis/Downloads/Slicer-4.9.0-2018-03-08-macosx-amd64.app/Contents/lib/QtPlugins/styles/libqSlicerBaseQTGUIStylePlugins.so, metadata=
{
    "IID": "org.qt-project.Qt.QStyleFactoryInterface",
    "MetaData": {
        "Keys": [
            "slicer",
            "dark slicer"
        ]
    },
    "className": "qSlicerStylePlugin",
    "debug": false,
    "version": 330240
}

Got keys from plugin meta data ("slicer", "dark slicer")
jcfr

jcfr

2018-03-09 02:27

administrator   ~0015540

Fixed in r27030

pieper

pieper

2018-03-09 08:46

administrator   ~0015541

Works in today's nightly - thanks for sorting it out!

Issue History

Date Modified Username Field Change
2018-03-02 10:56 jcfr New Issue
2018-03-02 10:56 jcfr Status new => assigned
2018-03-02 10:56 jcfr Assigned To => jcfr
2018-03-02 10:56 jcfr Reporter jcfr => kikinis
2018-03-02 11:12 jcfr Target Version => Slicer 4.11.0
2018-03-05 00:40 jcfr Target Version Slicer 4.11.0 => Slicer 4.9.0
2018-03-05 00:41 jcfr Status assigned => resolved
2018-03-05 00:41 jcfr Resolution open => fixed
2018-03-05 00:41 jcfr Fixed in Version => Slicer 4.9.0
2018-03-05 00:41 jcfr Note Added: 0015533
2018-03-06 11:26 pieper Note Added: 0015535
2018-03-06 11:27 pieper Note Edited: 0015535 View Revisions
2018-03-07 01:37 jcfr Note Added: 0015537
2018-03-09 02:26 jcfr Note Added: 0015539
2018-03-09 02:27 jcfr Note Added: 0015540
2018-03-09 08:46 pieper Status resolved => closed
2018-03-09 08:46 pieper Note Added: 0015541