Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows 10, Notification about article updates, but not shown in the interface #70

Closed
groentebroer opened this issue Oct 14, 2016 · 34 comments
Assignees
Labels
Component-DB Status-Partially-Fixed Part of bug/feature is fixed/implemented. Type-Defect This is BUG!!!
Milestone

Comments

@groentebroer
Copy link

groentebroer commented Oct 14, 2016

Brief description of the issue.

Sometimes, new articles are downloaded according to the Windows 10 notification.
But looking at the interface all feeds have no new items. After one or two (manual or automatic) update cycles, these articles (or at least the same number of items) appear in the interface.

How to reproduce the bug?

  1. Let RSS Guard run a while.
  2. Mark all items in all feeds read.
  3. Wait until a "global update" run with a notification for new articles
  4. Check RSS guard (I normally don't click on the notification)
  5. No new articles in any of the feeds are shown
  6. Run the "update all feeds" manually.
  7. The items are shown. (Sometimes it takes several runs.)

What is the expected result?

New items should be displayed directly.

What actually happened?

No new items are shown.

Other information (logs, see Wiki)

I use the regular SQL -Lite database.

  • Could be a timing issue?
  • Or even a notification with outdated data (e.g. numbers from a previous run), that it is coincidence that the same number of items seem to appear after several runs.
  • UPDATE: Could it be related to not being able to update 1 of the feeds, so the refresh of the interface does not occur? (As it only happens sometimes.)
@martinrotter
Copy link
Owner

This could actually mean, that newly downloaded messages are in fact only "UPDATES" to already existing messages which may be already read, so it can look like that nothing changes in the message list.

Numbers in tray bubble informing about new messages is the number of "UPDATED" messages which consists of: TOTALLY NEW messages and REFRESHED messages (that happens when same author creates message with same title but changes its contents perhaps).

And it theoretically can be related to some problems that messages are in fact correctly downloaded, but one feed is not correctly updated in DB. It would be nice to see full log (see Wiki) with full situation.

@martinrotter martinrotter self-assigned this Nov 4, 2016
@groentebroer
Copy link
Author

Thanks Martin for your response.
I get your point, but think that might not always be the case. After refreshing all feeds manually then it shows the new items in the interface.
Having the issue some time now, it might also be related to "sleep" mode from Windows.

I will check to see if I can get more info from the logs.

@groentebroer
Copy link
Author

groentebroer commented Nov 8, 2016

I restarted with the log enabled and was able to reproduce the issues.
It seems related to these log lines:

[rssguard] DEBUG: File-based SQLite database connection 'feed_upd' to file 'C:\Users\SCRUBBED.rssguard\data\database\local\database.db' seems to be established.
[rssguard] DEBUG: Adding new message 'Message title 1' to DB.
[rssguard] DEBUG: Adding new message 'Message title 2' to DB.
[rssguard] DEBUG: Adding new message 'Message title 3' to DB.
[rssguard] DEBUG: Transaction commit for message downloader failed.

I will try to send a Personal message with the complete log and a screenshot.

(I was now able to reproduce it without "sleeping" my laptop in between.)

@martinrotter martinrotter added this to the 3.3.6 milestone Nov 8, 2016
@martinrotter martinrotter added the Status-Partially-Fixed Part of bug/feature is fixed/implemented. label Nov 8, 2016
@martinrotter
Copy link
Owner

Please, test latest development build. Newest builds are always located at the bottom of the page.

Now, reported number of downloaded messages should be correct and I added more debugging logs to part where DB transaction fails. So try to run it, get logs and upload them here pls. We should see the actual reason of DB transaction failure.

@groentebroer
Copy link
Author

Oke, I will update to the new development build and run it with logging enabled. :).

@groentebroer
Copy link
Author

Sorry, I still get the error message. Please let me know if you need the complete log.

Relevant part of the log:

