BKO: Components

This is the fourth post in my blog series: bugs.kde.org for developers.

Yesterday we looked at how to search in bko if there is useful information in it. Today we start adding the useful information: components. Now again I assume you will say that you know everything about components, but I have assigned bugs to so many products with too few components, that I decided components deserve an own post in this series.

Components can be used to group your bugs. You can use any grouping which might make sense to you. You could add components for the parts exposed to the user interface, components for implemented concepts (e.g. a protocol) or components for specific parts of the code base. My recommendation is to remember that the bugtracker is there to help you and that means you should use what makes sense to you and not what might make sense to users. Please don’t expect that users or triagers will find the right component – setting the component is something the developers have to do.

One of the advantages of components in my opinion that it makes bko less scary. You might have hundreds of bug reports which is difficult to manage and to go through. But when they are nicely separated in components everything is less scary. Your components might just have something between 10 and 20 bugs and that makes everything look much better. Just have a look at the component report of KWin.

The component report for your product is something you should bookmark. It is a very useful tool when searching for duplicates. You know the new reported bug has a duplicate: just go through the few bugs reported to the component. Much faster than using a search query.

If your bugs are nicely triaged into components it becomes much easier to work with the bugs. You can easily see which bugs exists for a specific code area, you immediately find the duplicates and similar bugs and you can nicely plan how to fix those bugs. There are very handy features to help you do the bug fixing planning – but that in a later post. Also you easily spot areas which requires work: if all your crash reports are in one component it might be a good idea to increase the priority of fixing bugs in that component.

In case you have developers in your team responsible for a specific part, you can set the developer as the default assignee and your general team bug account as the default CC list.

What we have not yet discussed is how to create components. There are two possible ways: create a sysadmin request to get the components for your product (sysadmin will need name, description, assignee and cc list) or in case you are a maintainer you could request to get higher privileges to create the components yourself. I highly recommend the latter as that makes your work with bko much more flexible. While doing a triaging session lately I realized that we need two additional components and I could just create them and send the bugs there without waiting for sysadmins to act and they really have enough work to do ๐Ÿ™‚

You don’t have to be afraid of components becoming obsolete in future versions of your software: components can be deleted (if there are no bugs assigned to it) and can just be disabled, so that no new bugs can be assigned to that component.

BKO: Searching the Bug Database

This is the third post in my blog series: bugs.kde.org for developers.

Today’s blog post in my series on bko for developers is about searching in bugzilla. Now you will say searching is easy I know all about it: trust me if you are not a developer of Amarok/Phonon, Plasma, KWin, Solid or Telepathy you will learn new things. Yes bko can even tell me if you know how to search ๐Ÿ˜‰

Searching by bug number

On each page of Bugzilla you have access to the quick or simple search through a very prominent field. This is a great search field for users, but mostly useless for developers: you don’t want to use it. A more detailed explanation can be found in the help on Quicksearch.

Quicksearch is a wonderful tool if you already know the bug number or alias you want to go to. But if you already know the bug number you don’t need to use Quicksearch, but you can use a web shortcut in combination with KRunner:

The web shortcut “bug:” allows to search in bko with search term either bug id or alias independent of used browser. If you don’t know about alias: you can give each bug a human readable name – the alias. That is particular useful if you have a bug report which has many duplicates like the one in the screenshot. To set an alias you need to edit the bug summary which reveals a field to enter the summary. Use the alias wisely: you need to remember it and remember that bko is a global database, so better use a prefix.

The Advanced Search

The real search for developers is the Advanced Search. It has an entry in the global navigation, but I recommend you not to use it, but to set a bookmark on a slightly adjusted link with “&product=“. You will most likely just search in your product and bko hosts many products and especially many which start with a “k” ;-).

Now what is important to know about the Advanced Search is that it is not about searching like e.g. Google. Of course you can also use it to search in bko, but it’s much more powerful. It is the key to turn bko into a tool to support your workflow. In my last post I wrote that I use emails to get all information about bugs for kwin. This is only partially true, I start to transit to using only searches.

Why is the search so powerful? It allows you to search on any information you put into the bug. You want to have all bugs in a specific component reported between beta tagging and beta release? No problem with advanced searches. You want to see all bug reports with a specific target milestone and having a patch as attachment? No problem with advanced searches.

I use the searches for example to see all bugs which have changed for KWin in the last 24 hours. That is very similar to what I also have in my mail inbox. But it’s better: it gives me the context on how I need the bug. What’s the status of the bug? When has it been changed before? Is it scheduled? Confirmed? Triaged? All these information I have in one table, but are missing in the mails. It allows me to better schedule when I want to work with the bugs.

