=== yofel_ is now known as yofel
=== ext2 is now known as ext3
zkriesseHallo monkeyland07:54
monkeylandhola zkriesse07:55
=== pjarnahomzz is now known as pjarnahom
=== newbie is now known as kredf
=== userdays5 is now known as twiiiiiin
=== pjarnahom is now known as pjarnahomzz
=== gordon is now known as Guest51981
=== pjarnahomzz is now known as pjarnahom
=== ext2 is now known as ext3
=== pjarnahom is now known as pjarnahomzz
=== cheese is now known as Guest83698
=== pjarnahomzz is now known as pjarnahom
=== AKShams is now known as ashams
=== pjarnahom is now known as pjarnahomzz
=== pjarnahomzz is now known as pjarnahom
=== charlie is now known as Guest25290
akgranerWelcome to Ubuntu Developer Week Day 216:51
akgranershadeslayer, if you are ready the floor is yours!16:51
shadeslayerHi! Everyone and welcome to Packaging with the Ninjas16:52
dholbachshadeslayer: can I interrupt for an organisational note?16:52
shadeslayeryes sure16:52
dholbachWelcome everybody to Ubuntu Developer Week - for those of you who join in the first time today, please also make sure you join #ubuntu-classroom-chat (yes, lernid does that automatically for you)16:53
dholbachif you have questions, please ask in #ubuntu-classroom-chat and prefix them with "QUESTION: "16:53
dholbachfor those of you who did not review https://wiki.ubuntu.com/UbuntuDeveloperWeek/Sessions yet, some of the sessions that are happening today and in the next days, require a bit of preparation16:54
dholbachfor example Riddell's session requires to have qt4-qmlviewer installed16:54
dholbachRohan Garg (shadeslayer) will introduce you to Ninja packaging skills now, so I hope you'll enjoy the session!16:54
dholbachshadeslayer: the floor is yours :)16:54
shadeslayerOK.. so first up,the stuff that takes some time16:55
shadeslayerBuild Env : https://wiki.kubuntu.org/Kubuntu/Ninjas/BuildEnvironment16:55
shadeslayerRead that once and have the build environment ready :D16:55
shadeslayerEvery few weeks KDE make a new release of their software compilation16:55
shadeslayerand our crack team of packaging ninjas jumps into action to package this16:56
shadeslayerPlease branch bzr branch lp:kubuntu-dev-tools16:57
shadeslayerthose are the latest tools16:57
shadeslayermhall119: yes16:58
=== MaWaLe_ is now known as MaWaLe
shadeslayerFirst we build all the packages for maverick and these are backported to lucid16:59
shadeslayertech2077: currently the kubuntu-dev-tools are broken17:00
=== ChanServ changed the topic of #ubuntu-classroom to: Welcome to the Ubuntu Classroom - https://wiki.ubuntu.com/Classroom || Support in #ubuntu || Upcoming Schedule: http://is.gd/8rtIi || Questions in #ubuntu-classroom-chat || Event: Ubuntu Developer Week - Current Session: Packaging Like A Ninja - Instructor: shadeslayer
shadeslayerthe branch i just gave you doesnt seem to be right .... lemme search for another one17:00
shadeslayerbzr branch lp:~kubuntu-members/kubuntu-dev-tools/trunk17:01
shadeslayerthe right dev tools17:01
shadeslayerGeneral Dep Graph : https://wiki.kubuntu.org/Kubuntu/Ninjas/DependencyGraph : is the genral dep graph ninjas follow in their quest to get the latest KDE releases building17:02
shadeslayerso first up we have to upload kdelibs and then go upwards onto kdebase and other such stuff17:02
shadeslayerKDE released 4.4.92 sources a few days back,so i will be teaching you how to package kdetoys 4.4.9217:03
shadeslayerWe usually get the tarballs a few days prior to the release so that we get the time to package them and test out any build failiures17:04
shadeslayerhttp://people.ubuntu.com/~rohangarg/kdetoys-4.4.92.tar.bz2 << Not so secret tar17:04
shadeslayerdownload that tar in a seprate folder17:05
shadeslayerlets name it tmp/17:05
shadeslayerso , mkdir tmp ; cd tmp ; wget http://people.ubuntu.com/~rohangarg/kdetoys-4.4.92.tar.bz217:05
shadeslayereveryone done?17:06
shadeslayertar -xjvf kdetoys-4.4.92.tar.bz2 comes next17:06
shadeslayer<joaopinto> QUESTION: Assuming there are no major build related changes couldn't the entire build-on-new-release process be automated ? Do you really need to manually package it for an inicial upstream build ?17:07
shadeslayerjoaopinto: yes,but there are huge issues with Beta 1 releases of KDE,loads of missing stuff in install files and deps that need to be added17:08
shadeslayerthese have to be checked manually and cannot be automated17:08
shadeslayerok now most of our packaging is hosted on bzr17:09
shadeslayerso : bzr branch lp:~kubuntu-members/kdetoys/ubuntu -r 6017:09
shadeslayerthat checks out revision 6017:09
shadeslayerAlso,if your not a k/ubuntu member,like i was when i joined the ninjas,you can push the packaging to your own bzr branch and ask for a merge with that branch17:10
ClassBotMindflyer91 asked: We have to checkout in the temp folder?17:11
shadeslayerMindflyer91: yes17:11
shadeslayerthat will create 2 folders,one containing the kdetoys sources and the other has the ubuntu/debian dir17:11
shadeslayerwhich has most of our packging17:11
shadeslayerThe good thing is,most of the dirty work ends in the .90 releases17:12
shadeslayerthats when no more install files need to be edited to make the package work17:12
shadeslayeronly small alterations are required17:12
shadeslayerso,after you have the packaging branched, just copy the debian/ folder over to the extracted kdetoys sources17:13
=== pjarnahom is now known as pjarnahomzz
shadeslayerabhi_nav: just cp -r ubuntu/debian kdetoys-4.4.92/17:14
shadeslayercopy the debian folder from the ubuntu folder into the kdetoys-4.4.92 folder17:14
shadeslayereveryone done?17:15
shadeslayerok so far so good :D17:15
shadeslayernow, cd kdetoys-4.4.9217:15
shadeslayerdch -i17:15
shadeslayerat the top,edit the version to 4:4.4.92-0ubuntu1~ppa117:16
shadeslayerif your on maverick and 4:4.4.92-0ubuntu1~lucid1~ppa1 if you are on lucid17:16
shadeslayerabhi_nav: debchange <<17:17
shadeslayerthen after the * add : New upstream release17:18
shadeslayerthis marks the changelog17:18
shadeslayerthat a new upstream KDE version was released17:18
shadeslayershould i move forward? :D17:19
shadeslayerok,so moving forward17:20
shadeslayernow open : nano debian/control17:20
shadeslayerthis is the most important file apart from our rules file that helps in packaging17:21
shadeslayeras you can see it describes each package,what it does,and what needs to be pulled in to make it build :D17:21
shadeslayerin line 7 you will see something like kde-sc-dev-latest (>= 4:4.4.90)17:22
shadeslayerkde-sc-dev-latest is a meta package that pulls in other dependencies to make the package work17:22
shadeslayernow change that 4:4.4.90 to 4:4.4.9217:23
shadeslayersince kde released a new version and new deps are needed ;)17:23
* shadeslayer hands orange ninja belt to tech2077 chilicuil and abhi_nav_17:23
shadeslayercongrats new ninjas :D17:24
shadeslayerok now thats all we need to edit in that file :D17:24
shadeslayerclose with Ctrl+X and y17:24
shadeslayerok,now thats all that needs to be done in that package17:25
shadeslayerjust edit debian/changelog and add - Bump kde-sc-dev-latest to 4.4.92 below the *17:25
shadeslayersomething like http://bazaar.launchpad.net/~kubuntu-members/kdetoys/ubuntu/annotate/head:/debian/changelog17:25
shadeslayereverything done?17:26
shadeslayernow,lets start building!!!!!!!17:27
shadeslayerin the kdetoys dir,just run : pdebuild17:27
shadeslayerthats it!17:27
shadeslayer( supposing you have pbuilder and some ninja hooks ;) )17:27
shadeslayermy favourite hooks are B10list-missing  C10shell17:28
shadeslayerthe B10list-missing hook prints out a list of missing files at the end of the build17:28
shadeslayerpretty useful when your packaging the first beta release of KDE17:29
shadeslayerthe C10shell is another one which drops to a shell and install vim for me to inspect the problem17:29
ClassBotsimar asked: How this different from MOTO in ubuntu ?? I look for analogous names of ninja as i'm more familiar with ubutnu ??17:30
shadeslayerMOTU == Masters of the Universe17:30
shadeslayerthese people are responsible for the universe section of the archives17:30
* shadeslayer looks for ubottu17:30
shadeslayerKDE packages are in the main section of the archives ( most of them that is ;) )17:31
shadeslayerso packaging KDE and MOTU are 2 different things17:31
ClassBotjoaopinto asked: regarding kde-sc-dev-latest, how do you know that the new version is required to build this particular package ?17:32
shadeslayerjoaopinto: good question17:32
shadeslayerkde-sc-dev-latest is a meta package17:32
shadeslayerit depends on other packages,but does not install anything by itself17:32
shadeslayeralso,in order to build kdetoys 4.4.92,you will need kdebase 4.4.92 , this is hard coded in the cmake files17:33
ClassBotsimar asked: I have learnt some packaging skills yesterday from danial also but after then I don't know what to do and where and frm where to start ?? How to get in team .. Could you please tell me a bit abt dat here also ..17:33
shadeslayersimar: we idle in #kubuntu-devel,poke us there and we will hand you work :D17:34
ClassBottech2077 asked: I can't build this myself, i seem to not have a lot of the dependencies17:34
shadeslayertech2077: can you pastebin this error?17:34
shadeslayeralso which version are you on?17:34
* shadeslayer checks time17:35
shadeslayeroh.. 30 mins more :D17:35
=== abhijain is now known as yoku
=== warp10 is now known as warp10-captato
shadeslayertech2077: ok exit pbuilder if it hasnt already17:36
shadeslayertech2077: now run : sudo pbuilder --login  --save-after-login17:37
shadeslayereveryone welcome Quintasan17:37
shadeslayeranother ninja17:37
shadeslayerdpkg-checkbuilddeps: Unmet build dependencies: kde-sc-dev-latest (>= 4:4.4.92) cmake pkg-kde-tools (>= 0.6.4) kdebase-workspace-dev (>= 4:4.4) libphonon-dev (>> 4:4.7.0really) libstreamanalyzer-dev (>= 0.6.3) libqimageblitz-dev17:37
shadeslayerthat says that you do not have the proper build deps17:38
shadeslayerQuintasan: this will be over in 10 mins,we can take on neon then :D17:38
shadeslayerso everyone run sudo pbuilder --login  --save-after-login17:38
shadeslayerthen : add-apt-repository ppa:kubuntu-ppa/beta17:39
* shadeslayer pokes all orange belt ninjas will pointy sword17:40
=== Mitch is now known as Guest9138
=== yoku is now known as abhijain
shadeslayerok then : apt-get install nano17:40
shadeslayerpbuilder doesnt have a editor by default17:41
shadeslayerthen : nano /etc/apt/sources.list17:41
shadeslayerand add : deb http://ppa.launchpad.net/kubuntu-ppa/beta/ubuntu lucid main17:41
shadeslayerat the very end17:41
shadeslayeror you can do as tech2077 did.. install python-software-properties17:42
shadeslayerthe basic thing here is to add the kubuntu beta ppa17:43
shadeslayerwell.. after that just : apt-get update17:43
shadeslayerthen log out using ctrl+D17:43
shadeslayerthen pdebuild again17:43
shadeslayerand this time , it should work :D17:44
shadeslayerQuintasan: ready to fire away?17:45
Quintasanhmm I think yes17:45
ClassBotpenguin42 asked: So once you've built all of this stuff as Ninjas do you have a set of tests?17:45
shadeslayerpenguin42: yes!17:45
shadeslayerpenguin42: lintian takes care of most of the errors17:46
shadeslayerit checks the packaging for defects that the ninjas might have ignored17:46
QuintasanSo, fist of all, Project Neon was/is a very Kool thing that provides users with nightly (unstable) builds of KDE SC. This new users that are up for testing can work with bleeding edge changes in KDE without compiling the whole source by themselves.17:47
shadeslayerok after the deps are downloaded and unpacked,pbuilder builds the package and you get .debs in you pbuilder result dir17:47
shadeslayerwhich is basically all about ninja packaging :D17:47
shadeslayerjust as a example,kdelibs takes 2-3 hours to build17:48
Quintasanshadeslayer: you forgot about uploading to hyper secret ppa17:48
=== ext2 is now known as ext3
shadeslayerah yes.. the hyper secret ppa17:48
shadeslayerif you want to get your name spoken in the elite circles of ninjas,grab one of the ninjas and ask him to review your work17:49
shadeslayerafter a review,you get access to super secret ppa17:49
shadeslayerwhere you can test your builds in the ppa!17:49
shadeslayeras apachelogger pointed out17:49
ClassBotThere are are 10 minutes remaining in the current session.17:50
shadeslayerQuintasan: ^^17:51
shadeslayerquickly neon :D17:51
Quintasanas I worte earlier, Project Neon will provide you with latest builds of KDE SC. Some time ago apachelogger wrote some magic code in Ruby but it won't work now and we have decided to port it to Launchpad Recipes.17:52
shadeslayerWhich is in a beta stage as well17:52
QuintasanThis is where packaging comes in handy. I do belive that latest builds should be provided with ever possible feature.17:54
QuintasanThat's why we (me, shadeslayer, apachelogger) need to check for every additional dependecies, add them, rewrite rules and install files.17:55
ClassBotThere are are 5 minutes remaining in the current session.17:55
QuintasanWell, without boring stuff. Come to #project-neon and help us with out uber 1337 mission of providing the best nightly builds of KDE SC17:57
Quintasansimulacrum: Well, there is a page in Kubuntu Wiki but it is currently empty, I have been thinking about specs for the past few days17:58
Quintasansimulacrum: feel free to ask us anything in #project-neon, we currently need hands to sort out additional dependencies for our packages.17:59
QuintasanThank shadeslayer for teaching you those all things, you can help us right away17:59
=== ChanServ changed the topic of #ubuntu-classroom to: Welcome to the Ubuntu Classroom - https://wiki.ubuntu.com/Classroom || Support in #ubuntu || Upcoming Schedule: http://is.gd/8rtIi || Questions in #ubuntu-classroom-chat || Event: Ubuntu Developer Week - Current Session: "I Don't Know Anything About Translations" - Instructor: dpm
dpmhi everyone18:01
dpmand thanks shadeslayer for a great session18:02
dpmso, welcome everyone to this session on translations18:02
dpmIn the next hour we'll be learning about some basic concepts concerning natural language support, how translations work in Ubuntu at the technical level and how they work for other projects hosted in Launchpad.18:03
dpmThis is a very broad subject and there are lots of resources to learn from on the net. My intention on this session is just to give you an overview of the basic concepts and concentrate on the main technologies and tools for making Ubuntu translatable.18:03
=== weechat_user is now known as jengtron
dpmI'll leave some additional time for questions, but feel free to ask your questions in between as well.18:04
dpmSo without further ado, let's get the ball rolling.18:04
dpm== Why Translations ==18:04
dpmWhile this might seem obvious to some people, I'd like to start highlighting once more the importance of translations -or natural language support to be more precise.18:04
dpmOne of the principles that unite the Ubuntu community is providing an Operating System for human beings.18:05
dpmSome of these human beings might understand and speak English, which is the original language in which the OS is developed.18:05
dpmHowever, there is still a large number of users who need Ubuntu to be available in their own language to be able to use it at all.18:05
=== zyga is now known as zyga_
dpmIf you are an English speaker, you can think about it the other way round to get an idea:18:06
dpmimagine your operating system would be developed in a language you don't know - let's take Japanese.18:06
dpmWould you be able to choose the right menus in a foreign language, or even understand the messages the OS is showing you?18:06
dpmIf you provide internationalization support to your applications, more people will be able to translate them and to actually use them18:07
dpmSetting up an application for internationalization is easier than you might think.18:07
dpmIt is generally a one-off process and it's best done from the moment you start creating your application.18:07
dpmThe rest is simply maintenance - exposing translatable strings to translators and fetching translations.18:08
dpmWhat prompted me to run such a session was precisely the many times I've heard the session's title from developers:18:08
dpm    «I don't know anything about translations»18:08
dpmSo let's try to cast some light on that and hopefully change the statement so that next time someone brings the subject we hear something more along the lines of18:08
dpm    «Translations are awesome»18:08
dpmYeah, that'll do :)18:09
dpm== Basic concepts ==18:09
dpmLet's continue with some basic concepts18:09
dpmI'll quickly run through them, so I won't go into details, but please, feel free to interrupt if you've got any questions.18:09
dpm* Internationalization (i18n): is basically the process of making your application multilingual. This is something you as a developer will be doing while hacking at your app. It is mostly a one-off process, and in most cases it simply involves initializing the technologies used for this purpose.18:10
=== elpasmo1 is now known as ElPasmo
dpm* Localization (l10n): that's what translators will be doing, which is adapting internationalized software to a specific region and language. Most of the work here goes into actually translating the applications18:10
dpm* Gettext: that's the underlying framework to make your applications translatable. It provides the foundations and it is the most widely used technology to enable translations of Open Source projects. In addition, it defines a standard file format for translators to do their work and for the application to load translations, as well as providing tools to work with these.18:11
dpmRelated to gettext, we've also got:18:12
dpm* PO files: these are text files with a defined format basically consisting of message pairs - the first one the original string in English and the next one the translation. E.g:18:12
dpmmsgid "Holy cow, is that a truck coming towards me?"18:12
dpmmsgstr "Blimey, is that a lorry coming towards me?"18:12
dpmthey are often simply referred to as "translations", and are what translators work with, either with a text editor, a dedicated PO file editor, or with an online interface such as Launchpad Translations. They are named after language codes (e.g. en_GB.po, ca.po, hu.po) and are kept in the code as the source files to generate MO files.18:13
dpm* MO files: binary files created at build time from PO files and installed in a particular system location (e.g. /usr/share/locale). These are where the applications will actually load translations from.18:14
dpm* POT files: also called templates, have got the same format as PO files, but the messages containing the translations are empty. Developers provide the templates with the latest messages from the applications, on which the PO files will be based on. There is generally one template (POT file) and many translations (PO files), and it usually carries the name of the application (mycoolapp.pot)18:14
dpmso assuming you've got all your translations-related files under a 'po' directory, it would look like:18:15
=== IngForigua is now known as forigua
dpmso you can see how from a single POT file translators (or Launchpad) create the PO files for their particular language18:16
dpmoh, and in a POT file the message pairs will look like this:18:17
=== forigua is now known as IngForigua
dpmmsgid "Holy cow, is that a truck coming towards me?"18:17
dpmmsgstr ""18:17
dpmYou can see a real one here to get an idea: http://l10n.gnome.org/POT/evolution.master/evolution.master.pot18:18
dpmAnd a particular translation: http://l10n.gnome.org/POT/evolution.master/evolution.master.ca.po18:19
dpm* Translation domain: this is a name which will be used to build a unique URI where to fetch the translations from. E.g. /usr/share/locale/<langcode>/LC_MESSAGES/<domain>. It will be set in the code or as a build sysem variable and generally be the name of the application in lowercase. The POT template will also be generally named after the domain.18:19
ClassBotumang asked: gettext is a gnu software. Can I use it in a PyQt application, say?18:20
dpmyes, you'll be able to use it18:20
dpmbut it might be tricky to set up18:20
dpmsince all the makefile rules related to gettext are geared towards autotools18:21
dpmbut it is definitely possible18:21
ClassBotdevcando85 asked: What .PO and .MO stands for?18:22
dpmPO stands for Portable Object18:22
dpmMO ... err...18:22
dpmI'd have to look it up :)18:22
dpmMessage Object perhaps18:22
ClassBotcsigusz asked: If I didn't translate one message, than what will be appear in the application?18:23
dpmthe application will show the original English message if there is no translation18:23
dpmthat will always be the fallback18:23
ClassBotzyga asked: will there be a section specific to working with web applications? such as django-based web applications? Often distributing and installing such applications is done differently and gettext with its strict rules as to where to find translations is annoying to work with18:24
dpmI haven't planned this for this session, but that'd be a great idea for another (full one)18:24
dpmsome web apps use either gettext or their own implementation (full or partial) of the gettext api18:24
dpmso many of the concepts (po files, mo files, domain, etc) still apply18:25
dpmok, let's continue18:26
dpmI'll try to answer the rest of the questions later on18:26
dpmah, Rhonda tells me that MO stands for Machine Object. There you go, thanks :)18:27
dpmLet's go on with a final couple of basic concepts/tools:18:27
dpm* Intltool: it's a tool that provides a higher level interface to gettext and allows it handling file formats otherwise not supported (.desktop files, .policy files, etc.)18:28
dpm* Launchpad Translations: collaborative online translation tool for Open Source projects, part of Launchpad and available at https://translations.launchpad.net. It allows translating Operating Systems such as Ubuntu, as well as single projects. For translators, it hides the technical complexity associated with file formats and tools, and allows them easily translationg applications online without prior technical knowledge. For developers, it provide18:28
dpms code hosting integration, which greatly facilitates the development workflow18:28
dpmThere are more technologies associated with other i18n aspects - font rendering, to mention an important one - but we'll not be looking at them today.18:28
dpmFrom those concepts, technologies and tools, the main ones to retain for this session are gettext and Launchpad Translations18:29
dpmAnother important concept is the translation workflow. Traditionally, this has been as follows:18:29
dpm1. Some time before release (e.g. 2 weeks), the developer announces a string freeze and, release date and produces a POT template with all translatable messages. This allows translators to start doing their work with stable messages18:30
dpm2. Translators do the actual translations and sent them back to the project (either committing them, sending them per e-mail or simply saving them in Launchpad)18:30
dpm3. Before release, the developer makes sure the latest translations (the PO files) are in the source tree and releases the tarball18:30
dpmLaunchpad make some of those steps less rigid and easier both for translators and developers - the online interface and automatic translation commits ensures that translations get to the project automatically and nearly immediately. Automatic template generation allows the templates to be always up to date. More on that later on.18:30
dpm== Ubuntu Translations ==18:30
dpmUbuntu is translated in Launchpad at https://translations.launchpad.net/ubuntu by the Ubuntu translators, which work in per-language translation teams that constitute the heart of the Ubuntu Translations community.18:31
dpmYou can see all teams here:18:31
dpm  https://translations.launchpad.net/+groups/ubuntu-translators18:31
dpmEach team has their own communication method, and they coordinate globally through the ubuntu-translators mailing list.18:31
dpmSo if as a developer you need to announce anything to translators, or ask a question, the mailing list at https://lists.ubuntu.com/mailman/listinfo/ubuntu-translators is the place to go to.18:31
dpmAll Ubuntu applications -and Ubuntu-specific documentation- can thus be translated from a central location and with an easy to use online interface that greatly owers the barrier to contribution.18:32
dpmLet's get a bit more technical and talk about the workflow of Ubuntu translations18:32
dpmA couple of important point first:18:32
dpm* Ubuntu is translated in Launchpad at https://translations.launchpad.net/ubuntu18:33
dpm* This only applies to Ubuntu packages in the main and restricted repositories18:33
dpm* Translations are shipped independently from the applications in dedicate packages called language packs. There is a set of language packs for each language.18:33
dpm* Language packs allow separation between application and translations and shipping separate updates without the need to release new package versions.18:33
dpmOk, let's have a look at the Ubuntu translations lifecycle:18:34
dpmIt all starts with an upstream project being packaged and uploaded to the archive18:34
dpmIf that package is either in main or restricted, it will be translatable in Ubuntu and will go through this whole process18:34
dpmUpon upload, the package will be built and its translations (the PO files from the source package plus the POT template) will be extracted and put into a tarball18:34
dpmThe pkgbinarymangler package takes care of doing this18:35
dpmThis tarball will then be imported into Launchpad, entering the translations import queue for some sanity checking before approval. It is important at this point that the tarball contains a POT template, otherwise it will not be imported.18:35
dpmhere's what the imports queue looks like18:35
dpm  https://translations.launchpad.net/ubuntu/lucid/+imports?field.filter_status=NEEDS_REVIEW&field.filter_extension=pot&batch=9018:36
dpm(for Lucid)18:36
dpmAfter approval, both the template and the translations will be imported and exposed in Launchpad, making them available from an URL such as:18:36
dpmHere is for example how it looks like for the evolution source package:18:36
dpm  https://translations.launchpad.net/ubuntu/lucid/+source/evolution/+pots/evolution18:37
dpmFrom this point onwards, after translations have been exposed, translators can do their work.18:37
dpmWhile they are doing this, and on a periodical basis, translations are exported from Launchpad in a big tarball containing all languages and fed to a program called langpack-o-matic18:37
dpmLangpack-o-matic takes the translations exported as sources and creates the language packs, one set for each language. These are the packages which contain the translations in binary form and will ultimately be shipped to users, finally closing the translation loop.18:38
dpmSo that was it. Basically, for an application to be translatable in Ubuntu:18:38
dpm* It must have internationalization support18:38
dpm* It must be either in main or restricted18:38
dpm* Its package must create a POT template during build (here's how: https://wiki.ubuntu.com/UbuntuDevelopment/Internationalisation/Packaging#TranslationTemplates)18:38
dpmIf you want to learn more about this, you'll find more info here as well:18:39
dpm  https://wiki.ubuntu.com/Translations/TranslationLifecycle18:39
dpm  https://wiki.ubuntu.com/Translations/Upstream18:39
dpm  https://wiki.ubuntu.com/UbuntuDevelopment/Internationalisation/Packaging18:39
dpm  https://wiki.ubuntu.com/MaverickReleaseSchedule18:39
dpm== Translation of Projects ==18:40
dpmSo we've seen how an Operating System such as Ubuntu can be translated in Launchpad18:40
dpmBut what about individual projects? How can they be internationalized and localized?18:40
dpmThere are many programming languages, build systems and possible configurations, so let's try to see a general overview on the steps for adding i18n support to an app and getting it translated.18:40
dpm* Gettext initialization - the code will have to add a call to the gettext initialization function and set the translation domain. This generally means adding a few lines of code to the main function of the program. Here's a simple example in Python:18:41
dpm  import gettext18:41
dpm  _ = gettext.gettext18:41
dpm  gettext.install('myappdomain', '/usr/share/locale')18:41
dpmThis is a very basic setup. Depending on your build system -if you are using one-, you might have to modify some other files as well18:41
dpm* Marking translatable strings - you'll then need to mark strings to be translated. This will be as simple as enclosing the strings with _(), which is simply a wrapper for the gettext function18:42
dpm* Create a 'po' folder to contain translations (po files) and a template (pot file)18:42
dpm(remember the layout I was mentioning earlier on)18:42
dpmRoughly, up to here the package will have internationalization support. Let's now see how we can make it translatable for translators to do their work18:43
dpm* Updating the .pot template - the translatable strings will need to be extracted from the code and put into the POT template to be given to translators. There are several ways to do this:18:43
dpma) you can use the gettext tools directly (calling the xgettext program)18:43
dpmb) you can invoke intltool directly -if you are using it- with 'intltool-update -p -g mycoolapp'18:44
dpmc) using a make rule to do this for you: with autotools you can use 'make $(DOMAIN).pot-update' or 'make dist'; with python-distutils-extra you can use ./setup.py -n build_i18n18:44
dpmI'd recommend the latest, as having a build system will greatly simplify maintenance18:44
dpmIf you are using intltool in a standard layout, you can even let Launchpad do the work for you and build the templates automatically18:44
dpmcheck out this awesome feature here: http://blog.launchpad.net/translations/automatic-template-generation18:45
dpmThe best integration and workflow is achieved when your project's code is hosted in Launchpad and using bzr, as either committing a new template or letting Launchpad generate it for you will automatically expose it to translators18:45
dpmin a location such as https://translations.launchpad.net/ubuntu/<distrocodename>/+source/<sourcepackage>/+pots/<templatename>18:46
dpmsee the Getting Things GNOME translations for a real example:18:46
dpmSetting up a project for translations in Launchpad involves enabling translations, activating the template you (or Launchpad) have created and optionally enabling the bzr integration features18:48
dpmThese are fairly easy steps18:48
dpmso I'll just direct you to https://help.launchpad.net/Translations/YourProject/BestPractices and leave the last few mins for questions18:49
ClassBotarjunaraoc asked: what is the minimum translation required to include the language in boot options for Ubuntu?18:49
dpmI believe there is not a minimum for the bootloader package. The minimum is the translation coverage of the debian-installer package18:50
ClassBotThere are are 10 minutes remaining in the current session.18:50
dpmI'd recommend you check https://wiki.ubuntu.com/Translations/KnowledgeBase/DebianInstaller or ask on the ubuntu-translators mailing list18:50
dpmMoomoc: Is documentation in Ubuntu always translated with gettext? Isn't this a bit arduous?18:51
dpmactually, translating using with gettext isn't arduous, but rather more comfortable for translators. The tricky part of translating documentation18:51
dpmis converting from the documentation format to the gettext format, which is the one translators are used to18:52
dpmfortunately, there are several tools to make this easier:18:52
dpmxml2po or po4all are two good ones18:52
ClassBotinquata asked: Are there plans to support http://open-tran.eu/ by providing Ubuntu strings?18:52
dpmThere aren't right now, but if you've got an idea on how this could be implemented, a blueprint would be most welcome18:53
dpmRemember that Launchpad is Open Source: https://dev.launchpad.net/18:53
dpmand any contributions are really welcome18:54
ClassBotumang asked: I seem to have missed something about gettext. Are the .po /.mo files accessed at runtime depending on the user's language or are they integrated into separate builds of the same program? If I've understood correctly it's the former.18:54
dpm.po files are source files, so they aren't used at run time18:54
dpmthe .mo files are generated at build time from the .po files18:55
dpmthen installed in the system (generally at /usr/share/locale ...)18:55
ClassBotThere are are 5 minutes remaining in the current session.18:55
dpmand applications using gettext pick them up at runtime to load the translations from them18:55
dpmRhonda also tells me: One important thing to note about MO: Even though it's byte encoded and can be big-endian and little-endian, gettext is sane enough to be able to use _both_ no matter what system it runs on. So the MO format actually is still architecture independent even though the data isn't really.18:56
dpmWe've got time for one or two questions still, anyone?18:57
ClassBotarjunaraoc asked: debian-installer has not been setup in Launchpad so far for Telugu. Is it better to do translation outside?18:58
dpmit is in Launchpad, but yes, I'd recommend doing translations upstream in Debian for that particular one18:59
dpmit is a complex package and does not use a conventional layout18:59
dpmA final note Rhonda mentioned to me as well: The package python-polib helps with respect to using gettext catalogues in python19:00
dpmok, so that was it!19:00
=== ChanServ changed the topic of #ubuntu-classroom to: Welcome to the Ubuntu Classroom - https://wiki.ubuntu.com/Classroom || Support in #ubuntu || Upcoming Schedule: http://is.gd/8rtIi || Questions in #ubuntu-classroom-chat || Event: Ubuntu Developer Week - Current Session: Developing With Qt Quick and QML - Instructor: Riddell
dpmThanks a lot for listening and for the interesting questions19:00
Riddellafternoon all, I'll be starting in one minute19:01
RiddellHi, anyone here for a session on Qt Quick?19:02
Riddellchat in #ubuntu-classroom-chat I believe19:02
Riddellfor this session please install qt4-qmlviewer19:02
Riddelllucid users need to   sudo apt-add-repository ppa:kubuntu-ppa/beta; sudo apt-get update; sudo apt-get install qt4-qmlviewer19:03
RiddellI'm Jonathan Riddell, a Kubuntu developer19:03
Riddellas you know Qt is used in KDE.  it's also spreading out a lot now that Nokia have invested in it19:04
Riddellit's going to be on pretty much all Nokia phones soon, which will make it the most used UI toolkit on the planet19:04
Riddellup until now Qt has normally been programmed in the traditional way of making widgets and putting them places19:05
Riddellwhich is useful for coders but isn't how designers tend to think19:05
Riddelldesigners tend to start with items in places which move around and out the way depending on what's happening19:06
Riddellso Qt has come up with Qt Quick, a new way to make UIs19:06
Riddellit's declarative, so you say what you want it to look like and it'll sort out the bits inbetween19:06
Riddellthis is very new stuff19:07
Riddellit hasn't been released yet19:07
Riddellit will be with Qt 4.7 which is due in August19:07
Riddellit's still in flux, the language has been changing and more changes might happen19:07
Riddellbut already it's being used in interesting places like KDE PIM mobile http://dot.kde.org/2010/06/10/kde-pim-goes-mobile19:07
RiddellI'm not too familiar with other toolkits but I think flash and Mac already have declarative UI coding, I don't know of any free toolkits which support it19:08
Riddellso if you want to create bling interfaces then this will be the way to go19:08
RiddellQt Quick is made up of a few thing19:09
RiddellQtDeclarative library, Qt Creator, qmlviewer app, the QML language and some plugins19:09
Riddellmuch of this talk was given by a Qt Quick developer last week at Kubuntu Tutorials day, you can see the logs here if I don't explain things too well (it's new to me too) https://wiki.kubuntu.org/KubuntuTutorialsDay19:09
Riddellyou can use Qt Creator for this but the version in the archive doesn't support it19:10
Riddellyou'd need to download the daily build ftp://ftp.qt.nokia.com/qtcreator/snapshots/latest19:10
Riddellbut for now you can just use qmlviewer19:10
Riddellthe QML language integrates well with c++ and signal/slots19:10
Riddellso if you like your old style of programming, it's not going anywhere19:10
Riddellright, let's see some code19:11
Riddellthat's a hello world example19:11
Riddellit shows some text in a rectangle19:11
Riddellyou can run it with   >qmlviewer tutorial1.qml19:11
Riddell19:12 < maco> looks like CSS to me19:12
Riddellyes it's a similar syntax but there's plenty differences19:12
Riddellhere you declaire the objects, not just add styles to them19:12
Riddellalso it's not cascading19:12
Riddellthe first line, import Qt 4.7, imports all the types in Qt 4.719:13
Riddellso when we start using types later, like 'Rectangle', you now know where they are from19:13
Riddellhttp://doc.qt.nokia.com/4.7-snapshot/qdeclarativeelements.html  lists all the current types19:13
Riddellthe Rectangle { line actually creates a Rectangle element19:13
Riddellbetween {} you can set the properties and children of the element19:13
Riddellnext line sets an id so we can refer to this rectangle by that id "page" elsewhere19:14
Riddellsome properties are set19:14
Riddellthe next line, Text{, creates another element19:14
Riddellthis element, as it's inside the Rectangle{}, will be a child of the Rectangle element19:15
Riddelland we set its properties over the next few lines19:15
Riddellthe anchor properties are a way to position elements19:15
Riddelland that line binds the horizontal centre anchor of the Text to the horizontal center of the element called 'page'19:15
Riddellanyone got it running?19:15
Riddell19:15 < ean5533> QUESTION: Do QML elements have required attributes?19:16
Riddellean5533: not as far as I know, they will default to sensible defaults19:16
Riddellalthough for text that will be a blank string so it's not much use unless you want to use the item later19:16
Riddell19:16 < maco> QUESTION: how do we execute it?19:16
Riddellwith  >qmlviewer tutorial1.qml19:17
Riddellyou need to install qt4-qmlviewer19:17
Riddell19:15 < simar> QUESTION: Is this work on GNOME also ie on ubuntu?19:17
Riddellof course, it's all X so it'll run on any desktop environment19:17
Riddelljust because you use Gnome doesn't mean you can't use non-Gnome apps19:18
Riddell19:18 < Neo---> no problems with running it19:18
Riddellresizing the window will move the text so it stays centred, that's the anchor in use19:19
Riddellso onto tutorial2.qml, which uses multiple files19:19
RiddellThe change here, is a grid containing a lot of cells that are all very similar19:19
Riddellso we want to write the code for the Cell once, and reuse it19:19
Riddellit will load the file Cell.qml to create the Cell type19:19
Riddellso looking at Cell.qml19:20
RiddellItem is just a simple type in QML, which is pretty much nothing but a bounding box.19:20
Riddellthe id is set, we'll call it container19:20
Riddellnext some new stuff19:20
Riddellthe line 'property alias cellColor: rectangle.color' creates a new property on this item, and calls it cellColor19:20
Riddell'property' starts the property declaration, 'alias' is the type of property, and 'cellColor' is the name19:21
Riddellbecause it is an alias type, it's value is another property. And it just forwards everything to that property19:21
Riddell19:22 < maco> QUESTION: so cellColor is like a variable name then?19:22
Riddella property can be a variable, in this case it's an alias so it's just the same as another variable19:23
Riddellin this case rectangle.color19:23
Riddellback in tutorial2.qml we only have a 'Cell'. And the interface for that is whatever is declared in the root item of Cell.qml (we can't access the inner Rectangle item)19:24
Riddell"rectangle" is the item declaired next in Cell.qml, to expose rectangle.color, we add an alias property19:24
Riddellthe 'signal clicked(color cellColor)' line is similar. We add a signal to the item so that it can be used in the tutorial2.qml file19:25
RiddellAnother new element in this file is 'MouseArea'. This is a user input primitive19:25
Riddelldespite the name, it works equally well for touch19:25
RiddellQML can be the entire UI layer, including user interaction19:25
RiddellAnd MouseArea is a separate element so that you can place it whereever you want. You can make it bigger than the buttons for finger touch interfaces, for example19:26
Riddellto make it the exact size of the Item, we use 'anchors.fill: parent'19:26
Riddellwhich anchors it to fill its parent19:26
Riddellless obvious is the 'onClicked' line after that19:26
RiddellMouseArea has a signal called 'clicked', and that gives us a signal handler called 'onClicked'19:27
Riddellyou can put a script (QtScript) snippet in 'onClicked', like in Cell.qml, and that snippet is executed when the signal is emitted19:27
Riddellso when you click on the MouseArea, the clicked signal is emitted, and the script snippet is emitted19:27
Riddelland the script snippet says to emit the clicked signal of the parent item, with container.cellColor as the argument19:27
Riddell19:24 < sladen> can these QML files have (semi-)executable code19:27
Riddellso that answers Paul's question, you can include QtScript (which is Javascript inside Qt)19:28
Riddellto create UIs that do something19:28
Riddellso Cell is a rectangle which lets us set the colour and emits a signal with that colour when it's clicked on19:29
RiddellBack to tutorial2.qml, we can see this interface in use19:29
RiddellIn each Cell instance, we set the cellColor property19:29
=== zkriesse is now known as Guest97205
Riddelland use the onClicked handler19:29
RiddellThe Grid element positions the Cell elements in a grid19:29
=== ZachK_ is now known as zkriesse
Riddellwho's got it working?19:29
Riddell19:30 < sladen> Riddell: how does tutorial2.qml know that 'Cell{}' refers to the Cell.qml file?19:32
Riddell19:31 <+Riddell> sladen: any .qml files in the same directory as the one being run are loaded automatically19:32
Riddell19:31 <+Riddell> and the item name comes from the file name19:32
Riddellif you rename the Cell.qml file then it stops working19:32
Riddellok, who wants some animation?19:33
Riddelltutorial3.qml does animations using states and transitions19:33
Riddella State is just a set of property changes from the base state (called "")19:34
Riddelland a Transition is just telling it how to animate those property changes19:34
Riddellin this file, in the Text element, we add a MouseArea, states, and transitions19:34
Riddellcompared to tutorial2.qml that is19:34
RiddellWe have a State, which we name "down", and the way we are entering it is through the when property.19:34
RiddellWhen 'mouseArea.pressed' changes, that property binding gets revaluated19:35
Riddellwhen mouseArea.pressed changes to true, it makes 'when' true. And so the state activates itself19:35
Riddelland this applies the property changes in the PropertyChanges element19:35
RiddellPropertyChanges has a similar syntax to the rest of QML. Once you set the target, it is just like you are in that item19:36
RiddellSo the 'y: 160' and 'rotation: 180' will be applied as if they were written inside the Text item19:36
Riddellthe transition adds the animation, without it the text just jumps between the two states19:37
Riddellthe from and to properties on the element say which state you are going from and to19:37
=== Andre_Gondim is now known as Andre_Gondim-afk
RiddellThe ParallelAnimation element just groups animations19:37
Riddelland when it runs, the animations in it are run in Parallel19:37
RiddellThe first animation in it is a NumberAnimation, which animates numbers19:37
Riddell'properties: "y, rotation"' means that it will animate the y and rotation properties19:38
Riddellso if these properties changed in this state, on any items, they will be animated in this way19:38
Riddellthe rest of the properites in the NumberAnimation will define this exact way19:38
Riddellduration: 500 means the animation will take 500ms19:38
Riddelleasing.type: Easing.InOutQuad means that it will use an interpolation function that has quadratics on both the in and out parts19:38
Riddellor something like that. The documentation has pretty pictures19:38
Riddellwho's got it running?19:39
Riddellif you click on the text the transition will start until it reaches the new state19:39
=== zehrique is now known as zehrique-brb
Riddellthe position, rotation and colour all change, unless you let go of your mouse button in which case they change back19:40
Riddellif you comment out the    transitions: Transition { ... }   block then the animation doesn't happen19:40
Riddellit just jumps between the two states19:40
Riddell /*  */  and // comments work19:40
Riddelland that is how you get pretty animations without having to code them19:41
Riddellsince animations are going to be important in applications in future, this is an important new tool to make sure free software remains at the lead and the world isn't dominated by iPhone software19:41
Riddell19:41 < mgamal> QUESTION: Can you integrate qml code within normal Qt C++ code?19:42
Riddellyes, and actually you will have to with qt 4.719:42
Riddellqmlviewer won't be installed by distros by default in general19:42
Riddellyou need to load it with QDeclarativeView in your c++ (or python or whatever) code)19:43
Riddellas I said before, this is so new it hasn't been released yet, so consider this a heads up for the future19:43
Riddellalso this code still isn't much use for most designers, so Qt Creator integration is planned19:44
Riddellthen you can just lay your elements out like in Qt Designer and enter the properties through the UI and pick your preferred transition style19:44
Riddellwith any luck it'll get rid of the need for anyone to use Flash19:44
RiddellI think there's even been experimental browser plugins with it19:45
Riddell19:44 < Neo---> QUESTION: are interfaces supposed to be written by coding or is there a graphical editor (possibly in-the-making)?19:46
Riddellthe graphical editor is actually Qt Designer, the IDE you can use is Qt Creator and it integrates Designer very well19:46
Riddellany questions?  comments?  heckles?19:47
Riddellmissed your chance sladen :)19:48
Riddellthanks for coming all19:48
Riddellas ever #kubuntu-devel is open to anyone wanting to help with Kubuntu19:49
Riddell#kde-devel is a good place to get into KDE development, #qt for Qt development and #qt-qml for Qt Quick19:49
Riddell19:48 < sladen> Riddell: what's the latest terminiology re: "signals" "slots" and the like (eg. you've used "signal handler")19:50
ClassBotThere are are 10 minutes remaining in the current session.19:50
Riddella signal handler is a property in a QML item which can handle a signal19:51
Riddellunlike a slot it's in the same item, a slot can be in any object19:51
Riddelland you don't need to connect it, it's connected by just having something in the property19:51
Riddell19:53 < sladen> Riddell: "something" ?19:53
Riddellyes, where the something is probably a QtScript snippit19:53
Riddelle.g.          Cell { cellColor: "red"; onClicked: helloText.color = cellColor }19:53
Riddellsignal is "clicked" signal handler is the property "onClicked" which we set to the QtScript snippit "helloText.color = cellColor"19:54
Riddell19:54 < James147> Riddell: how does scope work with QML? Can child elements see their parents properties?19:55
RiddellI believe there's a "parent" keyword yes19:55
ClassBotThere are are 5 minutes remaining in the current session.19:55
Riddellgenerally you just use the id for each object within that file19:55
Riddelland files are used for items with interfaces so you can't (easily) access items within the top level item in a file19:56
Riddellbut you make sure that top level item has the interface you need, like we did with Cell19:57
Riddell19:55 < sladen> Riddell: so the relationship between 'clicked' and 'onClick' is implicit19:57
Riddellthanks for coming all, hope it was interesting19:58
RiddellI believe Laney and Rhonda will be taking us through "How to work with Debian" in a couple of minutes19:59
* Laney waves19:59
LaneyWe'll get started in a couple of minutes20:00
* Rhonda greets, too.20:00
=== ChanServ changed the topic of #ubuntu-classroom to: Welcome to the Ubuntu Classroom - https://wiki.ubuntu.com/Classroom || Support in #ubuntu || Upcoming Schedule: http://is.gd/8rtIi || Questions in #ubuntu-classroom-chat || Event: Ubuntu Developer Week - Current Session: How To Work With Debian - Instructors: Laney, Rhonda
LaneyRight, let's do this20:01
Laneydo we have people in #-chat? :)20:01
=== zyga is now known as zyga_
LaneyAh yes, good good!20:02
* Laney spots a troublemaker in sebner already :)20:02
LaneySo I'll quickly introduce myself... I'm Iain and I'm going to talk to you today about why you want to work with Debian20:02
LaneyI'm a MOTU developer and contribute to Debian packaging too20:03
LaneyHalf or so of the session will also be given by Rhonda who is a long-time DD and recent MOTU, but she can introduce herself later :)20:03
LaneySo what is Debian? Simply put, it is a hugely important Linux distribution which maintains some tens of thousands of pieces of free software20:04
LaneyAnd almost uniquely in our Linuxy world, it is completely volunteer driven and not controlled by any commercial entity20:04
LaneyThe vast vast *vast* majority of software packages that are present in Ubuntu come from Debian packages in one way or another20:05
LaneyHere's a graph that I found which shows how the packages in Universe are formed: https://merges.ubuntu.com/universe-now.png20:05
LaneyEverything apart from the cyan wedge are packages which came from Debian — the dark blue wedge are those which haevn't been modified in Ubuntu at all20:06
Laneyso you can see how important this project is to us :)20:06
Laney<zyga> QUESTION: is part of getting ubuntu-specific packages in debian part of the talk?20:07
LaneyNot specifically, but I will try and get to this at the end20:07
Laney<simar> QUESTION: Yesterday I attended Danial's class. It was great but after learning packaging I don't know what to do, where to get started and how to help ubuntu. I hope you  will take care of this :)20:07
LaneyThis talk is more about the why rather than the how: It is intended to encourage people to contribute to Debian directly20:08
RhondaIt is also meant to cover how, but for a very specific area. :)20:08
Laney...ok then, so I'm here to convince you to do your Ubuntu work in Debian directly rather than trying to get fixes into Ubuntu. Having the string "ubuntu" in a package version is what we're intending to minimise20:09
LaneyRhonda: Right, my half :P20:09
LaneyThe Ubuntu MOTU team has approximately an order of magnitude fewer developers than there are DDs (people who can upload to Debian), so we have really got no hope of keeping on top of that many packages without help20:10
LaneyBy working together with our biggest partner, we can make the effort of keeping Ubuntu in good shape go as smoothly as possible20:10
LaneyAlso there is another perspective to this partnership: getting fixes pushed upstream (to the source of the software) will help more people benefit from your work, which can't be a bad thing20:11
=== MTeck is now known as MTecknology
LaneyI'm not going to spend time in this session talking about the technical process of how to send your work to Debian, but here are some pointers for that:20:11
Laney  - look at the script "submittodebian" in the ubuntu-dev-tools package20:12
Laney  - look at the program "reportbug" in the reportbug package20:12
Laneyhttps://wiki.ubuntu.com/Debian/Bugs#Using%20submittodebian%20to%20forward%20patches%20to%20Debian this is also a good resource on how technically to go about forwarding bugs20:12
Laneyand as always #ubuntu-motu on freenode is an excellent place to ask any question20:12
ClassBottech2077 asked: When we contribute to debian, and we want a package we made for debian in ubuntu, what should we do20:14
RhondaPackages that are in Debian will get imported automatically into Ubuntu - there usually is nothing needed at all, as long as the next release isn't pending like currently (Debian Import Freeze)20:14
ClassBotari-tczew asked: do I need to be a DD to doing NMU?20:15
RhondaNo, you don't need to - though you'll need a DD to sponsor you to do the actual upload. The NMU itself can be get prepared by anyone.20:15
Laneycontributing RC bug fixes by NMU is a great way to get involved in Debian btw: see various RCBW posts on Planet Debian :)20:16
Laneythanks Rhonda20:16
LaneyRight, so imagine you've found a bug and have managed to identify the fix20:16
RhondaSidenote: NMU stands for Non Maintainer Upload - there is in many packages within Debian a pretty tight maintainer concept of who is responsible for the package.20:16
LaneyIt can be difficult for you to identify whether the fix is appropriate to Debian or to Ubuntu, and additionally whether the fix is serious enough to require Ubuntu uploading right away or whether you can wait for the Debian maintainer to upload and then do a sync from there20:17
LaneyPart of your fixing process should be investigating how far upstream to push the fix:20:18
LaneyIf Debian is also seeing the bug, or if the fix is not specific to Ubuntu in any way — forward to the Debian bug tracking system (using submittodebian or reportbug)20:18
LaneyIf the fix is in the upstream code (not part of the Debian/Ubuntu packaging or any patch therein), then it might be nice to try and reproduce the problem on the vanilla upstream version and then send the patch direclty there20:19
LaneyIf it is somehow Ubuntu specific then just submit to Launchpad for sponsoring20:19
Laneyif you are unsure then ask in #ubuntu-motu as always20:20
LaneyI've dug up a couple of bugs to use as case studies so that we can decide what to do with some real patches20:20
LaneyThe first one is bug #604565 — https://bugs.launchpad.net/ubuntu/+source/motion/+bug/60456520:21
Laneyhave a look at the proposed diff — http://launchpadlibrarian.net/51774081/debian-ubuntu.debdiff — do you guys think this should be forwarded?20:21
Laney<simar> QUESTION: what is vanilla upstream version. Please relate it to bazaar20:22
LaneyIt's useful to download the upstream software from their website and compile it yourself, that way you can tell whether the bug you are seeing is a problem with their software or the way Debian/Ubuntu have set it up20:22
Laneythat's what I mean by the vanilla upstream version20:23
Laneyin bzr terms, perhaps a tagged commit? i.e. one which is an official upstream release20:24
Laneyright, let's move on with the example20:24
LaneyThis is a good case of something which requires a little bit of investigation: the real change is a build-depends change from libmysqlclient15-dev → libmysqlclient-dev20:25
LaneyWhat you'd want to do here is to investigate whether this fix applies to Debian too, to see whether we can forward the patch there20:25
Laneyso we hop over to the PTS page of mysql-5.1 to have a look20:25
Laneythat's this page: http://packages.qa.debian.org/m/mysql-5.1.html20:26
Laneywe can see a package by the name libmysqlclient-dev in the "binaries" list, so that's a good start20:26
Laneywe'll double check the changelog to be sure20:26
Laneythat's here: http://packages.debian.org/changelogs/pool/main/m/mysql-5.1/current/changelog20:26
LaneyIn the entry for 5.1.37-1 we see the message "Drop empty transitional package libmysqlclient15-dev, and provide/replace it with libmysqlclient-dev20:27
Laneythat is a very strong hint that we can indeed apply this fix to Debian too20:27
Laneyso at this point I'd check the bugs list of the original package tos ee if the change is there: http://bugs.debian.org/cgi-bin/pkgreport.cgi?repeatmerged=no&src=motion20:27
Laneyit's not, so now I'd do a test build in a debian environment (e.g. from pbuilder-dist sid create with ubuntu-dev-tools instaled)20:28
Laneyand if this all works, then forward the patch20:28
Laneyand hopefully at the next upload the Debian maintainer picks it up and we can just sync the package again :)20:28
LaneyI got this question in PM:20:29
Laney13/07 20:16:39 <Moomoc> On the Debian site: Am I a Debian Developer when I'm just maintaining one or more packages in Debian, or am I just a Debian maintainer then?20:29
RhondaThe terms Debian Developer and Debian Maintainer come with specific permissions.20:30
LaneyBoth of those terms have technical meanings in Debian: a Debian Developer is someone who has passed through the New Maintainer process and has an @debian.org address. They have almost unrestricted upload access to the Deiban archive20:30
LaneyDebian Maintainer is a more limited set of permissions that is correspondingly not as stringent to achieve. These people can upload to packages they are maintainer or co-maintainer of and have a specific control file field set20:30
Laneyhowever you need have neither of these statuses to comment perfectly well to Debian; you will just have to have your uploads spnosored by someone with access20:31
LaneyRhonda: did you have some questions you wanted to answer now?20:31
ClassBotari-tczew asked: mentors debian page is for new packages?20:31
RhondaThe mentors.debian.net effort is a site for conveniently uploading packages for seeking for sponsors.20:32
RhondaThere are some people monitoring uploads to there, but it is usually adviced to also look on the debian-mentors@lists.debian.org mailinglist or in #debian-mentors on OFTC (irc.debian.org)20:32
ClassBotporthose asked: If you are unable to make it to UDS or DebConf, how is one to get there key signed to become a DM, what alternatives are there?20:33
RhondaThere is a special page in the Debian wiki where you can look for people in your area. Debian Developers are usually found at most bigger conferences and events beside from UDS and DebConf, too.20:34
RhondaThere are alternatives too, but those became extremely discouraged in recent times and only apply to people living really off the track.20:35
RhondaThanks to nthykier, he digged up the keysigning URL: http://wiki.debian.org/Keysigning/Offers20:36
RhondaYou can also ask any DD to look up location information in the debian ldap to find additional people that might live in your area.20:36
LaneyOK, I had another case study which was Ubuntu specific but I'll leave that for now :)20:37
Laneyit was bug 582253 if you're interested20:37
LaneyTo wrap it up, I just want to quickly talk about actualyl maintaining packages in Debian20:38
Laneyyour contributions need not be limited to forwarding individual patches from Ubuntu20:38
LaneyIf you get more involved in Ubuntu development, you will probably find at some point that there is a particular package or group of packages that hold your interest more than the rest20:39
=== Andre_Gondim-afk is now known as Andre_Gondim
Laneywhen this happens to you, it's a good idea to have a look at how they are maintained in Debian and try and get involved directly there20:39
Laneyfor example I am a member of the Haskell packaging team and CLI (~ mono) teams20:40
Laneyall of the advantages of patch forwarding apply here too — reducing deltas, getting your fixes out to more people etc. with the additional bonus that *you* get to decide (or at least help to decide) what gets into the Debian packages20:41
Laneyeven if your fave package isn't maintained in a team, it might be a nice idea to approach the maintainer and offer your time — often times people are pressed for time themselves and would appreciate your help20:41
Laneyand by talking to Debian maintainers directly you will be speaking to people who have direct knowledge of the software they are dealing with — this is not guaranteed to be the case in the MOTU team :)20:42
Laneyright, that's all I had to say for now20:42
LaneyI believe Rhonda has a few words for you, if I didn't take up too much time… :)20:42
RhondaHi. I've sneaked in a few lines already, let me introduce myself properly. I'm a Debian Developer for a very long time who piled up a fair amount of packages to look after.20:43
RhondaOver the time I found out that some of the packages I maintain carried diffs within Ubuntu that make sense for Debian, too.20:44
RhondaSo I wrote to the last person who I found in the changelog doing a change to one of the packages to ask why the changes weren't forwarded to me.20:45
RhondaResponse was mostly "I didn't do the changes, just the last sync."20:45
RhondaOver the time though I was able to convince some of the people to understand that it is good for them to forward patches.20:46
RhondaThere are many good reasons, including that it's covered even in the Code of Conduct ;)20:46
RhondaThe most appealing reason though should be: It means less work! No more merges needed, no checking wether the patch still is required, wether the patch might even produce a conflict, and others.20:47
RhondaWhen a package can easily get synced without requiring a merge, it is a win-win situation for everyone: The fix is available to a broader audience and there is no work anymore for you!20:48
ClassBotNMinker asked: Is there an IRC channel that we can talk to Debian Maintainers, much like we can with the Ubuntu MOTDs?20:48
RhondaThere is a very old channel that was pretty dead over the time but got reactivated recently for this purpose: #debian-ubuntu which lives on OFTC (irc.debian.org)20:49
ClassBotThere are are 10 minutes remaining in the current session.20:50
RhondaI'd like to mention two pages in the Ubuntu wiki that are closely related to this topic:20:51
Rhondahttps://wiki.ubuntu.com/Debian/Bugs mentiones how the Debian Bug Tracking System (BTS) works and how one can interface with it. The approach is a fair bit different to launchpad, mostly in the way that it's email centric and doesn't have a web interface for changing bug status and comments.20:52
RhondaSecondly, https://wiki.ubuntu.com/Debian/Usertagging is also extremely interesting. It helps keeping track of bugs that were submitted to Debian to get an overview of where one might need a little more prodding to get it applied, or find candidates of packages that might require NMUs to get them fixed.20:54
ClassBotRam_Yash asked: Is there any code review tools used?20:54
RhondaUsual people are more happy to receive ready patches to apply to the packages. When they are sent to the BTS they can easily be reviewed by the package maintainer or anyone else interested in the packages.20:55
ClassBotThere are are 5 minutes remaining in the current session.20:55
RhondaA very important question that I still want to address:20:55
Rhonda<fabrice_sp> and what abut DD or DM that are hostile? Is there a way to work around that hostility?20:55
RhondaUnfortunately this is part of the reason why some Ubuntu people rather refrain from forwarding patches or bugs to Debian.20:56
RhondaI'd like to stress that those might be very vocal but on the other hand are a rather small group.20:56
RhondaThe best advice is to try to keep your temper and stay calm. Feel invited to come over to #debian-ubuntu (OFTC) and seek help on advices for how to move on in those areas. Usually there are DDs around who have had their own issues with those people already and found a way to work around already, in the one or the other way.20:58
RhondaI think our time is almost up - next session should start within a few minutes time.20:59
LaneyThanks for coming!20:59
LaneyThe take home message is: always think about Debian when fixing stuff in Ubuntu20:59
* Laney waves20:59
RhondaThanks for listening, and also for the good questions. :)20:59
=== ChanServ changed the topic of #ubuntu-classroom to: Welcome to the Ubuntu Classroom - https://wiki.ubuntu.com/Classroom || Support in #ubuntu || Upcoming Schedule: http://is.gd/8rtIi || Questions in #ubuntu-classroom-chat || Event: Ubuntu Developer Week - Current Session: Setting Up A Small Validation Dashboard - Instructor: zyga
=== zyga__ is now known as zyga
zygafirst of all thanks for joining, I don't know how many people are with me today21:03
zygaI prepared some rough notes and a bzr branch for those of you who will find this topic interesting21:04
zygaalso I'm not sure how classbot and questions work so if anyone could ask me a QUESTION in the #ubuntu-classroom-chat channel I would appreciate that21:04
zygaif not I'll just start talking...21:04
zyga== About ==21:05
zygaValidation dashboard is a tool for both application developers and system integrators.21:05
zygaAt system scope (which is probably not that interesting to most people here) it21:05
zygaaids development of a distribution or an distribution spin-off. More specifically it aids in seeing how low-level changes affect the whole system.21:05
zygaAt application developer scope is aids in visualizing performance across time21:05
zyga(different source revisions), operating system versions and target hardware.21:05
zygait all sounds nice but it's worth pointing out that dashboard is still under development and very little exists today21:06
zygastill it's on schedule to be usable and useful for maverick21:07
zygaI have a branch with some code that is worth using today, I will talk about it later during this session21:07
zyga== How it works ==21:07
zygaValidation dashboard is based on tapping into _existing_ tests and benchmarks21:08
zygathat provide data interesting to the target audience (you, developers). Most21:08
zygaprojects have some sort of tests and already use them for CI (continuous21:08
zygaintegration), some have test suites but no CI system as some are difficult to21:08
zygaset up and require effort to maintain.21:08
zygaDashboard takes CI a step further. First by allowing you to extend a CI system21:08
zygainto a user-driven test system. When users can submit test results you get much21:08
zygamore data from a wide variety of hardware. Second you can test your unchanging21:08
zygasoftware (a stable release branch) against a changing environment. This will21:08
zygaallow you to catch regressions caused by third party software updates that you21:08
zygadepend on or that affect your runtime behaviour by being active in the system.21:08
zygaFinally the biggest part of launch control is the user interface. While I'm21:08
zygajust giving promises here the biggest effort will go into making the data easy21:08
zygato understand and easy to work with. Depending on your project you will have a21:08
zygadifferent requirements. The dashboard will allow you to21:08
zygaThe dashboard will allow you to show several kinds of pre-defined visualizations, depending on the kind of data your tests generates21:09
ClassBotporthose asked: is it working21:10
zygait works, thanks21:10
zygaand will also allow you to make custom queries (a variation of the pre-defined really) that will show some specific aspect of the data such as comparing one software version to another or comparing results from different hardware, etc21:11
zygaso that's the good part, next I'll talk about how the dashboard operates internally and what is required to set one up (once it's ready to be used)21:12
zygaso the bard part is you need to put some effort to use the dashboard, an initial investment of sorts21:12
zygayou have to do some work to translate your test results into a format the dashboard will understand21:13
zygaDashboard understands a custom data format that encapsulates software profile, hardware profile and test results (both tests and benchmarks). You get half of the information for free but you have to invest in writing a translator or other glue code from whatever your test suite generates into dashboard-friendly format.21:13
zygaA python library (that already exists) has been created to support this. Anyone can get it from my bzr branch by executing this command: bzr get lp:~zkrynicki/launch-control/udw launch-control.udw21:14
zygayou can get the branch now, I'll use it for one example later on21:15
zygaso a little back story now, dashboard is a project created for the arm world, arm hardware is really cool because it is so diverse and can scale from tiny low power microcontrollers all the way up to the multicore systems that have lots of performance21:16
zygaone of the thing that is not good about such diversity is validating your software stack on new hardware configuration, you really need some tools to make it efficient and worth your effort in the first place21:17
zygaso a couple of people in the linaro group are working on a set of tools that will make it easier, dashboard (aka launch-control) is one of them21:17
zygaso enough with the back story21:18
ClassBotktenney asked: url to look at while waiting?21:18
zygaktenney, I made a presentation about the initial assumptions of what the dashboard is about, I'm not sure if that is what you asked for. The presentation is here: http://ubuntuone.com/p/6fE/21:20
zygaokay so at the really low level the dashboard is about putting lots of lots of samples (measurements of something) into context21:21
zygayou can think of samples as simple test results21:21
zygasamples come in two forms one for plain tests and other for benchmark-like tests21:22
zygamost of the work you have to do to start using this is to translate your test results into this sample thing, fortunately it's quite easy21:22
zygaif you check out the branch I posted earlier (bzr get lp:~zkrynicki/launch-control/udw launch-control.udw21:23
zygaif you look around you'll see the examples directory21:24
zygainside I wrote a simple script that takes the default output of python's unittest module output21:24
zygaand converts that into a dashboard samples21:24
zygaand packages all the samples into something I call bundle that you will be able to upload to a dashboard instance later on21:25
zygaso let's have a look at that code now21:25
zyganote: this is developed on maverick so if you have lucid and hit a bug, just let me know and I'll try to help you out21:25
zygaI'm sorry for saying this but I'm on holiday and I'm away from my workstation where I have a much better infrastructure21:26
zygathe client side code will run on a wide variety of linux distributions and will require little more than python2.521:26
zygathis branch might fail but it's just a snapshot of work in progress developed on maverick21:27
zygaso first thing is to get some test output21:27
zygaif you just run the test case (test.py) it will hopefully pass and print a summary21:28
zygaif you run it with -v (.test -v) it will produce a much more verbose format21:29
zygathat's the format we'll be using, redirect it to a file and store it somewhere21:29
zyga(by default unittest prints on sys.stderr so to capture that using a bash-like shell you must redirect the second file descriptor: ./test.py -v 2>test-result.txt )21:30
ClassBotpenguin42 asked: What's the flow? Is the idea the dashboard runs somewhere central (like launchpad) or that each developer might have his own copy for his own test runs?21:30
zygapenguin42, great question thanks21:30
zygapenguin42, so the flow is kind of special21:30
zygapenguin42, we have decided NOT to run the centralized dashboard instance ourselves as it would defeat the linaro-specific requirements21:31
zygapenguin42, so to cut to the chase, you host your own dashboard,21:31
zygait's going to be trivial to set one up21:31
zygaon a workstation21:31
zygaor a virtual machine21:31
zygaor some server you have21:31
zygawe'll make the deployment story as easy and good as possible as we expect (we == linaro) to get this inside corporations that develop software for the arm world and we want them to have a good experience21:32
zygathat said it's still possible that in the future launchpad or other supporting service will grow a dashboard derived system, there is a lot of interest for having some sort of tool like this for regular ubuntu QA tasks21:33
zygabut the answer is: currently you run your own21:33
ClassBotpenguin42 asked: Is it possible to aggregate them - i.e. if there are a bunch of guys each doing this, or if a bunch of organisations are each doing it?21:33
zygasorry for loosing context, could you specify what to aggregate21:34
zygacurrently I see this being used (during the M+1 cycle) by linaro and some early adopters that will want to evaluate it for inclusion into their tool set, so I expect project-centric deployments21:36
ClassBotpenguin42 asked: n-developers each working on an overlaping set of packages, each running their set of tests; is there a way multiple dashboards can aggregate test results to form a n overview of all of their tests?21:36
zygapenguin42, yes multiple developers can use a single instance to host unrelated projects and share some data (possibly)21:37
zygapenguin42, so to extend on your example, you can have a couple of developers working on some packages in some distribution (one for simplicity but this is not required)21:37
zygapenguin42, and while each developer sets up something that will upload test results (daily tests are our primary target)21:38
zygapenguin42, you can go to the dashboard and see a project wide overview of how your system is doing21:38
zygapenguin42, if there are any performance regressions21:38
zygapenguin42, new test failures21:39
zygapenguin42, overall test failures grouped by test collection (my term for "bunch of tests")21:39
zygapenguin42, our current targets are big existing test projects such as LTP or phoronix21:39
zygathey have lots of tests that look at the whole distribution21:39
zygaso many people can upload results of running those tests on their software/hardware combination21:40
zygaand you can look at that on one single page21:40
zygaon the opposite spectrum you can have multiple projects (such as "my app 1" and "my app 2")21:41
zygathat for some reason share a dashboard instance21:41
zygaand have totally unrelated data inside the system21:41
ClassBottech2077 asked: Will this be available stable before maverick, i heard it would be stable at the time, but what is the stable release time frame21:42
zygasorry I'm on GSM internet here and I have some lags21:42
zygawe have to speed up a little21:42
zygatech2077, it will be available by the time maverick ships in a PPA21:43
zygatech2077, our target is inclusion in N21:43
zygaI'll get back to the session now21:43
zygaso we ran the test suite I have written for the client side code21:43
zygaand placed the results in a test-result.txt file21:44
zygathe results themselves are a simple line-oriented (more less) format21:44
zygathe interesting bits are lines that end with " ... ok" and " ... FAIL"21:44
zygaparsing that should be easy21:44
zygaIf you run ./examples/parse-pyunit -i test-result.txt -o test-result.json21:45
zygayou'll get a test-result.json file, go ahead and inspec it21:45
zygathere is some support structure but the majority of the data is inside the "samples" collection21:46
zygaso this is the easiest way of translating test results21:46
zygatests have no individual identity21:46
zygaand all you get is a simple pass/fail status21:47
zygaeverything else is just optional data, like message we harvested in this case21:47
zygathis is very weak as we cannot, for example, see a history of a particular test case21:47
zygabut it was very easy to set up21:47
zygathe next thing we'll make is to turn on a feature I commented away21:48
zygain examples/parse-pyunit find the line that says bundle.inspect_system() and remove the comment # sign21:48
zygaif you run the parser again you'll get lots of extra information21:49
zygathis is the actual data you'd submit to a dashboard instance21:49
zygayour test results (samples)21:49
zygasoftware profile (mostly all the software the user had installed)21:50
zygahardware profile (basic hardware information, cpu, memory and some miscellaneous bits like usb)21:50
ClassBotThere are are 10 minutes remaining in the current session.21:50
zygathe profiles will make it possible to construct specialized queries and to filter data inside the system21:51
zygaokay so I have 10 minutes21:51
zygaI'd like to talk a tiny bit about samples again to let you know what is supported during this cycle21:51
zygaand spend the rest on questions21:51
zygaso there are qualitative samples (pass/fail) tests21:51
zygathey have test_result (mainly pass and several types of fail)21:52
zygaand test_id - the identity21:52
zygaif you start tracking test identity you need to make sure your tests have an unique identity that will not change as you develop your software21:53
zygathe primary use case for this is specialized test cases and benchmarks21:53
zygaa test that checks if the system boots is pretty important21:53
zygaa benchmarks that measures rendering performance needs identity to compare one run to all the previous runs you already stored in the system21:53
zygaidentity is anything you like but it's advised to keep it to a reverse domain name scheme21:54
zygathe only thing the system enforces is a limited (domain name like) characters available21:54
zygaif you look at the pydoc documentation for launch_control.sample.QualitativeSample you can learn about additional properties21:55
zygathe next important thing is QuantitativeSample - this is for all kinds of benchmarks21:55
ClassBotThere are are 5 minutes remaining in the current session.21:55
zygaand differs by having a measurement property that you can use to store a number21:55
zygaif you have benchmarks or want to experiment with adapting your test results so that they can be pushed to the dashboard please contact me, I'd love to hear your comments21:56
ClassBottech2077 asked: is python coverage available for lucid, it seems to depend on it21:57
zygatech2077, python-coverage is not strictly required, it's just for test coverage of the library21:57
ClassBotdupondje asked: when running it I get ImportError: No module named launch_control.json_utils, whats the right package I need to install ?21:58
=== Andre_Gondim is now known as Andre_Gondim-afk
zygadupondje, none, just make sure to run this from the top-level package directory, or set PYTHONPATH accordingly21:58
zygain general if you want to make sure you have all the dependencies see debian/control21:59
ClassBotpenguin42 asked: Has it got any relation to autotest (autotest.kernel.org)21:59
zygapenguin42, no21:59
zygapenguin42, actual test frameworks are not really related to the dashboard22:00
zygapenguin42, dashboard is just for visualizing the data and for having a common upload "document" (here a .json file)22:00
=== ChanServ changed the topic of #ubuntu-classroom to: Welcome to the Ubuntu Classroom - http://wiki.ubuntu.com/Classroom || Support in #ubuntu || Upcoming Schedule: http://is.gd/8rtIi
zygatime's up22:00
dupondjeyou have some visual example ?22:01
zygadupondje, just mockups, I'm working on the visual parts really22:01
zygadupondje, (actually I will next week, I'm still on holiday)22:02
dupondjehéhé ok :)22:02
* zyga keeps getting bitten by mosquitoes just to get internet here22:02
zygadupondje, what I can tell you today is that I'll probably use open flash charts for the on-screen rendering22:03
penguin42a whole new meaning to bugs with your net connection22:03
zygathe hard part with visualizing is to make it really easy to make custom graphs that you want to show (as in asking for the right data)22:03
zygasome of this is really skewed to linaro and arm world but much I hope will apply to general PCs and upstreams that develop software22:04
zygaif upstreams start producing more tests and start to look at feedback from various runtime environments (during their daily development process) then the dashboard project will succeed22:05
zygathat's all from me, if you want please contact me at zygmunt.krynicki@linaro.org22:05
=== iqbal_ is now known as Cr`eme

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!