[rssguard] DEBUG: Starting auto-update event, pass 1/15.
[rssguard] DEBUG: Starting auto-update event, pass 0/15.
[rssguard] DEBUG: Starting feed updates from worker in thread: '0x13a8'.
[rssguard] DEBUG: Downloading new messages for feed 12 in thread: '0x3338'.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Downloading new messages for feed 1 in thread: '0x3480'.
[rssguard] DEBUG: Downloading new messages for feed 5 in thread: '0x36d8'.
[rssguard] DEBUG: Downloading new messages for feed 6 in thread: '0x3688'.
[rssguard] DEBUG: Downloading new messages for feed 7 in thread: '0x1dd0'.
[rssguard] DEBUG: Downloading new messages for feed 4 in thread: '0x2e24'.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Adding enclosure 'https://scrubbed.url/9b00f7e33bbe698848efa5e5e549f3ee.png' for the message.
[rssguard] DEBUG: Downloading new messages for feed 9 in thread: '0x1dd0'.
[rssguard] DEBUG: Saving messages of feed 7 in thread: '0x13a8'.
[rssguard] DEBUG: Updating messages in DB. Main thread: 'false.'.
[rssguard] DEBUG: SQLite connection 'feed_upd' is already active.
[rssguard] DEBUG: File-based SQLite database connection 'feed_upd' to file 'C:\Users\scrubbed.rssguard\data\database\local\database.db' seems to be established.
[rssguard] DEBUG: Settings of BaseNetworkAccessManager loaded.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Destroying SilentNetworkAccessManager instance.
[rssguard] DEBUG: Transaction commit for message downloader failed: 'database is locked Unable to commit transaction'.

@martinrotter
Copy link
Owner

Yes, you will still get the error, but now we see more info and remember that number of downloaded messages now should be reported correctly.

@groentebroer
Copy link
Author

Yes, I do not get any notification anymore, because the updated number stays 0 ;-).
Refreshing a single feed (which I know that has updates via the log) gives me a notification of (in this case) 5 updated entries. (So it seems the DB lock is not "active" when updating a single feed.)

Hope this helps pinpointing the issue ;).

@groentebroer
Copy link
Author

@martinrotter please let me know if you need anymore help debugging or analyzing the issue. (My routine is now restarting RSS Guard several times a day ;-))

@martinrotter
Copy link
Owner

martinrotter commented Nov 24, 2016

Here, it seems that DB transaction are not working. I already know how to fix the issue, I could just remove DB transactions and insert data to DB just like that.

@groentebroer
Copy link
Author

Sounds good, glad that it is not that much trouble!

@martinrotter
Copy link
Owner

Yea, problem is that inserting many messages into DB could be SLOW without db transactions. I will have to solve this properly.

Unfortunately, now I do not have enough time for RSS Guard. But hopefully in a few weeks I will release next version.

@martinrotter
Copy link
Owner

So, this issue in fact is solved. The number will now show correctly, but the core cause still remains and I will solve that cause now -> problematic transactions.

When this issue is solved (in one week), then new version of RSS Guard gets released.

@martinrotter martinrotter removed the Status-Accepted I will eventually implement this. label Jan 4, 2017
@groentebroer
Copy link
Author

Great to see you working on it again ;-).
I work around the issue now by restarting RSS guard every couple of hours, would be great if you could resolve this issue.
I think transactions might still be the way to go, but maybe you can prevent it to stay in "locked" mode by using the rollback or free the DB when an error occurs?

@martinrotter
Copy link
Owner

martinrotter commented Jan 5, 2017

The DB does not in fact stay in "locked" mode. It just for some crazy/weird reason seems that when feed update transaction wants to start, it is not sometimes possible. When that happens, messages for one feed are not stored in DB and from the user perspective it looks like no feeds were downloaded/updated at all.

On my PC, no such things happen. I tried to activate SQLite immediate transactions, which could help in these situations. Please, download the development build for commit 79c4e57 when it gets compiled (in 15 minutes). You will find it here on the bottom of the page. The file will have 79c4e57 in its name.

Test it and let me know if there is any improvement.

Also, you could try to switch to MySQL data storage backend or use SQLite with in-memory option (see settings of RSS Guard), any of these alternatives might also solve your problem.

@groentebroer
Copy link
Author

Will give it a try soon, thanks for the update!

@martinrotter
Copy link
Owner

Yep.

@martinrotter
Copy link
Owner

Any news for me @groentebroer?

@groentebroer
Copy link
Author

