PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

The directory you removed contains the website scraping scripts. Configuration is in ~/.kde(4?)/share/config/plasma-desktop-appletsrc. The configuration for all applets is in there. You can try to only delete the filter settings lines, they're looking like this (before rc1):
[AppletGlobals][plasma_applet_publictransport][filterConfig_NAME]
FilterAction=0
Filters=... - Jul 22 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Ah sorry, now I remember you ;)
But I don't know why there's no crash dialog. Ok, then please try to start plasma from a terminal, it may print out something useful on the crash:
> kquitapp plasma-desktop
> plasma-desktop

Maybe you need to enable debugging messages then using "kdebugdialog", search for "publictransport" and check it.

I'll try to reproduce the crash with some old filter settings when I have time. - Jul 22 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I guess you mean plasma-desktop crashes?

Was it the first time you tried the applet? I just tried it without any stored settings and it didn't crash for me.
Or do you have some filter settings from an older version? That may cause the problem..
Did you install the openstreetmap engine? Installed with the installer script (install.sh)? Can you get a backtrace using the KDE crash dialog that (should) pop up?
With a backtrace of the crash I should be able to fix it quickly. For a useful backtrace the applet should be compiled with debug information. To do that open a terminal (eg. Konsole) and go to the folder with the "install.sh". Assuming you have already run it and downloaded the git repository type:
> cd publictransport/applet/build
> cmake -DCMAKE_BUILD_TYPE=DebugFull -DCMAKE_INSTALL_PREFIX=`kde4-config --prefix` ..
> make
> sudo make install (or use su)

Then try it again and KDE's crash handler should popup, click on the debug tab and wait for the backtrace to show. Then send me that backtrace :)
Maybe you need to crash it twice, because it may still use the old version before it restarts.
In the dialog it should say that the information is useful. - Jul 22 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Great :)
And the link is updated.

I'll hopefully find some time to finish the 0.10 version soon. - Apr 14 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Yes, I already fixed the problem in HEAD. The problem was a function not declared as "slot" and therefore not called to remove departures.

Dragging the plasmoid around should work like with the other plasmoids. But maybe all the blinking departures caused that problem as well. - Mar 29 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I don't think that's possible with GIT.
That's why it's not used for collections of big binary files that change a lot, like the kde artwork.. To download something you have to clone everything with all history (old versions).

What you can do is use git archive --format=tar --remote=git://anongit.kde.org/publictransport unstable-0.1-beta7, which loads everything of the given version into a tarball, without cloning the complete repository. - Mar 20 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

If you're using the install.sh or packagers.sh script it asks you which version it should checkout (packagers.sh can now also download in a single tarball).

You first clone the GIT repository and then checkout the version (revision) you want from the cloned repository. The available version strings (=tags) can be listed with "git tag". "HEAD" always references the latest revision / current development version.

eg:
> cd path/of/cloned/repository/
> git checkout stable-0.9 (go to version 0.9)
> git checkout unstable-0.10-beta7 (go to version 0.10-beta7)
> git checkout HEAD (go to newest revision)

Each new version gets tagged by me. I also found and tagged a suitable commit as final commit for version 0.9 ("stable-0.9"). - Mar 13 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

The script is now available for download here. - Mar 09 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

It needs to be copied to .../plasma_engine_publictransport/...
It can be copied globally to /usr/share/kde4/apps/... or locally to ~/.kde4/share/apps/... (locally installed files are used preferably).

Normally the "Install From Local File" button should copy the files to the local installation directory, so that it doesn't need root permission. (only TimetableMate has a PolicyKit action to install files globally)
I'll check this.

But try to copy the files manually to /usr/share/kde4/apps/plasma_engine_publictransport/accessorInfos/. That should work.

Installation with a script file works since some version (I don't remember which). Maybe 0.9 didn't support that correctly (only installing the XML-file). - Mar 07 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I just wrote another little script which collects all .po files from KDE's SVN, compiles them to .mo files and asks if it should also install them :)
You can select which languages you want to download and for which version of PublicTransport (it then chooses a suitable SVN revision).

It's also integrated into the installer script.

Are the .mo files enough? They're currently put into directory "l10n/build/output/<LANGUAGE_CODE>/....po. - Mar 06 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Ok, I'll use Plasma::Theme::HighlightColor for KDE < 4.6. Thanks - Mar 05 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

You can go to https://projects.kde.org/projects/playground/base/publictransport/repository/revisions/master/show/engine/accessorInfos, download de_db.js and de_db.xml, then install it using the configuration dialog of the applet (the little star on the right of the service provider combobox -> Install from local file).

Don't know why it's not in there (packager buschmann23 will know ;)). What version do you have? - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

