When I try to open the options menu in 0.12.0rc1, Bitcoin Core just crashes.
I get this in the debug.log when it happens:
GUI: ASSERT failure in QList<T>::at: "index out of range", file /usr/include/x86_64-linux-gnu/qt5/QtCore/qlist.h, line 478
When I try to open the options menu in 0.12.0rc1, Bitcoin Core just crashes.
I get this in the debug.log when it happens:
GUI: ASSERT failure in QList<T>::at: "index out of range", file /usr/include/x86_64-linux-gnu/qt5/QtCore/qlist.h, line 478
Thanks for the report. Interesting. What OS? Did you compile yourself?
I am running ubuntu 15.10. Yes, I compiled it myself.
What is the version you have upgraded from? What language is set when the crash happens?
It is a fresh install, although the datadir is copied from my windows machine. The windows machine had 0.11.2 running when it created the datadir.
The language is English
@achow101: just testes on Ubuntu 15.04. Can't reproduce.
What happens it you use regtest (./bitcoin-qt -regtest) or if you temp. rename your datadir (to force creating a new one)?
This would be an opportunity to test the new -resetguisettings flag. This clears the GUI-specific options so you should (hopefully) be able to enter the menu again.
@jonasschnelli Same thing happens with a new datadir. The problem also occurs when I use the downloaded binaries and my own gitian binaries.
@laanwj -resetguisettings flag didn't change it.
@achow101 If you're able to compile yourself, can you run bitcoin-qt in gdb and get a traceback of the assertion? The problem is that it points into qt and not into our code so as long as we can't reproduce it, it's impossible to diagnose the issue using just this information.
@laanwj This is what I get when I run it in gdb
Program received signal SIGABRT, Aborted.
0x00007ffff3c7d267 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:55
55 ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
Edit: I would give you the core file generated but it happens to be kinda big for github. Also, do they reveal sensitive information?
Yes, if you are running a wallet the a core file contains private keys etc. Be really careful with it.
But do make a backtrace using 'bt', otherwise you just get the upmost entry on the stack.
This is the backtrace
[#0](/bitcoin-bitcoin/0/) 0x00007faa6cab0267 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:55
[#1](/bitcoin-bitcoin/1/) 0x00007faa6cab1eca in __GI_abort () at abort.c:89
[#2](/bitcoin-bitcoin/2/) 0x00007faa6eefec88 in QMessageLogger::fatal(char const*, ...) const ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#3](/bitcoin-bitcoin/3/) 0x00007faa6eef9e31 in qt_assert_x(char const*, char const*, char const*, int) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#4](/bitcoin-bitcoin/4/) 0x000055c165d39b53 in QList<QString>::at (i=0, this=0x7ffe5f624830)
at /usr/include/x86_64-linux-gnu/qt5/QtCore/qlist.h:478
[#5](/bitcoin-bitcoin/5/) OptionsModel::data (this=<optimized out>, index=..., role=<optimized out>) at qt/optionsmodel.cpp:186
[#6](/bitcoin-bitcoin/6/) 0x00007faa6fc614a0 in QItemDelegate::setEditorData(QWidget*, QModelIndex const&) const ()
from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#7](/bitcoin-bitcoin/7/) 0x00007faa6fc95620 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#8](/bitcoin-bitcoin/8/) 0x00007faa6fc9671f in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#9](/bitcoin-bitcoin/9/) 0x00007faa6fc9682c in QDataWidgetMapper::setCurrentIndex(int) () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#10](/bitcoin-bitcoin/10/) 0x000055c165d33825 in OptionsDialog::setModel (this=this@entry=0x7ffe5f624a50, model=0x55c166c17510)
at qt/optionsdialog.cpp:150
[#11](/bitcoin-bitcoin/11/) 0x000055c165d0b6b2 in BitcoinGUI::optionsClicked (this=0x55c166a2bbc0) at qt/bitcoingui.cpp:593
[#12](/bitcoin-bitcoin/12/) 0x000055c165d887c5 in BitcoinGUI::qt_static_metacall (_o=0x55c166a2bbc0, _c=<optimized out>, _id=<optimized out>,
_a=<optimized out>) at qt/moc_bitcoingui.cpp:209
[#13](/bitcoin-bitcoin/13/) 0x00007faa6f12178a in QMetaObject::activate(QObject*, int, int, void**) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#14](/bitcoin-bitcoin/14/) 0x00007faa6f9b5172 in QAction::triggered(bool) () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#15](/bitcoin-bitcoin/15/) 0x00007faa6f9b7618 in QAction::activate(QAction::ActionEvent) () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#16](/bitcoin-bitcoin/16/) 0x00007faa6f122651 in QObject::event(QEvent*) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#17](/bitcoin-bitcoin/17/) 0x00007faa6f9b7b61 in QAction::event(QEvent*) () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#18](/bitcoin-bitcoin/18/) 0x00007faa6f9beb8c in QApplicationPrivate::notify_helper(QObject*, QEvent*) ()
from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#19](/bitcoin-bitcoin/19/) 0x00007faa6f9c4230 in QApplication::notify(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
[#20](/bitcoin-bitcoin/20/) 0x00007faa6f0f0f1b in QCoreApplication::notifyInternal(QObject*, QEvent*) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#21](/bitcoin-bitcoin/21/) 0x00007faa6f0f3057 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#22](/bitcoin-bitcoin/22/) 0x00007faa6f147e73 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#23](/bitcoin-bitcoin/23/) 0x00007faa6bc9fff7 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
[#24](/bitcoin-bitcoin/24/) 0x00007faa6bca0250 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
[#25](/bitcoin-bitcoin/25/) 0x00007faa6bca02fc in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
[#26](/bitcoin-bitcoin/26/) 0x00007faa6f14827f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#27](/bitcoin-bitcoin/27/) 0x00007faa6f0ee75a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#28](/bitcoin-bitcoin/28/) 0x00007faa6f0f62cc in QCoreApplication::exec() () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
[#29](/bitcoin-bitcoin/29/) 0x000055c165cec6d6 in main (argc=2, argv=0x7ffe5f625858) at qt/bitcoin.cpp:667
Hmm... strange.
OptionsModel::data (this=<optimized out>, index=..., role=<optimized out>) at qt/optionsmodel.cpp:186
Refers to: mapper->addMapping(ui->connectSocks, OptionsModel::ProxyUse); in our code.
Can't see a reason why this should cause a crash.
@MarcoFalke: yes. Right! @achow101 do you set a proxy ip without port?
We need to fix this anyways.
How would a malformed IP end up in the settings; Is the sanitization that worse with pre-#7025 versions?
Well he already did -resetguisettings, so the malformed data, wherever it comes from, shouldn't be coming from the QSettings. You'd say it must be from bitcoin.conf or the command line.
@jonasschnelli I don't have any proxy set.
OK, I fixed it. Apparently the config file where QSettings saved the settings was not accessible by my user account, it was owned by root. After I changed the permissions on it the problem went away.
Interesting. Weird that Qt doesn't raise a clearer exception but crashes on an assertion.
@achow101 I've got a newbie question... Which config file please?
The file is ~/.config/Bitcoin/Bitcoin-Qt.conf
I've, curiously enough, been unable to reproduce this.
chown root:root .config/Bitcoin/Bitcoin-Qt.conf .config/Bitcoin/Bitcoin-Qt-testnet.conf
chmod 600 .config/Bitcoin/Bitcoin-Qt.conf .config/Bitcoin/Bitcoin-Qt-testnet.conf
No crashes at all. Just the expected result that the GUI options are no longer used.
Ubuntu 14.04, Qt 5.2.1.