Older blog entries for dan (starting at number 9)

So, I think there are enough people here with Lispish tendencies that we could set up the Advogato sexp-fiends webring.

If your idea of ideal syntax involves parens and prefix notation, send me mail, or make a note in your diary and certify me as something so that I actually bother to go and check your diary

Right now the ring is empty because I've only just had the idea

Hypothetically, if someone were to certify everybody who certified him at the same level, everybody would certify him as Master, to get the equivalent level themselves. As more people did this the value of his counter-certification would increase as he'd become very well-connected.

Hmm

Stayed at work late last night, got half the required amount of sleep, flaked aout at about 5pm and went home to sleep some more. Now awake again (it's about 1am)

More sockets. gethostbyname now works, and I feel a rant about type punning coming on (why do they pretend IP addresses are "network-endian integers" - wouldn't life be a zillion times easier if everyone just admitted it's an array of 4 bytes?)

Spent most of the day with emacs, jade and dia on this silly document. The tools are far more interesting than the content. dia is really neat, did I mention that already? All it needs is an embedded lisp with a prototype-based object system to create new objects with `behaviours'.

Not a lot got done. I was going to spend the day hacking more sockets, finishing the aforesaid docbook document (more day-job stuff) and installing Linux on a customer box: in fact, I stayed in bed until 4pm then groused around the flat in a lethargic kind of way. Sundays are often like that.

I got halfway through gethostbyname() support (which is not necessarily DNS, just "whatever the name service switch says to use") then went out for a walk to see what parts of London I might reasonably want to live in, what parts I could afford and whether there's any crossover. Clapham Junction is actually in Battersea, apparently. And only twenty minutes walk from the river, which would be kind of nice.

If anyone knows anyone with a large studio or 1br flat in Zone 2 available end March, send me mail. Professional n/s, deposit, refs, etc etc. Yeah, this is not the appropriate place to be advertising ;-)

How does gethostbyname() deal with DNS timeouts? It could get tedious if the caller is supposed to simulate them with alarm()

It wasn't a quiet week, it just looks like it. It was a day-job week

Short summary, no particular order:

  • Learnt minimum acceptable amount of DocBook, wrote document.
  • Wrestled with stylesheets to get it to print using >50% of the page area
  • Installed dia. Learnt minimum acceptable amount of UML, started fiddling with UML-syntax class diagrams. Project for someone with more free time than I have: parse the dia save file and create classes in (your choice of programming language) from it. I still don't see how to illustrate a multiply-specialised method in UML. I wonder if the need has occurred to anyone
  • Typed up my errno rant as an article here. Thus far nobody has replied, so I guess I should have talked about advogato instead
  • Eventually got as far as some more socket code. Now I have a working client. Probably. I checked it in w/o writing test scripts, aren't I naughty?
  • Came across more jwz docs, including one of two web pages about java that I've found worth reading. The other is Peter Norvig's

(It's still the 20th in my personal timezone. Dunno what zone this server thinks it's in though)

So apparently everyone else was bored today

I wasn't

Ner

More sockets; it's theoretically at the point now that you could write a TCP server with it. You wouldn't actually want to as there's not yet any way to setsockopt(SO_REUSEADDR)

And Paolo Amoroso (why does he not have an account here, hmm?) posted a pointer to Araneida on comp.lang.lisp yesterday. Then Rainer Joswig apparently saw that and forwarded it to the cl-http list. So far today it's had more hits as a result than at any time since I apachebenched the server. And I bet I've made a good impression on the cl-http developers ("Why? Because cl-http is not free"). Not that I care overly

I found the Keirsey thing again. I'm still IN[FT]P. Surprise

This is actually yesterday's diary entry. I haven't got out of bed yet today

More sockets. I can now successfully socket(), bind() and check errno. The last of the three is what actually took real time. I have two rants about POSIX-as-implemented-by-Linux and type punning by C programmers, but they're both for another time. One of them will probably even be an article here.

And I fixed my cvsweb installation, by deleting the $CVSROOT/history file. "cvs -l co " really ought not to bail out if it can't write history, but it seems that it does

Random advogato idea: people should be allowed to post comments on other people's diary entries. Precious little of the content here ever goes anywhere near the front page.

I'm kind of unsure about the purpose of thse diary entries - originally I thought they were supposed to describe free software projects, but nobody else is using them for that

So, hey, I guess I can write anything I like. Today I hacked a little more on my socket interface, and set up a nearly-functional cvsweb interface to same - and to araneida

Actual ability-to-see-the-files sometime this weekend when I'm sober again

Oh, and random other observation: Sourceforge seems to have the aim of becoming the one-stop shop for free software project support services - CVS, FTP, mailing lists, bug tracking etc

It has no Logo Competition management software! Whose glaring oversight was that?

What do I do for fun? Right now, I'm writing a socket interface which is eventually intended for SBCL because it doesn't have one. I'm developing using CMUCL, as the two systems are basically compatible and I don't much like the CMUCL one anyway.

USPs of this one:

  • sanified Berkeley Socket-ish interface - looks fairly similar to Perl's IO::Socket, but with explicit bind/listen instead of keyword arguments in 'new'.

  • all structure layouts (sockaddr_in, etc) and symbolic constants (AF_INET, SOCK_DGRAM, etc) figured out by a twisted piece of Lisp that runs the C compiler to generate a Lisp file (programs that write programs, mmm) which we then load in. Done this way because the C compiler is, when you get right down to it, the only thing that actually knows how to parse a C header file.

  • rational error handling

Today I've been attempting to understand the CL condition system (concept not unlike Java Exceptions, but - as is normal for CL - far more flexible and trickier to get ones head around). I also got lent a copy of "Extreme Programming Explained" - watch me not link that title to Amazon - so I've been doing some of that lovely automated test creation stuff too, using the regression tester in the CMU AI repository.

I'll spare you the code samples until advocado starts letting me put <pre> tags in here

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!