Bug 298680 - grantlee version available in KDE on Windows is not yet up to date
Summary: grantlee version available in KDE on Windows is not yet up to date
Status: RESOLVED FIXED
Alias: None
Product: kde-windows
Classification: Miscellaneous
Component: general (show other bugs)
Version: 4.10
Platform: Microsoft Windows Microsoft Windows
: NOR major
Target Milestone: ---
Assignee: KDE-Windows
URL: http://forum.kde.org/viewtopic.php?f=...
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-23 16:51 UTC by HBB Think Tank
Modified: 2013-05-28 22:08 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description HBB Think Tank 2012-04-23 16:51:34 UTC
Skrooge 1.2.0 via KDE on Windows 4.8.0 gets error message when trying to access Monthly Reports in Skrooge:
[ERR-6]: Plugin library 'grantlee_defaulttags' not found.
Skrooge was installed using KDE Installer 0.9.9

Reproducible: Always

Steps to Reproduce:
1. Installing Skrooge 1.2.0 via KDE on Windows 4.8.0 on Windows XP SP3
2. Try using Monthly Report
Actual Results:  
Error message:
[ERR-6]: Plugin library 'grantlee_defaulttags' not found.

Expected Results:  
Monthly Report

I reported the error to the Skrooge forum on KDE.org and was told that it is likely because grantlee in the latest KDE in Windows version in not up to date. See link provided with this bug report.
Comment 1 Stephane MANKOWSKI 2012-04-24 08:40:28 UTC
This bug should be corrected with Skrooge 1.3.0.
Comment 2 Guillaume DE BURE 2012-04-24 15:44:07 UTC
Reassigning to the KDE on Windows team since it will be solved when Skrooge 1.3.0 is available on Windows. Thanks in advance guys :)
Comment 3 Patrick Spendrin 2012-04-24 16:34:36 UTC
The version provided with 1.2.0 should be grantlee 0.2. That was the latest version I could find back then, so it shouldn't be a version problem. skrooge also depends on grantlee, so it should get installed as well.
NOTE: I might be able to find this bug in all of our compilers, but could you specify which compiler you chose when installing skrooge?
Thanks a lot
Comment 4 HBB Think Tank 2012-04-24 16:47:01 UTC
It looks like VC100, judging from the file in the manifest folder (and as there were only two compilers proposed and it wasn't MinGW thingy).
Comment 5 Guillaume DE BURE 2012-04-24 17:53:33 UTC
(In reply to comment #3)
> The version provided with 1.2.0 should be grantlee 0.2. That was the latest
> version I could find back then, so it shouldn't be a version problem.
> skrooge also depends on grantlee, so it should get installed as well.
> NOTE: I might be able to find this bug in all of our compilers, but could
> you specify which compiler you chose when installing skrooge?
> Thanks a lot

That's correct, Patrick, the bug was indeed on Skrooge side, and not on your side, and is corrected in 1.3.0 that we just released today (I didn't make the announcement yet). I reassigned the bug to you because it is specific to Windows, and will be solved when 1.3.0 is available on Windows. Is that OK for you ?
Comment 6 Patrick Spendrin 2012-04-24 18:58:19 UTC
@Guillaume: I found another issue: the plugin path for grantlee is hard coded at build time as far as I can see, so I'll put Stephen into CC again. From the API it looks as if this can be overridden by the application itself, but I would prefer if grantlee would use a relative path on windows (QCoreApplication::applicationDirPath() + "../lib"), thus making it work out of the box.
@Stephen: If you want, I can try to come up with a patch for that.
@HBB: The next KDE on Windows release will need roughly one to two weeks, and will be 4.8.3 including one of the fixes for this bug.
Comment 7 HBB Think Tank 2012-08-30 17:05:01 UTC
I am a bit disappointed.

While there has been new releases of Skrooge (1.3.0 and later), there appears to be no way to install it on Windows as there is still no update on KDE on Windows (and its been now four months instead of "one to two weeks"). 4.8.0 (hence Windows too) only finds 1.2.0 - so this bug is still not fixed for Windows users.
Comment 8 Patrick Spendrin 2013-05-16 22:49:20 UTC
This bug still applies in 1.6.0.
Comment 9 Stephane MANKOWSKI 2013-05-23 15:38:20 UTC
The bug is still on 1.6.0 event if grantlee_defaulttags.dll is well installed.
I take the incident for deeper analysis.
Comment 10 Stephane MANKOWSKI 2013-05-24 06:32:29 UTC
Hi Patrick,

Here is my last analysis.
1-For the error "[ERR-6]: Plugin library 'grantlee_defaulttags' not found."
In my installation, the grantlee plugins are installed like this:
In C:\ProgramData\KDE\lib\grantlee\0.3:
grantlee_defaultfilters.dll
grantlee_defaulttags.dll
grantlee_i18ntags.dll
grantlee_loadertags.dll

In: C:\ProgramData\KDE\lib\kde4\plugins\grantlee\0.3
grantlee_skgfilters.dll

Grantlee seems to be not well installed because if I copy all dll from C:\ProgramData\KDE\lib\grantlee\0.3 to C:\ProgramData\KDE\lib\kde4\plugins\grantlee\0.3, the issue is corrected.

2-But now, I have an other error "[ERR-6]: Template not found, default/income_vs_expenditure_table.html"
This error is due to the fact that all html file are missing in C:\ProgramData\KDE\share\apps\skrooge\html\default.
These files should be installed with Skrooge but this is not the case.
I think that are missing.

I hope this will help you.
Comment 11 Patrick Spendrin 2013-05-24 08:52:32 UTC
I just spoke with Stephen and he mentioned that you might set the grantlee plugin path somehow and it seems to forget to look into the default location. I'll look into that.

On my installation the html files exist, I need to see why this happens.
Comment 12 Patrick Spendrin 2013-05-24 08:55:21 UTC
I looked into the packages, and as far as I could see, all of our packages actually contain those files?
Comment 13 Stephane MANKOWSKI 2013-05-24 10:17:08 UTC
(In reply to comment #12)
> I looked into the packages, and as far as I could see, all of our packages
> actually contain those files?

In fact the files are well installed...
...and removed at the first execution of Skrooge. :-(
Of course, the bug is in Skrooge. I found it. I will correct it this evening. I will take you informed.

I let you analyse the issue with grantlee.
For your information, here is the code to initialize it:
//Prepare grantlee engine
Grantlee::Engine gEngine;
const QStringList pluginDirs = KGlobal::dirs()->resourceDirs("qtplugins");
foreach(const QString & pluginDir, pluginDirs) {
	gEngine.addPluginPath(pluginDir);
Comment 14 Patrick Spendrin 2013-05-24 10:45:01 UTC
I can confirm your findings in the writeable location I have. In the non-writeable location this is of course not possible :-D
About the patch: please CC me if you commit it so that I can apply it to our skrooge package and update it.
Comment 15 Patrick Spendrin 2013-05-24 12:00:30 UTC
Git commit 117b8e8501012566c63ce8e996e0bbca4de9df8c by Patrick Spendrin.
Committed on 24/05/2013 at 13:58.
Pushed by sengels into branch 'kde-4.10'.

fix grantlee for skrooge

add the correct plugin path depending on the executable location

A  +31   -0    portage/kdesupport/grantlee/0001-add-plugin-path-depending-on-executable-location.patch
M  +1    -0    portage/kdesupport/grantlee/grantlee-20111204.py

http://commits.kde.org/emerge/117b8e8501012566c63ce8e996e0bbca4de9df8c
Comment 16 Patrick Spendrin 2013-05-24 12:01:43 UTC
ok, grantlee plugin path problem is fixed in our package, waiting for the skrooge patch so that I can update our packages and roll out new ones.
Comment 17 Stephane MANKOWSKI 2013-05-24 16:53:31 UTC
Hi,

I committed the correction in the trunk (91f6e6fe570e6a7cda311de67d109735e1d0bb4b).
The commit is  tagged with "PatchWindowsMonthlyReport"

@@ -80,8 +80,9 @@ bool SKGMonthlyPlugin::setupActions(SKGDocument* iDocument, const QStringList& i
 
     //Copy "default" directory in locale
     foreach(const QString & file, KStandardDirs().findAllResources("data", KGlobal::mainComponent().aboutData()->appName() % "/html/default/*.html")) {
-        QFile(file).remove();
-        QFile(file).copy(path % QFileInfo(file).fileName());
+        QString target = path % QFileInfo(file).fileName();
+        QFile(target).remove();
+        QFile(file).copy(target);
     }
 
     //Create yours actions here
Comment 18 Patrick Spendrin 2013-05-24 18:35:18 UTC
Git commit fb317109498601451e6baa8e434986a56d0d3c13 by Patrick Spendrin.
Committed on 24/05/2013 at 13:58.
Pushed by sengels into branch 'master'.

fix grantlee for skrooge

add the correct plugin path depending on the executable location

A  +31   -0    portage/kdesupport/grantlee/0001-add-plugin-path-depending-on-executable-location.patch
M  +1    -0    portage/kdesupport/grantlee/grantlee-20111204.py

http://commits.kde.org/emerge/fb317109498601451e6baa8e434986a56d0d3c13
Comment 19 Patrick Spendrin 2013-05-24 18:48:06 UTC
Git commit db17a3f9cf96deae82c8e2b7e756bb1a435daa80 by Patrick Spendrin.
Committed on 24/05/2013 at 20:46.
Pushed by sengels into branch 'kde-4.10'.

do not remove templates from skrooge installation

A  +28   -0    portage/extragear/skrooge/0001-320226-Monthly-report-does-not-work-due-to-missing-t.patch
M  +2    -1    portage/extragear/skrooge/skrooge-20111009.py

http://commits.kde.org/emerge/db17a3f9cf96deae82c8e2b7e756bb1a435daa80
Comment 20 Patrick Spendrin 2013-05-28 22:08:30 UTC
These packages have been uploaded into the 4.10.2 release of KDE on Windows.