Wil be testing with the log today.

@groentebroer
Copy link
Author

@martinrotter Seems to be missing a DLL in the package.
I get the following Windows error:

"The program can't start because QtPositioning.dll is missing from your computer. Try reinstalling the program to fix this problem."

@martinrotter
Copy link
Owner

OK, will fix.

@martinrotter
Copy link
Owner

Fixed, new build should be there in few minutes.

@martinrotter
Copy link
Owner

Is built now. Should work.

@groentebroer
Copy link
Author

groentebroer commented Jan 10, 2017

Hi, I used: rssguard-3.3.6-fbbb3a4-win32.7z,

Which resulted in the log:

[rssguard] WARNING: Qt WebEngine ICU data not found at C:/Qt/5.7/msvc2013/resources. Trying parent directory...
[rssguard] WARNING: Qt WebEngine ICU data not found at C:/Qt/5.7/msvc2013. Trying application directory...
[rssguard] WARNING: Qt WebEngine ICU data not found at C:/Program Files (x86)/RSS Guard. Trying fallback directory... The application MAY NOT work.
[rssguard] WARNING: Installed Qt WebEngine locales directory not found at location C:/Qt/5.7/msvc2013/translations\qtwebengine_locales. Trying application directory...
[rssguard] WARNING: Qt WebEngine locales directory not found at location C:/Program Files (x86)/RSS Guard\qtwebengine_locales. Trying fallback directory... Translations MAY NOT not be correct.
[0110/144221:ERROR:icu_util.cc(162)] Invalid file descriptor to ICU data received.
[0110/144221:FATAL:icu_util.cc(265)] Check failed: result.
Backtrace:
GetHandleVerifier [0x56F5FAF7+7559]
CertificateErrorController::operator= [0x56F37287+2178695]
QtWebEngineCore::WebContentsAdapter::d_func [0x57680581+586225]
QtWebEngineCore::CookieMonsterDelegateQt::canSetCookie [0x56759E53+573923]
QtWebEngineCore::WebContentsAdapter::webContents [0x565299AF+12655]
QtWebEngineCore::WebContentsAdapter::webContents [0x56529C45+13317]
QtWebEngineCore::BrowserContextAdapter::defaultContext [0x564F144F+15]
QWebEngineProfile::defaultProfile [0x6BD59C8D+61]

And did not start

@martinrotter
Copy link
Owner

It seems I messed up some files, will repair tomorrow.

@martinrotter
Copy link
Owner

OK, latest build should work, tested in clean Windows 10 VirtualBox image. Previous build really was not working.

@groentebroer
Copy link
Author

groentebroer commented Jan 11, 2017

Oke, will give it a try now!
Edit: It starts!

@groentebroer
Copy link
Author

Had the same DB locked error again. Will try a different database soon...

@martinrotter
Copy link
Owner

OK, I will try to investigate further.

martinrotter added a commit that referenced this issue Jan 13, 2017
@martinrotter
Copy link
Owner

OKAY, I fixed this issue like this:

  • DB transactions for storing new messages are now opt-in feature switchable in setting,
  • by default, they are turned off for more safety,
  • if anyone requires faster DB message storing, then he has to enable it in settings.

@martinrotter
Copy link
Owner

I was unable to track down the original cause of the issue, I just am not able to reproduce the bug on my machines. I let RSS Guard run several hours, but all DB transaction are okay and none of them fails.

So if anyone is having troubles with DB transactions, then now it is solved as DB transactions are by default off.

@groentebroer
Copy link
Author

Oke, I updated to: rssguard-3.3.6-1db5e61-win32.7z and am running it now. Let's see how it goes, running with the log on.
Thanks for your effort already!

@groentebroer
Copy link
Author

With this version after a period of time I get:

[rssguard] WARNING: Failed to set custom ID for all messages: 'database is locked Unable to fetch row'.
"Use transactions" is not enabled in settings.

Will try to go to memory DB now...

@martinrotter
Copy link
Owner

OK, will test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component-DB Status-Partially-Fixed Part of bug/feature is fixed/implemented. Type-Defect This is BUG!!!
Projects
None yet
Development

No branches or pull requests

2 participants