the errors seem very weird to me...

by the way: I just pushed updates to make applet-flights and applet-graphicaltimetableline compilable with KDE < 4.4 again. You can download the latest version in a tarball using:

> git archive --format=tar --remote=git://anongit.kde.org/publictransport HEAD | gzip > publictransport_head.tar.gz

I'm new to GIT but I really like it more and more :) - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

0.10 Beta 7 should build with KDE 4.5.
Next beta should then build with KDE 4.4 again (at least the errors you mentioned here are fixed). - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

This has something to do with DSO linking... I don't understand what.. but it's explained here: http://fedoraproject.org/wiki/UnderstandingDSOLinkChange

To resolve these errors, run cmake and make (or install.sh) one time, then edit build/CMakeCache.txt and run make again (or install.sh).

Modify the line:
CMAKE_EXE_LINKER_FLAGS:STRING=

To read:
CMAKE_EXE_LINKER_FLAGS:STRING=-lQtWebKit

for libpublictransporthelper I needed to change the line to:
CMAKE_EXE_LINKER_FLAGS:STRING=-lplasma

I found this solution on the kde-apps.org page for RecordItNow (in the comments). - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

You can simply clone the GIT repository and checkout the version you want:
> git clone git://anongit.kde.org/publictransport
> git tag -l (list versions)
> git checkout <VERSION> (eg. <VERSION> = unstable-0.10-beta7)

Or, if you want it in a tarball with a single command (example for version unstable-0.10-beta7):
> git archive --format=tar --remote=git://anongit.kde.org/publictransport unstable-0.10-beta7 | gzip > publictransport_0.10_beta7.tar.gz
(just as before)

These commands and more are described in the README file of the archive you download here. - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

... now I got it.. you only changed it for the unit tests of the library :) Yes, that's definitely wrong.

These tests aren't needed in a package. Maybe I should put them into a separate GIT branch to exclude them from the normal sources? - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

The library can be installed before compiling the applets/runner/timetablemate. With angle brackets as it is now it needs to ;)

I had the library sources moving around a bit, starting as a sub-directory of the publictransport applet. Therefore I used angle brackets.

But now everything is in one GIT repository in it's own dir, so it should be ok to use double quotes as you suggested. As long as the library doesn't become an extern library, but why should it..

Pros / Cons:
+ Makes it compilable without previously installing the library.
+ Can't get confused with incompatible old library version.
-? Library sources need to be in the same root dir.. No problem I think.

So I'll change it to double quotes :) - Mar 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I'll update the other components to compile with KDE 4.5 again. I only fixed this for the main applet in beta 5.. - Mar 02 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Hi,
I don't think that creating a package is too hard, but I never did it ;) You need to know the dependencies. The CMakeList.txt files show some dependencies in the target_link_libraries command (eg. libplasma). The old Ubuntu packages might also help you.

I found this link, which explains how to build debian packages: http://www.debian.org/doc/maint-guide/index.en.html.
You don't need to worry about gcc, it's automatically used by make. And the Makefile gets generated by cmake. A call to make install then installs all needed files.
There're INSTALL files in the directories, which explain how to build it on your own (cmake, make, make install).

If you have more questions, just ask :)
And leave a note if you were succesful. - Feb 28 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

It's already in there ;)
Try it: "Location:" => "Germany", "Service Provider:" => "Berliner Verkehrsbetriebe (BVG)". - Feb 25 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Ok, I tested it in a virtualized fedora 14 and Beta 5 builds on KDE 4.5 again :) - Feb 24 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Ah, the Plasma::Theme::View... colors are new.. I could replace them with some other colors for KDE < 4.6 quite easily. If there are no other errors it should then work again with 4.5. - Feb 23 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Does everything need KDE 4.6 or only timetablemate with KWebkitPart? I just removed some preprocessor switches for support of KDE 4.4 / Qt 4.5 ;) Seems, they were a bit outdated. - Feb 22 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Hi

- Ok: New version string (in the tarball name) :)

- Ok: I won't add strings like "timetablemate" to the toplevel directory name. But it's not meant to be packaged into one big package. You can think of it like multiple source packages in one tarball: There are eg. two data engines and three applets. Not everyone will want all? At least timetablemate should get it's own package, as it's only used to help when adding support for new service providers. Hm.. and package names change between distros, don't they? I added a HINTS_FOR_PACKAGE_MAINTAINERS file to the source tarball, which explains the directories and how the components depend on each other.

