On Friday bzr-upload was officialy announced. In the blog announcement Martin tells the story of how this plugin was born. I'm proud to say "I was there!". I was sat at the table with them that evening as they discussed what was wanted, and what was possible. This was just one of the great things about the last sprint for me, and I was only there for two days.
Very often on the #bzr IRC channel we have users asking why bzr doesn't update the working tree on a remote machine, and what they can do about this. Very often it turns out that they are web developers who are looking to deploy a website, rather than just host the branch, and so the normal behaviour is kind of the opposite of what they want.
John wrote the push-and-update plugin to help with this, but it didn't fulfil all the needs, and requires ssh access, where web developers sometimes only have ftp access.
While bzr-upload does have some corner cases to be wary of, it's a great thing to have available. If you are web developer who is looking for a version control system for your code then consider bzr, it will hopefully suit your workflow very well.
Now, watch out for Martin's improvements to loggerhead, and Vincent's improvements to his kitchen.
I love Stephen Fry, everything he does is great, but also seems to come with a touch of quality as well. His documentaries are probably a lesser known part of his work, but they are equally fantastic; the two-part documentary on manic depression was particularly notable.
Last night a watched a new documentary presented by him, and while it was neither as moving or as personal as the others I have seen it was still interesting and enlightening. This particular documentary was about Johannes Gutenberg, the printing press that he invented, and the impact which this had upon the world.
He explained that the printing press, and the increased access to knowledge that it allowed, was a major factor in the Renaissance, which radically changed the world, and can be seen in the world in which we live today.
In Gutenberg's time the Church was the most powerful organisation. He worked with the church, and tried to show them the benefits of his idea to them. It was suggested that he would never have succeeded if he had not courted the Church. If the printing press was indeed the catalyst for the Renaissance, and the Renaissance was the start of the decline in the power of the Church that we see today, then the Church's embrace of the printing press could be said to have precipitated their loss of power and influence.
Are there any ideas at the current time that are as powerful as the idea of the printed word? During the programme their were a couple of references to the growth of the printing press being similar to that of the growth of the Internet in recent years.
The Internet, like the printing press before it, allows a new group of people to have direct access to information. Will that access cause a fundamental shift in our world and our lives?
Is there a dominant force in the world which will be diminished by the Internet? Are they currently embracing it as a tool which they can use to entrench their position? Are we thinking too small; is there something we haven't thought of yet that is going to have an even more radical impact?
Now that one important release is out the way it's time to look forward to another one. This has been long anticipated, and will probably decide whether they go on to great new heights, or are just remembered for their previous contributions, but aren't considered relevant any more.
No, I'm not talking about the Fedora release, that is definitely relevant, and is sure to be great. I'm talking about the release of "Third", the new album from Portishead. Fingers crossed it's going to live up to the legacy.
Oh, and if you don't know, get to know.
Thanks to richb I found this recipe for "Jerk Pork Burgers with Green Apple Slaw", and they are fantastic. The Slaw is particularly good, I'd really recommend you try it, even if it does sound a little weird.
Unfortunately, it appears as though "The Bell", a pub just round the corner, no longer serves food. No matter how good a burger is, I'm sure there's no way it could be as good as a Bell Burger. It seems I'm stuck spending the rest of my days trying in vain to recreate that marvellous piece of meat technology.
One thing that Bazaar does a little different to the other distributed systems is to give every revision a revision number. Some people don't like this as the revision numbers are global, that means that the revision number of a revision in my branch does not necessarily match the number that it was given in your branch. Some people say that this makes bzr somehow "less distributed." This is not the case at all, you just need to be careful to be clear what branch you are referring to, i.e. say "revision 315 on branch http://...", rather than just "revision 315".
This is a little dangerous in that the branch may have it's revision history changed, for instance by uncommitting and then committing again. If that may happen then you should use revision ids, which you can find from "bzr log --show-ids".
Why do number the revisions at all then? One reason is simply that some people find revision ids ugly, and may be scared off by them.
Another reason is that they are shorter to type. git folks will tell you can use the first few characters of the revision id, and git will work out what revision you mean. However these shortened ids are not necessarily stable over a long period of time, and so again, if you are worried you should use the whole thing.
The third reason is that the numbers can give some sense of the order of the revisions in your branch. If I say talk about revisions "3445abe" and "b27ac9" then you don't know which is earlier in history. If I refer to revisions 345 and 532 then it is immediately obvious (providing that I am only referring to a single branch).
The advantages I have outlined are small, but they could be valuable at times, and you always have the revision ids to fall back on if you require them.
Along with numbering the mainline bzr also numbers merged revisions using a dotted numbering scheme. This means that your mainline revisions are "1", "2", "3", as you would expect, but any merged revisions are given three digit numbers, e.g. "2.1.3".
The numbering scheme has a couple of nice properties, the most notable of which is that it is "stable", this means that once I have numbered a merged revision with respect to a certain mainline it cannot be effected by any addition I make to the revision history. This means that any commits, pulls or merges that I do will not change any of the existing revision numbers, but they will add numbers to any new merged revisions such that they will not be the same as any number already used.
The current algorithm used for this involves looking at the whole history of the branch to number the revisions, which is obviously undesirable.
On the last evening of the sprint last week myself and John were discussing the numbering scheme, and thinking about possible algorithms to do the numbering that would be more efficient.
We had the following inputs:
- The revsision id you are trying to give a dotted number for.
- The tip of the mainline that you are numbering against.
- The revision number of that mainline revision.
- A map of revision_id -> parents.
And you are asked to provide the revision number for the specified revision. Any other numbering that you may be able to do along the way would be a bonus.
The fact that all we are given to get the information we need is a map telling us the parents of a revision id means that we cannot ask the question "what are all the children of this revision?"
I don't really want to explain the numbering scheme here, as it is a little long-winded to do so. The outline is that for the first digit you find the intersection of the target revision's left hand ancestry with the mainline, and use its revision number. For the second digit you find all of the branches that originated at the revision found in the first part, and then number them by the order that they merged back in to mainline. The third digit is then just the place of the revision in its own part of one of these branches.
Notice the second step there. Remember that we are not able to retrieve the children of any revision? That means that we must work backwards from our mainline to do this. This is where the real complexity comes in, and it appears as though it is necessary to search a reasonable amount of history to calculate this part.
After the discussion with John I had a reasonable idea of how such an algorithm would work, and yesterday I posted a first draft of that to the mailing list. We have found some problems with it, and haven't benchmarked it yet to see if it is actually an improvement, but hopefully it will evolve and prove to be faster.
The revision numbering code has a very close relationship, and also interacts with it in an awkward way from a performance standpoint. This lead to John explaining to me how the logs are generated in more depth.
When bzr produces logs by default it emphasises the left hand parent to produce your mainline. It then indents any revisions that you merged:
> ----------------------------------------------------------- > revno: 3270 > committer: Canonical.com Patch Queue Manager <pqm@pqm.ubuntu.com> > branch nick: +trunk > timestamp: Thu 2008-03-13 00:40:30 +0000 > message: > (Adeodato Simo) Add a space after "revision-id:" in log output. > ----------------------------------------------------------- > revno: 3257.2.1 > committer: Adeodato Simó <dato@net.com.org.es> > branch nick: foo > timestamp: Sun 2008-03-09 23:06:47 +0100 > message: > Add a space after "revision-id:" in log output. > ----------------------------------------------------------- > revno: 3269 > committer: Canonical.com Patch Queue Manager <pqm@pqm.ubuntu.com> > branch nick: +trunk > timestamp: Wed 2008-03-12 23:08:34 +0000 > message: > (Daniel Watkins) Add a --revision option to 'bzr push' > ----------------------------------------------------------- > revno: 3256.1.5 > committer: Daniel Watkins <D.M.Watkins@warwick.ac.uk> > branch nick: push-r > timestamp: Sun 2008-03-09 18:41:31 +0000 > message: > Added NEWS entry.
To do this it must decide which revisions are present in the history of one revision, but not in the history of its left hand parent. To do this it starts off two history walkers in parallel, one walking the history of the first revision, the second walking the history of the parent. The first walker then stops walking down a particular line of history when the second "claims" it, once the first walker has no more lines of history to walk it returns its group of revisions, and the log formatter code then displays them indented as necessary to match the history.
This is a much more complex process than that you get with "git log", in which the revisions are produced in just date order. There is a "--topo-order" option to git log, but that just ensures that all parents are output before their children. It doesn't ensure that all parents not in the ancestry of the left-hand parent are shown before the left-hand parent. The work to ensure that is significantly more than that done to provide "--topo-order".
This display makes it easy to see what work was done on a branch, and when those changes entered your branch. This is one reason why bzr's merge doesn't fast-forward by default ("bzr merge --pull" will do this for you if you like). This means that you can always instantly identify which work came from another branch and have them tied together.
Always having merge commits means that "bzr log --short" and "bzr log --line" can give you a good summary of what happened on your branch, the commits you did, and the things that you merged. It preserves a mainline for you in the left hand ancestry, which means that you can always see what happened in that particular branch. "bzr pull" then gives you a mirror of another branch, and the left hand ancestry tells you what happened in that branch.
The indentation of the merged commits (and the fact they disappear with "--short" and "--line") means that mentally they become of lesser importance. You see "merged performance work from Emma's branch", rather than all of the commits that you got from her. They are still there to look at if you want, but they can be ignored at most times.
This means that you don't have to spend time rewriting history to be clean if you don't want to. You don't have the history right in your face either way, though there can still be value in having a clean history. However rewriting history is not what some people want to do, and causes problems for those who base their work on yours.
So apparently "learning git is like learning vim". Putting aside the incremental learning aspects of this, and stretching the point a little, will you allow me to say "git is like vim"?
We all understand there is no way in which you would mandate that all contributors use vim. You wouldn't want to lose all of those valuable contributions from emacs users of course. However, you still wouldn't dream of mandating the use of one of these two editors. Why should your choice as project maintainer constrain the way in which others want to work?
Obviously it is quite difficult to enforce this editor rule. For a start there is nothing in a plain text file that tells you what editor was used to create it. More importantly though, the contributor's choice of editor doesn't matter to you. If they send you a plain text file then your editor will handle it just as well as theirs.
This is where version control differs from editors. When using the version control system to move code around it tends to dictate the client you use to access it, so one person's decision tends to impact on others.
Is the solution therefore to work towards a situation we have that is similar to that we have with text editors, where the interchange format is understood equally well by all of the tools? Do we spend time developing wrappers for each use that allow us to ignore the fact that we are using different systems?
Recently there has been work done to make bzr support the git-fast-import format. This would then be the start of an interchange format that all tools could use to communicate. However, the problem is that the representations used in one system start to bleed. For instance, bzr supports ghosts, and we are currently discussing the adding support to the format to represent them. However git doesn't support them, and as such there will be know way to complete a round trip of bzr->git->bzr when there are ghosts involved.
So, what about the other solution? Creating wrappers that allow the user to not care what VCS they are using and just get the job done? I think this is useful to a point. It will be great for some people who just want to do really simple things on lots of projects (for instance in Debian). However the tools are necessarily catering to the lowest common denominator, they won't support any of the unique things that make each system great.
Bazaar has foreign branch support (most notably bzr-svn) which allow you to access another system as if if were bzr. This is almost completely transparent ("bzr branch svn://" makes it clear what the project is hosted in), in contrast to git-svn. The latter adds a new command that allows you to do the svn specific parts (setting up the repository, committing back to svn). In contrast bzr-svn uses the normal bzr commands for (almost[1]) everything, meaning you only need to learn the one tool. git-svn is still a great tool, but it certainly makes you realise that you are not dealing with pure git.
The competition between the systems has been great for every one of them. However, it seems like we will be stuck with different systems for the forseeable future, so we should work hard on making them work well together to ease the pain on the users. I think that many of the supporters of distributed version control would say that it is better for you to be using any of them than none of them, but the fractured and unstable landscape we have now is causing a resistance in people to make the switch.
| [1] | It currently adds svn-push for doing a push that creates a new branch in svn, but this is only a temporary thing, "bzr push" will be able to do this at some point. The other commands that are added are for extra things that the core bzr is not meant to deal with. |
The lecturer who taught me evolutionary computing was also a devout Christian, who believed that the world is the way that it is because God created it, rather than it evolving via natural selection.
This was quite surprising to us when he revealed this, but he did not see a problem with holding this view. He recognised that there was a fundamental conflict between Darwinism and Creationism, but not one between his work and his religious beliefs. He could see that the theory of natural selection could be an effective optimisation algorithm where the form that the solution would take was not entirely clear, but it was not his belief that this was the mechanism by which humans arrived on this earth.
It's an interesting feature of science that he was able to hold this position and still research in the field. At one point in the year he did give a lecture on creationism itself. This was not one of the lectures that made up our course, it was an optional lecture at luchtime, open to the whole engineering faculty and other members of the University. I did not attend, but many people got very excited beforehand, seeing it as a chance to go and argue with a holder of this belief and try to discredit the idea. Perhaps they were also spurred on by the fact that he was a man of science, and so potentially more likely to listen to an argument of logical reasoning.
I don't think anyone convinced him, and I doubt anyone ever will, he has obviously confronted this issue many times in the course of his work and still holds the two potentially conflicting ideas in his head.
I came up with this the other day. It's pretty rich and indulgent, but not too hard to make. The lamb could perhaps do with something else, but I can't think of anything at the moment.
- 4 Lamb steaks
- New Potatoes if in season, otherwise any small potato.
- 4 Carrots
- 2 Red onions
- Bunch of rosemary
- Garlic cloves
- 2 glassed of red wine (a small bottle is fine). A good hearty one if possible
- Gravy powder
- Thyme (dried works fine)
- A knob of butter
- 3 Tablespoons Brown Sugar
If you can prepare the lamb the day before it will be better, but a couple of hours is fine. Place the lamb steaks in a small container. Take a third of the rosemary, and snap it a couple of times and place it in with the lamb. Next bash open the garlic cloves (there's no need to peel them first) and add them. Get your hands in there and rub both in to the meat, mixing it up. Next add a glass of wine, cover and leave to marinate.
About an hour put some oil in a baking tray and place it in the oven to heat up. Brush the potatoes clean then drop them in the hot oil, add some salt and pepper and snap the remainder of the rosemary and drop that in. Put them back in the oven.
Next brush the carrots clean (you can peel if you like), and chop them in to batons. Then quarter the two onions. Melt the butter in the frying pan over a hot heat. Add the carrots and onion, and stir fry for a few minutes. Then add the sugar and keep stirring. After a while you can turn the heat down to a medium heat. Keep stirring regularly, as they will like to stick.
After about 15 minutes place the lamb under the grill on a medium heat. Make up a serving of gravy in a saucepan, adding one more teaspoon of mixture than suggested. Add the second glass of wine, and put on a low heat on the hob.
When the lamb is cooked to your satisfaction then remove the potatoes from the oven and plate up. Next add the carrots and onions, and finally the meat. (I like to stack the ingredients here). Finally tip the juice from the meat in to the gravy and turn the heat right up and stir for one minute. Finally pour a little gravy on each plate and serve.
Enjoy!
A lot of my friends are on the Facebook site, and they upload pictures there, so I joined to see those. One of the things the sute has is a profile picture, and I wanted to upload one for me. I chose one and entered the filename in the box. The other part of the form was a checkbox to accept the terms of use for the site. Presumably every user accepts these as they sign up, but having it there as a reminder about the parts on content is admirable perhaps. Anyway I clicked on the link to read those parts out of interest.
After reading them I clicked the upload button, but had neglected to check the box, and up popped a message:
You must certify that that image is not copyrighted before you upload. Please click the checkbox to certify.
After learning about copyright and license issues throught libre software this sort of thing jars with me now, so I sent a message off to the admins (after searching for ages for some sort of contact form).
My problem with the above message is that it is incorrect and misleading. It is incorrect as that is not what the box is for, the box is to agree to the terms of use. The terms of use include some statements on copyright, but not that the material uploaded must be free of copyright. Perhaps a short detour in to the law of copyright (as I understand it) is warranted.
Copyright is associated with a creative work, and usually is automatically assigned to the author upon its creation. This requires no special action on the part of the author, though if they are sensible they will add a copyright statement to the work to let people know when it was copyrighted and by whom. Having the copyright on a work allows you special priviledges with respect to that work.
Now just because I have the copyright on a work doesn't mean that you can't use it, but for you to do that I must have granted you a license. A license is nothing more than a statement of what you are allowed to do with the work. They can be very simple, or very complex.
Very often in the media they refer to people distributing copyrighted work when they are discussing music or film piracy. While this is true, it is not exactly the problem, the problem is that the copyright holders (the music and film companies) have distributed the work under a license that does not allow redistribution. This means that even though they have sold you the film, you can't pass it on to other people.
On the cases of CDs and films you can find the copyright statement with the familiar (C) symbol. Next time you see it read past that and look at the next bit. Usually it will say something along the lines of:
Unauthorised copying, hiring, lending, public performance and broadcasting of the record are prohibited.
Which is a license stating that you can't do much with the CD you have bought.
However it is not the most restrictive license you can have. If a work has no license attached it then it should be assumed that you shouldn't even be looking at it. This can obviously be slightly problematic.
So this means that the facebook notice above is incorrect, as what they want is not non-copyrighted material, as the copyright of most (all?) of the photos on there will be held by someone (it doesn't expire for quite some time). What they want to know is that the person uploading has permission to distribute the file on their site.
You may think that I am just being picky over terminology, but I believe that this misuse of language is actually keeping people in the dark. Whenever the media, or a website, or someone I meet talks about whether a work has copyright or not as being the deciding factor in whether it can be distributed it continues the misunderstanding. If everyone were to understand that when they create a work they have the copyright of it, and must grant a license so that it can be used by others then they may be more inclined to do so. In fact I believe that many people would grant very free licenses, massively increasing the amount of free content available.
Take Flickr for instance they provide the user with an easy way of providing their pictures under one of several good licenses. Most of the pictures I have seen on that site are provided under the more free choices.
The other problem with facebook's approach is that their terms of use ensure that they have a license to host the picures, but they don't ensure anything about what the users can do with them. This means there is a mass of content, but it is all unusable by others due to the unclear situation. This is a very common problem, and could be mitigated by more people understanding the issues.
Hannah is very interested in radio, and is planning to set up her own Internet radio site. I wanted to try out icecast to see whether it would be suitable. I have jotted down a few notes about how to set it up here as I couldn't see any others.
Firstly get the server and the streaming client:
aptitude install icecast2 ices2
Then edit /etc/default/icecast2 to enable the daemon, and /etc/icecast2/icecast.xml to set the passwords.
Then
/etc/init.d/icecast2 start
Then
cp /usr/share/doc/ices2/examples/ices-playlist.xml .
and set the password in ices2-playlist.xml to be the stream password you set above.
Then create playlist.txt with the names of some .ogg files, one per line.
Then run as root
ices2 ices-playlist.xml
and test using
mplayer http://localhost:8000/example1.ogg
Hopefully this should be enough to get a stream going, and then you can configure it how you want.
I returned today and I had received the email I had been waiting for.
To: James Westby <jw+debian@jameswestby.net> From: Debian Installer <installer@ftp-master.debian.org> Date: Fri, 18 Aug 2006 07:00:09 -0700 Subject: seccure_0.2-1_i386.changes ACCEPTED Accepted: seccure_0.2-1.diff.gz to pool/main/s/seccure/seccure_0.2-1.diff.gz seccure_0.2-1.dsc to pool/main/s/seccure/seccure_0.2-1.dsc seccure_0.2-1_i386.deb to pool/main/s/seccure/seccure_0.2-1_i386.deb seccure_0.2.orig.tar.gz to pool/main/s/seccure/seccure_0.2.orig.tar.gz Override entries for your package: seccure_0.2-1.dsc - optional utils seccure_0.2-1_i386.deb - optional utils Announcing to debian-devel-changes@lists.debian.org Closing bugs: 378987 Thank you for your contribution to Debian.
Thanks to those that helped me to get this in, and especially the author for a cool bit of software. He has just released a new version, so I will package that and upload it soon.
We hadn't really realised but some gnutls related packages are Priority: Important, and as such are due to be frozen soon for etch. There has been some upstream activity in the area recently, with several releases. Luckily the timing was really good, and the uploads made it in such that they should progress to etch quickly, without causing any trouble for the release team.
Also there has been some action from a couple of the maintainers holding up the gnutls11 and libtasn1-2 removal. This just leaves two packages, one of which the maintainer has tagged pending, and nutmeg has just upgraded the bugs to serious to try and prod the maintainers. It is possible then that removal can be requested before the release team calls the freeze that is supposed to include these packages.
gnutls13 builds a gnutls-dev package, which will make this easier in the future... until there is an API change and we have to switch back to gnutlsXX-dev and get all packages to migrate again. It is hard to know which is the better approach, but at least this way it only requires rebuilds while things stay calm.
The other day I decided I wanted to try out one of the more modern revision control systems. I decided on bzr as it seemed to have some features that I liked the look of. I still intend to try out darcs one day though, as it looks very interesting.
Just as I started looking at it and thinking about using it for some of my packaging work, I discovered that there was no -buildpackage for bzr. But lo, madduck filed an ITP for it. However he said that it didn't actually exist yet.
I decided I would try and help to write something, even though I have hardly ever touched Python before. It was quite easy to hack something together by looking in examples. I ended up with a plugin that worked for me to build simple packages from a bzr repository, including supporting the layout where just the debian/ dir is versioned (the mergeWithUpstream of svn-buildpackage). You can find my work here, (in a bzr branch of course). The plugin is actually called builddeb, as it seems Fedora are keen on something similar, and so we didn't want to hog the namespace. The Debian package will probably include a wrapper script named bzr-buildpackage though.
There is plenty that can be added on, for instance config files are needed, and madduck would like to include hook script capability within the branches, but this is going to take some careful thought.
I have quite enjoyed working in Python, it allows you to do things "properly" if you want, but also can be very terse. I've not grasped all of the features yet though.
After I got a working wireless card I was finally able to fix the xfce4-wavelan plugin. After I had ported it to the Xfce 4.4 API it stopped working on a lot of systems. I don't think that I caused this, I think it was more the recompilation against updated wireless stack in the kernel that was what highlighted it.
The fix was quite simple in the end. I looked at the source of wireless-tools, and came up with this diff.
It seems some implementations interpreted the 0 as some large number or similar, most took it to mean 0, and returned E2BIG. Setting it to the size of the returned object allowed it to work.- wreq.u.data.length = 0;
+ wreq.u.data.length = sizeof(struct iw_statistics);
Until I get a goodies account sorted out then I will host the release at http://jameswestby.net/debian/, including some unofficial Debian packages.
[Update: I have just release 0.5.2 as well, this fixes the other bugs that I wanted to. Only one left that I know about (stats slightly wrong sometimes, but I don't know if that can be helped).]
So after I had such a problem with my rt2500 based card, I ordered an rt61 based one. It arrived this morning, and it works. Here's what I did to get it to work.
First download the cvs snapshot driver. The beta release one doesn't work, and you shouldn't try it. Untar it and go in to the Module subdir. Then run make. The make install looked a little dodgy to me, so I copied the driver across and ran depmod.
# cp rt61.ko /lib/modules/$(uname -r)/kernel/net/wireless/ # depmod -a.
Then grab the the firmware from RaLink and unzip the files in to /lib/firmware.
Then add the alias
# echo "alias ra0 rt61" >> /etc/modprobe.conf
The interface will be called ra0, so change any config files (e.g. /etc/network/interfaces) to reflect this. You should then be able to ifup ra0 and have the interface work. Good luck!