/srv/irclogs.ubuntu.com/2009/06/04/#ubuntu-classroom.txt

=== txwikinger2 is now known as txwikinger
=== ajmitch_ is now known as ajmitch
maxpagurusalve here i am06:56
RockyRoad!seen mvo07:06
ubot2I have no seen command07:06
dholbach<dholbach> hello everybody07:13
dholbach I just tried calling mvo, to no avail... I hope he's OK still07:13
dholbach shall we make this an impromptu Q&A session about Ubuntu Development and Packaging instead?07:13
dholbach who's here for the session?07:13
dholbachdon't be shy... raise your hands! :-))07:14
juanjeme! :-)07:14
* micahg is here :)07:14
* juanje hugs dholbach ;-)07:14
arao/07:15
* dholbach hugs y'all back :)07:15
mbuddeo/07:16
dholbachdo you have any questions about ubuntu development, about packaging, maybe even a specific problem that you're dealing with at the moment... some general thoughts about how ubuntu development works? anything we could help out with?07:16
maxpaguru°/07:16
* juanje thinking about....07:17
micahgI had a build fail on me07:18
micahgbut I think it was because a patch was out of date07:18
dholbachmicahg: do you have a build log somewhere?07:18
micahghttp://launchpadlibrarian.net/27434400/buildlog_ubuntu-jaunty-i386.acidbase_1.4.3.1-0ubuntu1~ppa1_FAILEDTOBUILD.txt.gz07:18
dholbachlet's see07:18
dholbachyes07:19
dholbachdpatch  apply-all07:19
dholbachapplying patch 01_default_config to ./ ... ok.07:19
dholbachapplying patch 02_update_external_links to ./ ... failed.07:19
micahgI didn't check the patches before uploading07:19
dholbachthat's because a patch is out of date07:19
micahgok07:19
micahgI'll look into it another time07:19
dholbachdoes everybody know what dpatch is and how it works?07:19
maxpagurunot so much ;)07:20
dholbachgreat :)07:20
juanjea bit07:20
dholbachso dpatch is one of the patch systems we use for packaging07:21
dholbachbecause we don't use distributed development with a clear history of changes for everything yet07:21
dholbachit sometimes makes sense to separate out patches07:21
dholbachso let's say you're packaging a huge piece of upstream software and the software authors do one release every year07:21
dholbachin that case you might come into a situation where you need to make changes their code or backport fixes07:22
dholbachit can get very hard to stay on top of what's happening and who changed what if you just apply all changes directly on the source07:23
dholbachthat's why some package maintainers decide to put separate patches (one for every issue) into the debian/patches directory07:23
dholbachacidbase, as micahg mentioned above, makes use of dpatch07:23
dholbach01_default_config seems to make some changes to the default configuration, and applies fine07:24
dholbach02_update_external_links unfortunately doesn't07:24
dholbachthe way that dpatch works is quite simple07:24
dholbachyou basically just run:07:24
dholbach   dpatch-edit-patch 03-new-patch-that-fixes-bug-123456707:24
dholbachand it will open a new shell environment, where you can make all kind of changes07:25
dholbachwhen you hit Ctrl-D to close the shell, it will create a new file called debian/patches/03-new-patch-that-fixes-bug-1234567.patch07:25
dholbachthat includes the diff of what you just did07:25
dholbachthen you add 03-new-patch-that-fixes-bug-1234567 to debian/patches/00list (for internal housekeeping) and it will automatically get applied during the build07:25
dholbachdoes that make sense?07:26
mbuddeYes it does :)07:26
dholbachhttps://wiki.ubuntu.com/PackagingGuide/PatchSystems#dpatch maybe makes it a bit clearer07:26
RockyRoadnice tool :)07:26
dholbach(and has a quick example)07:26
maxpaguruyes indeed!07:26
dholbachdpatch apply-all / dpatch unapply-all are useful commands too07:27
dholbachI hope one day we can get rid of all patch systems when we have full source imports in bzr though and keep track of all the history in there07:27
mbuddeIs there a preferred patch system (dpatch, quilt, ...) or does that depend on the package?07:27
dholbachmbudde: I think it depends on what the package maintainer likes best07:28
dholbachquilt seems to be the new black right now, but I really never grew to like it :)07:28
micahgwow07:29
micahgdpatch-edit-patch is cool07:29
micahgit does it all for you :)07:29
dholbachas nice as patch systems are for housekeeping (backport fix to version A, delete patch file, when version A+1 gets out), a bzr merge <upstream branch> is much more obvious :-)07:29
dholbachI guess we should have James Westby here as a speaker again, he's the man when it comes to distributed development :)07:30
dholbachdo we have any other questions?07:30
mbuddeI have a problem with a package I'm updating.07:31
micahgis there a way to set a default key for signing with debuild?07:31
dholbachmicahg: yes, hang on07:31
mbuddehttp://launchpadlibrarian.net/27276693/buildlog_ubuntu-jaunty-i386.purple-plugin-pack_2.5.1-0ubuntu1~ppa3~jaunty_FULLYBUILT.txt.gz07:31
dholbachsomething like this in your .bashrc should do the trick:07:31
dholbachexport DEBFULLNAME='Daniel Holbach'07:31
dholbachexport DEBEMAIL='daniel.holbach@ubuntu.com'07:31
dholbach(and make sure that email address is a key id on your gpg key)07:32
micahgdholbach: I have 2 keys for the one address07:32
micahgdon't ask...07:32
mbuddeI get a whole lot of dpkg-shlibdeps warnings, is there any way to stop that?07:32
mbuddeOr is it a problem at all?07:32
dholbachmicahg: I think you can specify the key id somewhere, but I'd need to look it up07:32
micahgok07:33
micahgI know I can do it on the command line07:33
dholbachmbudde: that looks more like an upstream problem to me - it might make sense to have a chat with the upstream authors about it07:34
mbuddeOk :)07:34
dholbachmbudde: but those warnings are not critical at all07:34
dholbachthere might be something wrong with the linking (sorry, I'm no expert there)07:35
dholbachdo we have any more questions... maybe more general questions?07:35
dholbachmbudde, micahg: good work - I'm happy you're working on some packaging stuff already07:36
mbuddeIt's fun! :)07:37
dholbachis there anything you'd like me to talk about a bit?07:37
mbuddeWhat about getting stuff back into debian?07:37
maxpagurui'd like to know how to use bugs in LP07:37
dholbachmbudde: check out https://wiki.ubuntu.com/Debian/Bugs (there's the 'submittodebian' tool in ubuntu-dev-tools which makes forwarding patches really easy)07:38
micahgI just started :)07:39
dholbachmbudde: now is a really good time to forward stuff to debian: we're merging lots and lots of packages right now and if you see a delta that could as well go to debian, forward it07:39
dholbachmaxpaguru: can you elaborate? what kind of bugs?07:39
dholbachor is there anything in particular that you're wondering about?07:40
=== MaWaLe is now known as tunisian
=== tunisian is now known as MaWaLe
maxpaguruhow to handle bugs in general , from where to begin , i'm a very newby;)07:41
dholbachok07:41
dholbachso let's say you found a simple bug that you want to work on and fix it07:41
=== ziroday is now known as zeroday
dholbachyou'd go and download the current source package by running   apt-get source package-you-want-to-fix07:42
dholbachthen you'd make the simple change in the source tree07:42
dholbachthen you'd document it, by running      dch -i07:42
dholbachyou'd add a new changelog entry, properly explain what you did to fix it07:42
dholbachand add    (LP: #1234567)   to the changelog entry07:43
dholbachwith the bug number of the bug you're working on07:43
dholbach(ah... before that you'd probably assign the bug to yourself and set the status to 'in progress')07:43
micahgindeed07:44
dholbachthen you'd run        debuild -S      to regenerate the source package07:44
micahgdholbach: why not make it a patch?07:44
dholbachmicahg: I'll get to that in a bit07:44
micahgok07:44
micahg:)07:44
dholbachthen you'd test-build the package (you could use pbuilder for that: https://wiki.ubuntu.com/PbuilderHowto)07:44
MaWaLesorry for interferring : where can i find the log of the classroom (i missed it :( )07:44
dholbachMaWaLe: https://irclogs.ubuntu.com - it gets updated every now and then07:45
MaWaLethx dholbach :)07:45
dholbachalso I'll put it up later at https://wiki.ubuntu.com/Packaging/Training/Logs07:45
micahgapprox every hour07:45
dholbachthen you'd test the resulting package, make sure the bug is really fixed07:45
maxpagurudholbach: Thanks where the tutorial links to that stuff . are there?07:46
dholbachthen you'd run07:46
dholbach   debdiff package-you-want-to-fix_old-version.dsc package-you-want-to-fix_new-version.dsc > package-you-want-to-fix.debdiff07:46
dholbachthis would generate the full patch (in package-you-want-to-fix.debdiff), that you could attach to the bug report07:47
dholbachthen you'd subscribe ubuntu-main-sponsors (if the package is in main/restricted) or ubuntu-universe-sponsors (if it's in universe/multiverse)07:47
dholbachand somebody will take care of reviewing it and uploading it for you07:47
dholbachthe nice thing about "(LP: #1234567)" is that the bug will automatically gets closed, when the package is accepted07:48
dholbachthe docs for that are available at: https://wiki.ubuntu.com/PackagingGuide/Recipes/Debdiff07:48
dholbachAndrewGe1: https://wiki.ubuntu.com/SponsorshipProcess07:48
dholbachsorry AndrewGe1 - automatic tab completion07:49
dholbachmaxpaguru: did that make sense so far?07:49
maxpagurudholbach: great it's much clearer!07:49
dholbachawesome!07:49
dholbachany more questions? :)07:50
juanjedholbach: so, the better way to fix a bug is with a debdiff? I missed the UDS' session about patches, debdiff, branches and I was wondering which one would be the better way. I usualy try to attach a bzr branch with the fixes so the maintainer can merge the changes07:50
juanjebut I don't know if this is the better way07:50
dholbachjuanje: if the package is in bzr already, the branch is probably the better option07:51
juanjedholbach: ok07:51
maxpagurudholbach: I understand , it's clear i have to follow these steps one by one in detail. tnx so much07:51
juanjedholbach: and how the changelog should be changed in a debdiff?07:52
dholbachjuanje: in that case, you could do something like:    bzr push --fixes lp:1234567 lp:~juanje/package-you-want-to-fix/my-fix07:52
juanjedholbach: yeah, make sense, thanks :-)07:52
dholbachjuanje: if you ran   dch -i    before, you added an entry in the changelog, which will turn up in the debdiff file07:52
maxpaguruwhere to find bzr tutorial?07:53
dholbachhang on07:53
juanjedholbach: yes, but I mean if you write it like you were writting your onw package or as other people (the maintainer) will change it after?07:53
dholbachmaxpaguru: http://doc.bazaar-vcs.org/bzr.dev/en/mini-tutorial/index.html07:54
dholbachfor general bzr use07:54
dholbachand https://wiki.ubuntu.com/DistributedDevelopment/Documentation for use in the packaging / ubuntu development context07:55
maxpaguruok ;)07:55
dholbachjuanje: I'm not quite sure I understand - can you give me an example?07:56
juanjemaxpaguru: this could be useful as well: https://wiki.ubuntu.com/BzrMaintainerHowto07:56
juanjedholbach: yeah, sorry, I didn't explain myself well....07:56
juanjedholbach: what I mean is that when you fix some package07:57
juanjeand it's not yours07:57
juanjedo you have to "propose" a changelog?07:57
maxpagurujuanje: thanks I'll follow all those links!07:57
juanjeor write the changelog as the final one07:58
juanje?07:58
dholbachwe don't have the concept of "package maintainer" in Ubuntu07:58
dholbachso we all maintain all packages as a team07:58
juanjeummmmm07:58
juanjeok07:58
juanje:-)07:58
dholbachso it definitely helps if you add a changelog entry07:58
juanjedholbach: but, if you are not MOTU or so?07:58
dholbachjuanje: then you still add a changelog entry and put up the full debdiff (or branch) for review through sponsorship07:59
juanjeok07:59
juanjeunderstood :-)07:59
dholbachperfect07:59
dholbachit's important that you put a lot of effort into documenting your changes07:59
dholbachI usually write changelog entries like this:07:59
maxpaguruBye everyone I'll see the log later :-)08:00
dholbach  * src/something.c, src/something.h: remove all occurrences of "frobnicator", changes taken from upstream SVN commit 1542, fixes the build again (LP: #638153)08:01
dholbachthat way people will see: which files you changed, what you changed, why you changed it and that the upstream developers did the same thing, plus you close the current Ubuntu bug08:01
dholbachit's important we do that, because as I said above: we all maintain packages as a team08:02
juanjedholbach: I usually write the changes on the bzr log and when I make changelog entry in it, but I had some doubts about if then the maintainer had to rewrite it (also maybe changing the version or so). Actually my doubts were more about the version you put to the changelog entry08:02
dholbachso the next uploader of the package doesn't have to guess why you did a certain change08:02
dholbach... or you won't have to guess your intentions half a year later :)08:02
juanjedholbach: agree :-)08:02
dholbachjuanje: usually dch -i should do the right thing08:02
juanjeit's very important :-)08:02
juanjeok08:02
dholbachjuanje: if you add a new changelog entry and run debcommit afterwards, it will use that changelog entry for the bzr commit message :)08:03
dholbach...two bird with one stone...08:03
juanjeummmm08:04
juanjeI swa something about debcommit, but I haven't try yet08:04
dholbachjuanje: you have a question?08:04
dholbachit's good stuff :)08:04
juanjeI think, I'll try :-)08:04
dholbachrock on08:05
dholbachok... thanks everybody! if you have any more questions, please feel free to join #ubuntu-motu and ask questions there08:05
dholbachwe're happy to help you out!08:05
juanjedholbach: thanks for all!08:05
juanje:-)08:05
dholbachmvo's session will be rescheduled - I'll let you all know about the session in a bit08:05
dholbachthanks everyone and have a great day!08:06
RockyRoadthx dholbach :)08:06
mbuddedholbach, thank you!08:06
dholbachmy pleasure :)08:07
maxpaguruthanks to dholbach and everyone! :-)08:07
aramvo session will be today at 15:00UTC08:09
aramore details on the planet today :)08:09
juanjembudde: do you have some where the code from the package you got the fail?08:09
juanjeara: thanks :-)08:09
juanjembudde: I have some ideas about the warnings I like to confirm. I you don't mind08:10
mbuddejuanje, great! :) You can get the package from my PPA: https://launchpad.net/~mbudde/+archive/ppa08:11
juanjembudde: thanks :-) I tell you latter ;-)08:12
mbuddejuanje, if I'm not online please do send me an email08:13
juanjembudde: sure ;-)08:15
ricecomtoo late.. :(08:15
ricecombye08:50
=== zeroday is now known as ziroday
MetralhaThis session was too early for me...:(09:39
* MaWaLe is away: brb10:35
* MaWaLe is back (gone 00:01:34)10:37
=== pipedrea1 is now known as pipedream
iahello. could you tell me, please - the next classroom about packaging will be in 6:00 UTC pm? or it has been already at 6:00 am?12:08
=== nhandler changed the topic of #ubuntu-classroom to: Ubuntu Classroom || https://wiki.ubuntu.com/Classroom || https://lists.ubuntu.com/mailman/listinfo/ubuntu-classroom || Upcoming: 4 June, 15:00 UTC: Make Your Package Upgrade Correctly; 11 June, 12:00 UTC: Java library packaging || Run 'date -u' in a terminal to find out the UTC time
nhandleria: The next packaging training session is at 15:00 UTC today due to a scheduling conflict12:14
=== ejat is now known as e-jat
=== yofel_ is now known as yofel
mvo_hello!15:59
=== mvo_ is now known as mvo
mvowelcome everyone - and sorry that I could not make it this morning15:59
mvoand a special thanks to dholbach for doing a Q&A16:00
dholbachmvo: no worries :)16:00
* iulian m00s16:01
mvoI'm going to talk about how to make package upgrade cleanly16:01
mvoI will give a overview on the common problems I see when looking at upgrade failure logs16:01
toabctlhi16:02
mvoon the bright side: dpkg/apt tend to do pretty well - but if stuff goes wrong recoverying is not a great user experience16:02
mvoso we should try to make sure that stuff does not get wrong :)16:02
keffie_jayxo/16:02
mvo(and improve our tools to deal better with failures)16:02
mvoif you have any questions or special topics that you would like to talk about, just ask here (or in #ubuntu-classroom-chat)16:03
Riniahello everybody16:04
mvoI prepared some notes, if there are no questions/comments I will just paste a bit into the channel16:04
keffie_jayx:D16:04
mvo= How to make packages upgrade cleanly =16:05
mvoNormal deb packages usually upgrade just fine, dpkg takes care of all the heavy lifting and shuffling of files. The most common source of problem on upgrades are:16:05
mvo• file overwrite problems (e.g. when a package was split)16:05
mvo• maintainer script problems16:05
mvoA general good advise is to keep the amount of code in the maintainer script small and clean. Shell is a language that can be tricky and a failure in the script will make the upgrade abort and gives the user a bad experience.16:05
mvothe most common source of overwrite problems are caused by package splits16:07
dholbachmvo: why are package split? does that happen very often? is ther an example? :-)16:08
mvobut they can also happen if two package just happen to install the same file into the same location. if that can not be avoided (e.g. by changeing the program to look into a different location) the package can not be installed in parallel and should conflict16:08
mvofor a package split we use a different technique16:08
mvodholbach: thanks, I give a example now :)16:08
mvo== Package splits ==16:08
mvoIf a package foo gets split into two packages like foo and foo-common there needs to be a "Replaces" line in the "foo-common" package. The reason is that on upgrade, the new package "foo-common" may get installed when the old "foo" is still installed. Because the foo-common has files that belong to the old foo dpkg will complain if the proper "Replaces" line is missing.16:08
dholbachwoohoo16:08
mvothis is pretty common for projects that start out as e.g. update-manager and then later grow new frontends (like udpate-manager-text). then the package typically gets split into update-manager-common, update-manager-gtk, update-manager-text etc16:09
mvoExample:16:10
mvo foo 1.0 is a big package16:10
mvo foo 1.1 is split into foo and foo-common16:10
mvofoo-common now needs a line:16:10
mvoReplaces: foo (<< 1.1)16:10
mvoto ensure that if the new foo-common is unpacked before the foo package is upgraded everything still works as expected.16:10
neurobuntuhow does (<< 1.1) differ from (< 1.1) ?16:10
mvoneurobuntu: the "<" is a older (and now deprecated way) of expressing the same. it used to mean earlier-or-equal16:13
mvoneurobuntu: but its a bit confusing, this is why "<<" and "<=" etc are now used16:13
mvoThe most common case is something like the following for "foo":16:13
mvoDepends: foo-data (= ${source:Version})16:13
mvoThis means that dpkg needs to unpack foo-data first before it unpacks the new foo. So without the Replaces line above it will not work.16:13
neurobuntuok thanks16:13
mvocheers16:14
mvoany questions on this particular bit (splitting/overwrite problems)?16:15
mvoI should note that we have a system that can check for file conflicts in the archive, but its currently in the need for some bugfixing16:15
dholbachwhat is a good way to test if my packages upgrade well? is  dpkg -i *.deb  good enough?16:16
mvodholbach: yes, that is a good way. its a good way of testing before a upload to make sure the current version is installed16:17
mvoand then install the new package like this16:17
mvothe good news is that for the common case (package just got some new files/some old files got removed) dpkg will do everything16:17
mvoand we do not have to worry16:17
mvotesting is always good, its pretty anoying if a forgoten "fi" in a maintainer script causes problems later :)16:18
mvowhich brings me to the next topic:16:18
mvo== Maintainer script problems ==16:18
mvoWe have two classes of issues here16:19
mvoone are "just" bugs16:19
mvoa forgoten "fi"16:19
mvothe use of bash syntax (like "==")16:19
mvoinstead of POSIX (which expects "=")16:20
mvoetc16:20
mvo(we use dash as /bin/sh so we need to be careful with that, some other distros do not have this problem)16:20
mvothe other class of problems is that the system is in a flux during a complex upgrade (like a upgrade from 6.06 -> 8.04 :)16:22
dholbachmvo: what are maintainer scripts? is there a good way to test them? :)16:22
mvodholbach: good point, sorry for using jargon :)16:22
dholbach(I hope everybody else feels free to pester mvo with questions too and it's not just me. :-))16:22
mvomaintainer scripts are the scripts known as: "prerm, postrm, preinst, postinst"16:23
mvothey are run as part of the package installation16:23
toabctlmvo, are they makefiles? or just shellscripts?16:23
mvothey can contain any shell code and are used for stuff like "ldconfig"16:23
mvotoabctl: usually shell scripts, some contain perl too (notable stuff that uses debhelper)16:23
neurobuntuwhen upgrading a package, are the prerm and postrm run (almost like the old package is removed before the new is installed)?16:24
mvoneurobuntu: yes they are. I have a example for this in a bit, it can become relatively complex16:25
mvoa maintaner script may alter the system state in any way, this is why we do not support rollbacks or downgrades in a general way. because it may simply be not possible to undo (or know) what a maintainer script did16:25
mvo(but that is just a side note :)16:25
dholbachmvo: is there any way to test them or do I just re-install the package to see if it worked?16:26
mvodholbach: they can be tested by running them with the approprate arguments (simulating the way they are called by dpkg). this can be very helpful, especially when run with "sh -x" to see line by line what is actually happening16:26
mvoI will give a example for this16:27
mvoProblems here are usually caused by the fact that the system is in a pretty unusual state during a upgrade. Some packages are half-installed, some are not available etc. Maintainer scripts should not make too many assumptions about the system because during a upgrade those may well be wrong. A script should gracefully whenever possible.16:27
mvoIts useful to know how maintainer scripts get called:16:27
mvohttp://debid.vlsm.org/share/Debian-Doc/debian-policy/ch-maintainerscripts.html has all the details in Section "6.5".16:27
mvoThe way apt works is that it splits the changes into dpkg runs that get called with "--unpack" and then "--configure". On a typical upgrade, this is:16:27
mvoUnpack:16:27
mvo•  old-prerm upgrade new-version16:27
mvo• new-preinst upgrade old-version16:27
mvo• files from the new package are now in place16:27
mvo• old-postrm upgrade new-version16:27
mvoConfigure:16:27
mvo• postinst configure most-recently-configured-version16:27
mvoneurobuntu: I hope the table below anser the earlier question16:28
neurobuntuyes it does16:28
mvoso quite a bit of script that are run :)16:28
mvoand if something goes wrong, it gets even more complext, if e.g. the old-prerm fails, the new-prm is called16:28
neurobuntuwhat is the logic behing running the new preinst and copying the new files before running the old-postrm16:28
mvothis can be useful when recovering from a mistake in a maitainer script16:28
mvoneurobuntu: a good question. I currently do not have a good example, generally the postrm is there to do final cleanup16:32
mvouseful for e.g. update-menu or something similar that updates the debian menu and needs the new menu files to get reliable data16:33
mvo(not the best example in the world I guess :)16:34
mvoThe time between unpack and configure can be pretty long (on release upgrades) because apt tries to put as much work into a single dpkg run as possible (to speed things up, dpkg invocation is slow).16:34
RailFYI, detailed information about maintainer scripts can be found at http://www.debian.org/doc/debian-policy/ch-maintainerscripts.html16:34
mvoRail: thanks! especially section 6.6 is interessting here16:36
mvoThis can be tricky if critical functionality relies on the work that is done in configure. A example is python when the symlinks get removed in preinst and re-created in postinst. This means that the package python functionality is not available during a release upgrade (people can not play certain gnome-games ;) Its also common for daemons that stop in preinst and start again in postinst). Often this is unavoidable, but it should be kept16:36
mvo in mind when thinking about the package maintainer scripts.16:36
mvogenerally I would recommend writing small and simple maintainer scripts if at all possible, the less complexity the less likely are bugs :)16:37
dholbachmvo: is there a way to avoid maintainer scripts easily?16:38
mvodebhelper takes care of a lot of this16:38
mvoe.g. the ldconfig scripts are all auto generated16:38
mvoor the python magic16:39
mvoor init stuff16:39
dholbachor is there a way around having to write (really good) shell scripts? :)16:39
mvoand thats good, auto-generated code is nice because it needs to be fixed only in one place if a errorr is found16:39
mvoanother new development is the increased use of triggers16:40
neurobuntutriggers?16:40
mvotriggers are a way to express a interessted in a certain directory for example16:40
mvoits a relatively new concept16:41
neurobuntuok i'll be sure to read up on them16:41
mvoa package like e.g. "man-db" tells dpkg that its interessed in changes in /usr/share/man16:41
mvoand everytime a file is installed there, dpkg will notice that and mark the trigger as pending16:41
mvothen dpkg will run the pending triggers at the end16:42
mvo(or when needed)16:42
mvoso it runs the man-db.postinst with "triggered" as argument16:42
mvoand the man-db package then processes the new man-pages and builds a db from them16:42
neurobuntuso man-db says its interested in /usr/share/man I install package foo which installs /usr/shar/man/foo.man and then dpkg runs the man-db.postinst?16:43
mvothis is a very useful concept because it means that mandb can be run when everything else got installed (needs to be run only once)16:43
mvoneurobuntu: yes16:43
neurobuntuwow thats really slick!16:43
mvoneurobuntu: re "configure" (from #ubuntu-classroom-chat")16:44
mvothe configure here is something different, it just shares the same name with the autotools configure16:45
mvodpkg roughtly splits a package into "unpacked" and "configured"16:45
mvounpack means the files are in place16:45
mvoconfigured means that the package is actually usable16:45
mvothe switches are "dpkg --unpack $long_list_of_packages"16:45
mvoand dpkg --configure $long_list_of_packages"16:46
mvoin a way, this is a performance optimization to avoid having to call dpkg too often16:46
mvoeach time dpkg is run it builds a (internal) database of all installed files and the relations16:47
mvothat can be time consuming16:47
mvoso the less times dpkg needs to be called, the better16:47
neurobuntuok that makes sense...  forgive me if you answered this earlier but after the files are in place (dpkg --unpack),  preinst gets run?16:47
neurobuntuor are all the preinst scripts run before the unpack happens and then all the postinst scripts are run?16:48
mvoneurobuntu: the preinst script gets run before the new files are in place. this can cause bugs, we had a package that tried to start a daemon in preinst, but the daemon was not on disk yet, so the package was not installable (or rather, installed, but always gave a error message)16:49
mvoia: thanks for your question - this is a tricky one16:49
neurobuntuok thanks16:50
neurobuntuthis is making sense16:50
mvoia: the python problem we had were hard to reproduce because the system is in so much of a flux during a upgrade. its tricky to get this right. in my experience jaunty-final did pretty well and the cases of failure were rare16:50
mvobut its a good example why complexity in maintainer scripts is generally something that may not work so well16:50
mvobecause its hard to predict the environment in which the script is run, that may depend on the installed packages on the system that is upgraded etc16:51
mvovery hard to reproduce16:51
mvowhat we can  do now is upgrade-testing on real HW16:52
mvothere is a update-manager --sandbox switch16:52
mvofor jaunty->karmic upgrades16:52
mvothat will perform a upgrade into a writeable filesystem snapshot in /tmp - but it keeps the real system unchanged (or rather, restores it on the next reboot)16:53
mvothis is quite useful to test real world upgrades16:53
mvochroots (e.g. pbuilder login) or other tests are useful too16:53
mvowe plan to have a auto-upgrade-tester package for karmic that can be used to test system upgrades of any given input packages, lets see how this goes :)16:54
mvoI guess the summary is: the best way for us (as a distro) to ensure clean upgrades is lots of testing (on a wide range of setups)16:54
mvofor the maintainer: write good, clean, small maintainer scripts :)16:55
iamvo: ok, thanks :-)16:56
mvo(for the specific python problem we plan to change the way the python packages are done to invlove a little bit less magic :)16:56
mvofor karmic16:56
neurobuntumvo thanks this has been really helpful16:57
mvothanks for comming and listening!16:58
mvoand asking good questions of course :)16:58
mvoia: the auto-upgrade-tester is a project that can perform a full upgrade in a virtual environment17:00
mvoit can use chroot, kvm and ec2 (the later is still a bit experimental)17:00
mvokvm is really the most useful one17:00
mvoyou give it a base image that can be any kvm image (e..g build via ubuntu-vm-builder) and then it will perform a release upgrade from the installed version of ubuntu to the next using update-manager in a non-interactive session17:01
mvothat takes ~1h on my realatively slow system17:01
mvoafter that I can see if the given image upgrades cleanly or if there are issues17:02
mvoits very useful as a QA tool17:02
mvoits currently only available via bzr, but we want to package it17:02
mvoso that everyone can test and play with it17:02
mvothe base-image is not touched, so when a failure happen a fix can be tested as well with it17:03
mvoe.g. when python-foo does not upgrade cleanly (but only in a complex dist-upgrade), a fix can be uploaded to a test PPA and the upgrade can be pointed to that PPA to test if the fix is really good17:04
mvodoes that answer the question? or should I expand on a particular are more?17:04
mvoarea17:04
iamvo: yep, thanks for answer :-)17:05
mvo:)17:05
mvoif there are no further question I say thanks for comming and have a good day17:10
Railmvo: thank you17:10
Railand others for questions17:10
Rail /close17:27
=== MaWaLe is now known as MaWaLe_
=== MaWaLe_ is now known as MaWaLe__
=== MaWaLe__ is now known as MaWaLe
=== MaWaLe_ is now known as MaWaLe
=== k00011 is now known as k0001
=== bazhang_ is now known as bazhang

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