- The installer stays, but I added a warning message before it starts: "Prefer packages, remember uninstallation of an old version, ..". It only helps getting the compilation and installation right. Without it a user that wants just to do that might get it wrong (eg. wrong installation prefix, although there're also INSTALL files) or maybe has no idea how to uninstall it at all.. Ah, the installer has an uninstall option, don't know since when (but of course it has to be run manually with the installer). I agree that packages are a much nicer way to install the software. So it's there for users with a distribution without publictransport packages or users that absolutely want to try out the newest version, when there's no new package already. Another thing I might add to the warning message: "Don't install in parallel with PublicTransport installed from the package manager".
(I created the installer to learn a little bit of bash scripting, but it also helps me to ensure, that everything builds fine in the source package) - Feb 22 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

@cmlr: There's now a HINTS_FOR_PACKAGE_MAINTAINERS file :) Hopefully informative enough.
I also added CHANGELOG files for all components.

@buschmann23: Can't you just create tarballs from the source directories instead of using the one with everything in it? Is the installer script also in the source RPMs? But not too important, yes, only a few KB ;) - Feb 22 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Hm.. I could put multiple source tarballs in one archive here. The installer script would then also be clearly separated from the sources.
But the component directories just need to be compressed into a tarball to have a source tarball for that component.

Another option would be to create source tarballs for everything and upload them to some other server (I can only upload one file here).
Or I could move everything to a git repository and create branches for the releases. Would that be a good option for you as packager?

The data engine and the library could be put together in one package, then one package for each applet and the runner. And one extra package for timetablemate. I thought, packagers just could divide the sources into multiple packages as they like. - Feb 18 2011
Glucose - Bloodsugar Diary

Plasma 4 Extensions by fpuelz 12 comments

Ah, I had build files in the archive and it was too big.. kde-look.org silently didn't accept it.
Now it should be 0.1.1 and it should work :) - Feb 15 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

"because make only builds files and install moves them to the correct folder"

Hm.. yes. But in this case make does nothing with the symlinks and make install "installs" the symlinks by creating them in the target directory. So it should not be a problem with a sandbox used for compiling but one used for installing?

I'll google, how to tell CMake to move files while installing. It didn't work with "cmake -E rename oldname newname", because my /home is on another filesystem than root and CMake then complains with "Invalid cross-device link". - Feb 14 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Yes, $ACCESSOR_DIR points to (something like) /usr/share/apps/plasma_engine_publictransport/accessorInfos. The .xml- and .js-files are also installed there by CMake.

The symlinks are installed using eg. "ln -s us_default.xml $ACCESSOR_DIR/us_septa.xml". So the symlinks are relative softlinks and written into $ACCESSOR_DIR. They point to files in the same dir, so the symlinks can point to eg. "./us_septa.xml". But the target dir for the symlink (second argument, the dir, in which the symlink should be created) needs to b $ACCESSOR_DIR, because otherwise they're created in the working dir. I just run it from the "build" dir, and it created the symlinks in the build dir.

The symlinks need to be in /usr/share/apps/plasma_engine_publictransport/accessorInfos.

Maybe you got this wrong: The symlinks aren't created first and then installed, but directly created in $ACCESSOR_DIR.
Maybe it would work if they're created in the build dir and then copied to their destination? But doesn't copying a symlink copies the linked file? - Feb 13 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

That doesn't install the symlinks to the install dir, but to the dir in which cmake was called. So they won't be used by the data engine.

I don't understand why it's still a problem for packaging. The other files are installed to the same directory as the symlinks. Why doesn't it complain about them? - Feb 13 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

It shouldn't, at least for me it now creates relative symlinks. The CMakeLists.txt only contains filenames as symlink targets.

But the symlinks are installed to absolute pathes, of course. They are installed to the same path as the other service provider files.

Maybe the symlinks haven't been overwritten, because they existed from a beta2 installation (check modified time)? For me they're replaced automatically (like the other installed files). - Feb 13 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Looks like it doesn't find the library headers. The library must be installed for the other parts to be compilable.
I guess the library has to get it's own package and must be set as dependency for the others (applets, runners, TimetableMate).

Or it should link to the compiled but not installed version of the library. I'll think about that, should be a little change in the CMakeLists.txt files. But I think a separate package for the library (or library + data engine) would be better, and could then be used as dependency for the applets, the runner and TimetableMate. - Feb 12 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