Other searches I use are for bugs with a specific target milestone. It is so to say my personal TODO list. It needs more work, but it can be tuned into telling me what I have to work on today.

So it is a very powerful tool and the UI is very complex, that’s why I cannot introduce all the specific features in this post. I can only suggest to start reading the documentation and experiment with the search capabilities.

Saved Searches

As mentioned the searches are very powerful and that means it takes quite some time to get the query in the way you want to have it. And if you use the same query again and again (e.g. all bugs changed in the last 24h) you don’t want to spend five minutes on setting up the query each time.

Of course bko has something for you: saved searches. Whenever you perform a search, underneath the search result there is an input field to name and remember the search:

As you can see the saved searches are shown in the footer of each page and you can always get to a search by just one click.

Defining searches and saving them is already a quite important feature to efficiently work with bko. But you normally work in a team and you can expect that your team mates have to search for the same things as you do, right? It would be a pity if everybody has to setup the searches. Of course bko has a solution for this problem. Go to Preferences -> Saved Searches. Here you can edit and manage all your searches but even more important you can share your search with groups.

If a search is shared it is listed on this page and you can just add it to your searches shown in the footer. So all the searches defined by your team members can be made available for the complete team. As shown in the introduction only very few teams make use of this feature, in fact it looks like half of all saved searches are for Amarok/Phonon. And Amarok is one of the products which got the bug count quite low over the last few years. So learning from the great work done there will help you.

Going Through Search Results

When working with the searches it’s of course important to see the information you really need. Therefore the search layout can be customized using “Change Columns”. This allows you to add/remove and reorder the columns listed in the search. Of course you can save the layout for each of your searches or just change the layout for your current session.

If you use the searches to go through a list of bugs, it can be very useful to not use the default tabular layout but to switch to the “Long Format”. This shows all bugs in the search result aggregated. That is you have all the comments and all bug fields. A quite useful feature also when searching for a duplicate. Unfortunately this view cannot be used to edit bugs, for that you still have to properly open the bug.

Bko also keeps the context when you open a bug from a search result. That is on each bug page you have pagination to navigate through the search result. If you change a bug by default bko will also open the next bug from your bug list, but you can change this behavior in the preferences.

BKO: Managing Bugs via email

This is the second post in my blog series: bugs.kde.org for developers.

For an Open Source developer email is one of the most important developer tools. We communicate on mailing lists, receive review requests through emails, get notified about new user support questions in the forums, ensure that all commits had been reviewed by using the commit filter and so on and on. If you are a developer interacting with bko you should probably already know that you can receive mails from bko. But there is much more into it.

Why receive mails for Bug Reports?

Getting mails for bug reports means that you have all your development discussion in one place: your email program. It is very easy to escalate a bug report by just forwarding it to the mailing list. But that is not the real advantage of it. Consider you want to answer to the user, how do you do that? Well of course you go to the web application. No! You press reply and send the mail to bko. All mails sent from bko have a reply-to header set to ensure that your reply will end up in the bug tracker. This makes it very easy to just reply to a comment on a bug.

Another advantage is that you start to collect a local copy of the bug reports and history of your product. Up to now I have collected close to 27,000 bug mails for kwin in one mail folder. Thanks to Akonadi and Nepomuk it is very easy and fast to perform full text searches which comes very handy when looking for a duplicate. Most duplicates can just be found by filtering for the subject if you have an idea how the bug was called.

Managing Bugs

But you cannot only receive comments and send comments to the bugs, you can do much more. You might not know it, but if you add

BUG: 123456

to a git commit the hook on our servers will send a mail to bko. This means you can even set bugs to fixed just by sending out a mail. For a complete documentation on how a mail has to look like please refer to the documentation on Bugzilla’s mail interface. Btw. if you don’t know that there is documentation about Bugzilla: you can find all available documentation about Bugzilla here. BKO currently uses version 4.2, be aware that not all documented features might be available on BKO.

Mail Settings and Following Users

BKO gives you a very fine grained control on when you want to receive mails for your bug reports. For that select “Preferences” and then the second tab called “Email Preferences”. So you can fine tune when you get a notification. E.g. you might not be interested to get a mail whenever someone is added to CC.

But much more interesting is the “User Watching” functionality on the same page. This allows you to receive emails as if you were the person you are watching. So if you follow a user who will receive emails for those bugs he is assigned to as if you were assigned to the bug. This is a very handy feature if you have a bko account for your project such as “kwin-bugs-null@kde.org”. So I’m following this user and that’s the reason why I complain when someone reassigns a bug to product kwin and forgets to reset the assignee to default: those following the user won’t be notified and the bug is kind of lost (a better workflow for this will be discussed in my next post).

