Recent blog entries for neoneye

Today its Xmas with snow outside. Bought lots of presents to the family. I have already gotten the nicest present myself [ruby-talk:124287], its a solution on how to do Unicode with xterm. I need this for version 2.x of AEditor. This present alone is more worth than most other presents. I have learned valuable stuff about [Ruby DL], which is truely an amazing piece of code.

Lexing of embedded documents has gotten my attention lately. For instance in HTML you can embed JavaScript and CSS. In Ruby you also can embed other documents. I wish to make a lexer that can colorize these embedded documents in a nice way, and maybe even provide extra shortcuts for programming in that embedded language. How do I figure out what kind of document that is being embedded? For Ruby it could depend on the name used for the heredoc.

doc = <<XHTML11
im xhtml 1.1
So that could be colored as XHTML. Maybe it will be too disturbing to color it with the same colors as the primary document. Some dimmed colors would probably feel better.

Recently I have put some effort into making a riffoff of [Werkkzeug], which is a RAD tool for composing demoes. This concept can be used for many other things than demoes. I want to use it for configurating [ROS]. I have been doing a mix of javascript and Ruby in order to get something usable. The empty frontend can be tried out [here]. For the backend I use WEBrick, where XMLHttpRequest's is being used for communication between backend and frontend. This project can sometimes make me really excited.

I somehow discovered that whytheluckystiff had mentioned me very positivly in [his blog]. Thanks and happy xmas.

recently I have been really busy with my study/job. Only little time for real fun (coding Ruby). From time to time I append more text to my document where I consolidate my current design, so I at some point can make a better data structure. [A New Data Structure].

The number of specs to the main structure is huge. I think I never before have had so many demands to so little piece of code.

I have (re)started at the university, studing math. I have tried in the past to study math while studing computer science.. but then all my focus is on computers. This time I want to be sure I don't loose focus. I like math.. just that programming is more interesting.

This friday I got a programming job where I am supposed to help implement an economical model for shipping companies. So 3 days for job, 2 days for school, so I am pretty busy at the moment (no remaining time for hacking). I wonder when my AEditor project drop from its 100% activity-level at rubyforge (I haven't done any commits for a long time now). Actually I went to my bank this wensday to talk about a study-loan, and I decided to think about the loan.. so it was really luckily that I got that job.. otherwise I would have been screwed.

This summer I went on a 3 week long vacation to the US, where I drow from Seattle to San Francisco. It was very interesting. I have talked with some ruby people to meet (Chad Fowler, Phil Thomsen), but I first had a chance to go online when we got to San Francisco, because we went camping.. So we never had a chance to meet. It was a nice trip.. I would really have liked to go to Oscon, but maybe next time I will have more luck with it.

When I got home I made a GUI-frontend for AEditor, that uses fxruby. Somehow I managed to add syntax coloring, and still maintain good speed (even though its written entirely in Ruby).

Last night I released version 0.8 of regexp-engine(perl5+6), which I have been on its way for a long time (4 months). I finally got fixed a very peculiar problem with nested quantifiers and backtracking. Besides that I got hit by the

premature optimization is the root of all evil
so that took a great piece of my time. Theres a testsuite (Rubicon) which exercises many aspects of Ruby, it contains 1560 tests of Ruby's native regexp engine. My initial goal has been to be compatible with 95% of these tests, which I have now exceeded. For a really long time I were only able to do 92% of the tests, and now I do 96.025% so I am very satisfied. But I guess its another example of the 80-20 rule:
The last 20 percent, takes 80 percent of the time
I like perl6 regexps, How about you?
8 Apr 2004 (updated 8 Apr 2004 at 23:26 UTC) »

Last night I got FOP working on my BSD box, it depends on Java. First I tried with diablo java, but it crashed on startup. I checked if others had experienced the same, apparently this was a known problem on the FreeBSD 5.x. Though it should work on FreeBSD 4.x.. Had I only known this on beforehand. I decided to see if I would have more luck installing jdk142. First I had to make an account at and supplying lots of info about myself. The registration took really long time. Next I had to download 3 files.

-rw-------   1 root     wheel     2513462 Apr  7 14:08
-rw-------   1 neoneye  neoneye  49269919 Apr  7 14:02
-rw-------   1 root     wheel    35829260 Apr  7 14:53 j2sdk-1_4_2_04-linux-i586.bin

About 87 mbytes. I had to add linux fs emulation to fstab, and mount it. I had to load a linux emulation kernel module.

Finally It started compiling java. Many hours compiling on my pentium 700MHz, where the machine hardly could be used because of lacking. I went to a friends place and played poker, when I got back the installation was completed. It had consumed 3.3 gbytes diskspace! Installing java can be painful.

Figured out how to add a project to advogato... I didn't noticed the creat button at the bottom of the project page until today. Maybe a small hint at the account page could help?

It seems as if I have managed to turn my sleeping pattern. Last night I went to bed at ?.. but got up at 0800! Thats a great improvement. Lets see if I can stay awake in the evening? BTW: must eat brains!

Some bugs lasts longer than others, some is hard to identify and yet others is just a pain in the ass. At one point you will be driven near madness, so that you do silly things because you think you are out of options. Admitted I have a bug (possible several bugs) which have been haunting me for too long. The amount of debug output has reached a point where it only confuses more that it helps. I have been thinking about using a multilevel logging system, but have so far rejected it. But now that I am near-crazy I consider it more that ever. It will definitly provide me with fine-graned information when I need it. I usualy just do a regexp search in the debug output. Howto tell if one has gone crazy?

Went to bed at 1000, but woke up at 1430. A total sleep of 4 and a half hour, not good. I am used to sleep roughly 7 hours and sometimes more. I feel dizzy and needs coffie, however I still feel wasted as if I had stayed awake while I should have been sleeping. Last night we switched to summer time which has displaced my sleeping-pattern by one hour in the wrong direction. I am beginning to consider when to force a transition upon myself, so normalization can occur. The temperature is 30.7 celcius inside my appartment, because its being hit by direct sunlight. Maybe the heat woke me up?

While fixing one bug you discover that another problem is also present, and when you dig into it you begin wonder how the whole program have been able to work? perhaps fixing the bug will break your program? Anyway it wasn't that severe but it got my attention. Even though it was hard to track, I added only 2 assertions to a testcase which exercises that cloning my iterator primitive works. However fixing that package, broke my regexp package. Programmers are like detectives, good at identifying what caused an action (the opposite of cause and effect). Hypotesis; programmers are better than detectives at solving puzzles?

Tonight I discovered that I have been working the whole week, under a false assumption, trying to solve a problem with nested quantifiers. No wonder it was difficult to understand what was going on, hounestly I never figuered it out. I think this could be the real reason why I recently have been visiting slashdot a thousand times and reading/writing newsgroups without solving any real problems. Damn it was hard to consolidate and identify this problem. I wrote bunches of testcases and carefully chose the input data. Is it true that humans learn from their mistakes?

2 older entries...

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!