It already loads as much departures as possible with the used service provider. For de_db it gets approx. 100 deartures, others mostly show less departures. Then it filters out departures and after that it cuts them to the maximum number of departures. It would work better if the filters could be added to the requests, but they are too complex and most service providers only support very easy filters if at all.
So if you use too restrictive filters, you may get less departures than the configured maximum number, depending on the used service provider.
If it shows less filtered departures than you can find on the results website, there is an error.
The only solution would be to fetch more departures, as you said. I will think about it. - Feb 09 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I will correct the bug with the stop suggestion list for the next version. It shouldn't load new suggestions when a suggestion gets selected from the list. Thanks for the hint!

I just tried the CHAPS provider in city Brno with stop name Technologick√Ĺ park, and it worked for me. You could try to open the web page with the timetable data by clicking "Open in Web Browser" in the applet's context menu. If there was no error it should show the page. You can send me the (new) logfile for the parsing scripts. It's in "~/.kde/share/apps/plasma_engine_publictransport/accessors.log". - Feb 07 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Done :)
Will be in the next version. - Feb 07 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I have no such error in my .xsession-errors. The geolocation data engine should only get queried by the publictransport applet if the button "near stops" in the configuration dialog is clicked. Did you use that function? What makes you sure that the applet causes the errors? - Feb 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Yes: The button labeled "Add Filter" adds a new OR filter (it shows a separator line with text "or"). The little add button on the right of a filter adds a new AND constraint to that filter.

There are help texts for the widgets in the configuration dialog using the help button from the windeco. - Feb 04 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Yes, only TimetableMate needs KWebKitPart. To compile it, the development files (headers) are needed. If there are no packages available for Arch, you would have to install the header files yourself from the KWebKitPart sources to compile TimetableMate.
Maybe I can make KWebKitPart usage optional. But TimetableMate is only needed to add support for new service providers, so it's not needed by the average user. - Feb 03 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Ok, did you also install the development package, kwebkitpart-dev or kwebkitpart-devel? - Feb 02 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I'm also using KDE 4.6 here and it compiles fine. What is the error message? If you're using the install script try "./install.sh --show-compile-output" if no error message is shown. - Feb 02 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Hi,
you can write the filter like this:

if ( ((vehicle = S or RB) AND (destination = frankfurt)) OR ((vehicle = S or RB) AND (destination = bad soden)) )

Thanks for the ebuild-update :) - Jan 28 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

sudo works for me, too on openSuse. Maybe I can somehow check if "sudo" is available and otherwise try "su". Something like checking if "whereis sudo" returns something (I'm no shell script expert ;)).
I'll look into how it's done with the YaWP-applet. - Jan 24 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

done, thanks :) - Jan 24 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

The "CMakeLists.txt" for TimetableMate is bad. Instead of

target_link_libraries( timetablemate ... kwebkit )

it should be
target_link_libraries( timetablemate ... ${KDE4_WEBKIT_LIBS} )

Then it compiles and works again :)
Will be in the next version. - Jan 20 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

Hi,
I just fixed the problem. It kept old departures, because it wrongly guessed the date as tommorow. Now it always shows the departures for the next hour for cz_idnes (for more data, at least two HTML documents would need to be downloaded). I also added the time into the generated timetable-urls. With the next version you can then also show departures in eg. 2 hours using cz_idnes.
The next version has some more changes, I will release it later as version 0.10. Until then you can higher the number of maximum departures in the configuration dialog > Section "General" > Tab "Advanced". Then it shows new departures for some more time.. - Jan 17 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

It tries to install flag icons for very many countries (although only a few are actually used..), one country has the code "mm". So it tries to install a flag icon "mm.png", but in the same directory mountmanager has installed it's own icon with the same name "mm.png". That's what the error message says.
But I've "fixed" it, by simply removing all the mostly unused flag icons. I read a bit through the sources of KDE's systemsettings modules to find out from where it gets the flag icons in the locale settings to select a country.
Fortunately I didn't have to search long and the applet now uses the same flag icons :) In the next version, will be 0.10. - Jan 05 2011
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I just fixed the journey parsing for SBB. It didn't work anymore, because the HTML code from SBB changed a little bit. I'll release a new version with that fix soon (0.9.1). - Dec 19 2010
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

The crash is quite random, but it's fixed in KDE's SVN trunk already. I will release it in version 0.9.
What service provider are you using? SBB? I will have a look why the journey function doesn't work. - Dec 11 2010
PublicTransport

Plasma 4 Extensions by fpuelz 813 comments

I fixed some crashes in the javascript parser when it parses bad javascript code (for timetablemate). Will be in version 0.9, to be released soon. - Dec 11 2010