What else?

Since the upgrade of our bugzilla installation bko can send out HTML mails. By default bko sends out plain text mail and I use plain text mails everywhere except for bko. With HTML mails you get nicely formatted tables whenever something changes like for example the component. It is in my opinion much easier to read and that’s why I use HTML mails for bko.

You can enable those in the last drop down of the “General Preferences”.

BKO: All the bugs belong to you

This is the first post in my blog series: bugs.kde.org for developers.

In this post I do not want to discuss any specific features of bko but want to give some general advice on how to work with bug reports.

The first important advice I want to give you is to remember that the bug reports are there to help you. They are there to improve the quality of your software, they exist to help you deciding what you want to work on. Remember: the bugs are there to help you!

But you have to help bko to become a database which actually helps you. There are bug reports with low quality, with user support questions, dream worlds, wrong assumptions and all such things. What is important is to improve the quality of the bug reports so that all bugs can help you.

To get to a good database don’t wait for others to do it for you. More than 400 bug reports are opened each week, so don’t expect that there is a team of bug triagers which knows all details of your software to properly triage it. Triagers and users can help in reproducing the bugs but cannot help you in turning the bug into pure gold.

When a new bug is reported remember that it will be in bko for quite some time. We are far away from a bug gets reported and fixed in the next release. The report will be in your search results, in your lists for weeks, months maybe years. You will see and read it more than once.

Every time you look at a bug to figure out what it is about you lose time. You did that once and you should not do it again. Remember: the bug tracker is there for you. The more information you put into the bug report the more it will help you. Is the summary line bad? Change it! It will be shown every time in your search result. Does it not contain any way to reproduce it? Add it! Did the user report multiple issues in one bug? Close it and open separate reports!

Yes it is totally fine to discard everything the user wrote. The bug tracker is there for you and not for the user. There is nothing wrong with opening a new bug report with your technical analysis and setting the user’s report as duplicate. If that helps you it’s fine.

Don’t be afraid of setting bugs to invalid. If the user just did not find an option or used the software in an incorrect way, you can safely close the report as invalid and send the user to the forum. That’s where user support happens and not on bko.

If a user is not able to reproduce a bug and cannot tell you what he did, there is hardly any chance for you to reproduce it either which means you cannot investigate it and cannot fix it. It’s a pity but there is nothing you can do about this bug, so you can set it to NEEDSINFO WAITINGFORINFO. If a user finds this bug and can reproduce it, it can still be reopened but till then it doesn’t help you if it sits there and contains no useful information for you.

Your software is no dream world. Yes bko allows the user to enter “wishes”. But you have to question the wishes. Not every wish should come true, not every feature can and should be added to your software. If we want software which does everything and the kitchen sink there is already Emacs for it ๐Ÿ˜‰ So there is nothing wrong with stating that the specific feature request does not fit with your software and that means setting the wish to WONTFIX. I think that is better and more honest than keeping the wish open for years without telling the user that you will never implement it. And remember bko is there for you and not for the user. If the feature request sits there and won’t be implemented it will be shown in your search results, it limits your possibility to work with bko.

In general bko is very bad to be used for feature requests. So just don’t use it for it. If a user reports a new feature request, just set it to WONTFIX and send them to KDE Brainstorm. That allows the users to discuss it, to figure out whether it is a feature for a user’s specific workflow or whether it’s a real advantage to your software.

Sometimes users report “bugs” which are in fact feature requests. Totally valid and correct behavior may seem like a bug to a user. But if your software behaves correctly, it’s not a bug. So the user is asking for a change in existing and working functionality. Those requests should be handled like any other feature request and not like a bug. Remember the bugs are there for you and not for the user. If it is no bug, it does not become a bug because the user yells. And if you think the feature works correctly the way it works, then again it’s a WONTFIX even if the user thinks it’s a bug. And don’t discuss. Users try to discuss such decisions and such discussions should happen – if at all – on brainstorm. Make it clear that discussions won’t help anything, that it takes away your time to fix bugs and if that does not help just ignore the bug or get help from the community working group. Users have no right to question your decisions about which features to implement and which not. If they want it implemented they can implement it themselves, hire someone to do so or whatever. But even then they don’t have the right to get the code in, though they can fork and whatever. Our license does not require that we build a kitchen sink.

And my last advice for today is: don’t expect to change bko for your product in a day. It’s a process which will take months and maybe you will benefit in a year from it. But it’s worth it, so invest the time.

