jlbrd / qmagneto

Automatically exported from code.google.com/p/qmagneto
0 stars 0 forks source link

readTVGuide :on_action_Options_triggered endless loop #18

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I added some code to handle user/password for proxy, but code is not
reached (since I modified statically QHttp call to handle my user/password
for proxy).

I get some console errors :
Failed to select record to db QSqlError(1, "Impossible d'exécuter la
requête", "no such table: channels") 
"select * from channels" 

I'm put at start of breakpoints in XmlDefaultHandler::readFromDB()
and here is the backtrace I get in gdb after some "xml file not up to
date"/config panel.

0  XmlDefaultHandler::readFromDB (this=0x99cd560) at
src/xmldefaulthandler.cpp:458
#1  0x08061425 in MainWindowImpl::readTvGuide (this=0xbfb094a4) at
src/mainwindowimpl.cpp:485
#2  0x0806131d in MainWindowImpl::on_action_Options_triggered
(this=0xbfb094a4) at src/mainwindowimpl.cpp:726
#3  0x08061610 in MainWindowImpl::readTvGuide (this=0xbfb094a4) at
src/mainwindowimpl.cpp:490
#4  0x0806131d in MainWindowImpl::on_action_Options_triggered
(this=0xbfb094a4) at src/mainwindowimpl.cpp:726
#5  0x08061610 in MainWindowImpl::readTvGuide (this=0xbfb094a4) at
src/mainwindowimpl.cpp:490
#6  0x0806131d in MainWindowImpl::on_action_Options_triggered
(this=0xbfb094a4) at src/mainwindowimpl.cpp:726
#7  0x08061610 in MainWindowImpl::readTvGuide (this=0xbfb094a4) at
src/mainwindowimpl.cpp:490
#8  0x0806131d in MainWindowImpl::on_action_Options_triggered
(this=0xbfb094a4) at src/mainwindowimpl.cpp:726
#9  0x08061610 in MainWindowImpl::readTvGuide (this=0xbfb094a4) at
src/mainwindowimpl.cpp:490
#10 0x08061949 in MainWindowImpl::on_dateEdit_dateChanged (this=0xbfb094a4,
date={jd = 2454894}) at src/mainwindowimpl.cpp:1028
#11 0x080a4bdf in MainWindowImpl::qt_metacall (this=0xbfb094a4,
_c=QMetaObject::InvokeMetaMethod, _id=2, _a=0xbfb092dc)
    at build/moc_mainwindowimpl.cpp:126
#12 0xb7379bd0 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#13 0xb737a952 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#14 0xb79e9733 in QDateTimeEdit::dateChanged () from /usr/lib/libQtGui.so.4
#15 0xb79f101c in ?? () from /usr/lib/libQtGui.so.4
#16 0xb79c76dc in ?? () from /usr/lib/libQtGui.so.4
#17 0xb79eb39a in QDateTimeEdit::setDate () from /usr/lib/libQtGui.so.4
#18 0x08066336 in MainWindowImpl::init (this=0xbfb094a4) at
src/mainwindowimpl.cpp:532
#19 0x08078893 in main (argc=136, argv=0x108) at src/main.cpp:70

I would like to help you improve this software. Please let me know what I
can do to help you.

Original issue reported on code.google.com by jcarnu on 3 Mar 2009 at 4:38

GoogleCodeExporter commented 9 years ago
Here we have two differents problems:torrent

1. readFromDB error. You have an "old" version installed which build the 
database.
Your have also the svn sources to works on code. But the database structure 
between
the two versions is different. To solve this problem, re-read the xml file to 
build
the database in good format.

2. the proxy can be used in current version. Availale in options dialog.

Original comment by jlbi...@gmail.com on 4 Mar 2009 at 11:08

GoogleCodeExporter commented 9 years ago
(Weird writting english whereas we may both write in french isn't it?) ;)

Shortly replies from two points :
1: That was true, but while I destroyed db rm ~/.qmagneto/qmagneto.db, the 
problem
remained because web site was unreachable (auth from proxy required)
2: proxy option is available but not with authentication 

Here are some more informations :

Well, I've checkouted the svn before running the test. 
I noticed you use wget to retrieve xml files (zipped) from remote website.If no 
error
from my analysis, wget is launched without any environnement variables to help 
it to
pass proxies (wget only allows to have --proxy-user & --proxy-password options 
nor
--proxy-address nor --proxy-port that should be provided by env through 
http_proxy
envvar). On the other hand, Qt provides QHttp (you're using in GetImages). I've 
done
some hack to replace QProcess/wget calls with QHttp call with or without proxy. 
It
works fine with it (untested towards proxies, tomorrow I'll be able to do 
such). I
also added some QLineEdit in config.ui to edit user and password for proxies.

I've attached an (unclean) patch from my sources (co from svn, then hacking) in 
order
to provide authentication to proxy feature. I will test it tomorrow and maybe 
clean
it for you.
Tell me if you're interested in further collaboration.

Regards

Original comment by jcarnu on 4 Mar 2009 at 1:26

Attachments:

GoogleCodeExporter commented 9 years ago
A cleaner patch.

Original comment by jcarnu on 4 Mar 2009 at 2:08

Attachments:

GoogleCodeExporter commented 9 years ago
Fixed in revision 122

Original comment by jlbi...@gmail.com on 6 Apr 2009 at 4:26