Blog Series: bugs.kde.org for developers

Over the last few weeks I have worked more intensively with bugs.kde.org (bko) – our Bugzilla installation. While doing so I realized that Bugzilla is much more powerful than most of us know and that many of the complaints about bugs.kde.org are caused by us developers using bko in a wrong/inefficient way. Also it seems like there is no proper documentation on how to use bko as a developer. We find lots of information on how to use it as a user or as a triager, but not for developers. No new developer gets mentored on how to use bko, although it would be so important to have also our GSoC students taking part in using bko right from the start.

I want for all developers to turn bko from the monster you don’t want to use into the most important tool for developing your software. With KWin I’m close to that state where I start to benefit from bko and don’t see it as my “enemy” any more.

So I want to share the knowledge I gained for using bko in a blog series. All the posts I will write in the scope of this blog series will be merged into a wiki page. If there is a specific topic you want to have covered in the blog series, please leave a comment to this blog post.

Changelog and Feature Plan Generator

This is kind of a new service announcement for our various maintainers and developers of KDE software. As I don’t like manual work and especially not manual and repetitive work, I decided to implement a tool which generates the markup for our changelog, which can be found in my scratch repo.

The changelog is generated from all bugs with a given version in the fixed-in field. So remember to add

BUG: 1234567889
FIXED-IN: 4.8.3

to each of your commits to the stable branch (please also add good keywords to your commits in master). This allows your maintainer to generate the changelog for your product in less than a minute. The bug’s summary is used as the changelog entry. So this is also a good reason to give a proper summary to your bug reports and remove junk like “KWin fails” ๐Ÿ˜‰ Oh and if you don’t know the bug report to your commit, just perform a search (bugs.kde.org is really fast nowadays – so it’s no excuse!) and if there is really no bug report rethink whether your commit is a good idea for the stable branch at all.

I hope that this tool will help us to get a better changelog in 4.8.3, so please all help to make that happen. If I see good progress, I will invest the time to get the tool into a shape that our release team can generate the complete changelog for a release without any manual intervention.

Generating the changelog is not the only manual process I don’t like, also creating and updating the feature plan is an annoying process, especially as writing tables in MediaWiki markup is so much fun. If you use the bugtracker to manage the features you are going to add to the next release (have a look at target milestones) the tool can also be used to generate MediaWiki markup for the feature plan. Based on whether the bug is opened or closed a todo or done entry is generated. If the bug report is assigned to you the tool can fetch your mail address, but not yet your name (all KWin features are assigned to the default component).

Less Than 200 Open KWin Bug Reports

After weeks of hard work by Thomas and myself the open bug count of KWin is finally below 200!

This is best seen in the graph plotting open bugs over time. In the weekly bug summary you now have to select the top 50 products to see KWin at all.

How did we achieve this great result? We have many user support issues in the bug tracker and many users don’t answer questions any more. Those bugs can be closed if the last comment is a year ago asking to provide the requested information.

Many bugs have in fact been fixed since the bug has been reported and we just have not known that there is a report for this issue. Also many bugs are just for so outdated versions (4.2 or earlier) that any information provided in the report is no longer valid. Not only KWin has improved a lot but most important also the drivers.

But there is still much more work to do in the bug tracker. 200 open reports is still much more than the number of real bugs which I expect to be below 100. So give us a helping hand. Reading an open report and trying to reproduce it is not that difficult ๐Ÿ™‚

KDE Plasma Daily

This weekend I read that the KDE:UNSTABLE:SC repository on the Open Build Service is up and running again. So I could finally finish a project I had already prepared but has been blocked by the missing updated packages: A Daily Live CD/Image for KDE Plasma. Additionally to KDE Plasma I put most of our KDE Applications on the image.

I hope that such an image can help test our software in a better way. At least for me it is an important addition to have something with our defaults to easily test.

So give it a try and report any issues and even better help me with this little project ๐Ÿ™‚

As the KDE:UNSTABLE:SC repository is not updated daily, this appliance is also not updated daily, but most likely once a week.

A more elegant KDE Plasma Window Manager and Compositor

Recently I have spent some time to make our window manager even more elegant. That is I decided to fix a few rough edges in our user experience offerings. All of these issues had actually been reported in our bugtracker as feature requests some time ago and listed as Junior Jobs, on the KWin ideas Wiki page and of course recently been added to the 4.9 milestone plan.

Unfortunately nobody wanted to work on these important yet easy to fix issues ๐Ÿ™ So instead of waiting even longer I started to tackle the issues myself to ensure they will hit the next release. That means I invite all readers to participate in the development: it’s really easy and we are quite open and offer help to new developers ๐Ÿ™‚ We even have quite some non-development tasks like requesting new categories on kde-look/apps.

The context menu when right clicking a window decoration has been synchronized as far as possible with the one of the tasks applets. Unfortunately we cannot share the code for technical reasons and some actions just cannot be available in both. E.g. creating a launcher doesn’t make sense in KWin and e.g. window tabs are a KWin internal functionality not yet available to Plasma Desktop.

While I was working on the menu I also decided to improve the “Move To Desktop” menu by using radio buttons instead of check boxes. A window is either on one desktop or on all – the checks do not make any sense as the actions are mutual exclusive. This indication is important as for Activities a window can be on a set of Activities and there check boxes make sense and are used.

Those users knowing the menu will notice that the entry “Configure Window Behavior” is no longer present in the screenshot. The entry has never opened any settings to configure the behavior of the selected window, which is quite confusing. It is in fact a quite exposed entry to the window manager settings. Based on feedback we got, including me asking non-technical persons what they expect this entry does, it got moved into the “More Actions” submenu and renamed to “Window Manager Settings” which is more compliant with other settings of our desktop shell like “Desktop Settings” or “Application Launcher Settings”.

Another area which received a few more improvements is again the Window Switchers. In addition to what I wrote last week cursor key navigation got added to our fancy switchers like CoverSwitch. So you now have a consistent behavior no matter if you use an effect or a QtQuick based layout.

In case there are no open windows when the Window Switcher is opened we now include the entry to “Show Desktop”. Defining the behavior for the Window Switcher when there is no window present is not trivial. The correct way would be to not show the list at all, but this would imply that there is no visual feedback at all to the user action. Also it is always possible that the last open window closes while the switcher is present. To handle such cases correctly we have so far shown a special text that there are no windows. But this has never felt very integrated as e.g. the thumbnail list is empty.

By adding the “Show Desktop” entry we have a consistent and correct behavior as the desktop will be shown after the user ended Window Switching. Another improvement in this area is that the wording is now the same in all layouts and effects. The effects used to call this entry “plasma-desktop”. Also as the icon we now use the same icon as e.g. the “Show Desktop” Applet which you can add to your panel instead of the Plasma icon. So all together some nice improvements to have an overall more elegant user experience in the KDE Plasma Workspaces.

Window Switcher Love

One of my favorite features in KWin is Window Switching (aka Alt+Tab) and it is not surprising that it’s also one of the areas I prefer to work on and love to see others working on.

This week our Window Switchers have received quite some love from various contributors. The compact layout got some usability improvements and the highlight in all layouts does no longer move around when pressing Alt+Tab for the first time. Navigation with cursor keys when the list of windows is open, is properly supported, now. That is in a horizontal layout the left/right keys can be used to navigate through the list, in a vertical the up/down keys are supported and in a grid all keys are supported. Of course the normal navigation is still Alt+Tab/Alt+Shift+Tab – navigation through cursor keys is just an additional useful feature for those who want to use it.

Speaking of grid based layouts: I implemented a new QML layout in a “Present Windows” style. It is a layout showing thumbnails of all windows in the list in a regular grid and taking the complete available screen estate. By that it is similar to the previous Alt+Tab mode inside the Present Windows Effect. The code related to Alt+Tab has been removed from the effect, but otherwise the effect is of course unchanged.

Having this mode as a QML layout has quite some advantages. E.g. it is no longer required to have desktop effects enabled, though it is still recommended ๐Ÿ™‚ The layout follows the visual style of our primary Desktop Shell which makes it easier to use. Selection is indicated by the well known selection marker of the Desktop Shell Themeing. Last but not least the layout properly supports multiple screens, which has not been a pleasant experience with the old effect based implementation.

Overall the new grid layout is also incorporating some of the feedback we received for the new layouts introduced in 4.8. Our default layout replaced the BoxSwitch effect, but there has been a slight difference in behavior. The layout makes only use of the horizontal space and by that thumbnails can become so small that they cannot be recognized any more. In the new QML based layout the thumbnails always have the same size at the compromise that some of them are perhaps not visible.

A grid based layout provides here quite some advantages as the screen estate is used in a more efficient way to render high quality and good looking thumbnails even with a large amount of windows.

I like to remember that we are currently selecting ideas on how to improve our default settings and switching to the grid based layout may be one of those. Also I want to remember that all those changes are rather trivial and could easily be implemented by new contributors and are also listed in our ideas page and as milestones for 4.9.