Posts

  • Mutation testing

    Now that we’re done yak shaving, we can start talking about mutation testing. As an engineer at Google, I often use the Go programming language (which I really enjoy), so that is my choice for these examples; however, mutation testing is available for other languages.

  • The ioutil yakshave

    I’ve been planning to write a blog post about Mutation Testing, and finally got around to it a couple of weeks ago. I set up my example, and looked to some publicly-available mutation testing tools for my programming language of choice, Go (I get to use it quite often as an engineer in Google). The best-maintained one appears to be go-mutesting, so I figured I’ll try it out. Unfortunately, I ran into a build issue with one of its depdencies:

  • The Matzliah method

    My native language, Hebrew, has a useful term - the “Matzliah” method. It’s documented in a hebrew wikipedia entry, but my translation can’t make it past the draft stage. I’ll add my translation here for posterity:

  • תקלה ב-TransportDroidIL

    This post is written in Hebrew due to the target audience. TL;DR - TransportDroidIL can no longer function.
  • Seaplane - Github with a non-programmer

    The Faculty Programmer

  • Git While You Sit 3 - "Rename" edge cases

    This is part of the “Git While You Sit” series, a play on Google’s Testing on the Toilet. It’s intended to fit on a printed page. Currently Chrome doesn’t seem to correctly print columns, but Firefox does.

  • Git While You Sit 2 - .gitignore

    This is part of the “Git While You Sit” series, a play on Google’s Testing on the Toilet. It’s intended to fit on a printed page. Currently Chrome doesn’t seem to correctly print columns, but Firefox does.

  • Git While You Sit 1 - Add --patch

    This is part of the “Git While You Sit” series, a play on Google’s Testing on the Toilet. It’s intended to fit on a printed page. Currently Chrome doesn’t seem to correctly print columns, but Firefox does.

  • Lessons learned

    After 6 years with my previous employer, as a DevOps engineer and DevOps team leader, I’ve learned two important lessons. I wanted to get these in here before I start my new position (…as an SRE in Google Dublin, which I am very excited about!), as it’s always fun to look back after a few years and see if what I wrote is still relevant.

  • FakeFile

    I’ve recently been rewriting a mess of bash, tcsh and Python code as a Python script, and this has proven interesting to test. I’ve written a tiny Python library called fakefile to help out with it, so I can write code like this:

  • Fun with file descriptor leaks

    Here’s a fun little bash script:

  • Social network spoiler prevention

    There is a well-known problem on today’s social network platforms - spoilers. Anyone watching a show and failing to immediately catch up to the latest episode will see a lot of posts on their feed dancing around the spoiler, and finally revealing it completely. This makes sense - people like to talk about their favorite shows, and social networks are a great place to do it.

  • Investigate

    My show downloading stack lives on. I’m curious as to which will happen first: NetFlix hits Israel, or I switch over to Sick Beard.

  • Startup times

    Lately, a facebook comment of mine on the subject of Java’s slowness has proved quite popular, so here goes: Here’s a listing of a few Hello World programs and running times for them (including startup, which is a big deal in Java) on my laptop:

  • Asserting string equality

    I’ve had several opportunities to write unit tests for code that outputs large strings. It’s important that your unit-testing framework handles this well.

  • Test-driven procrastination

    A conversation with a friend reminded me that, in fact, I’ve been doing test-driven development long before I knew it was called that. Back in Introduction to Systems Programming (a second-semester course revolving around abstract data types in C, introduction to C++, and hands-on experience building multi-module C programs), most homework exercises looked something along these lines: Write a program managing a store inventory, with a command-line client conforming to a given set of specifications. For an input file looking like this:

  • Multiple library versions

    Introduction

  • Reading, writing and vacations

    Vacations are a great time for doing that problematic category of things every management course teaches you about: important, but not urgent. For some people, it’s housework or schoolwork which gets drowned out by day-to-day life. For others it’s keeping up with friends and family. Myself, I also like to read and write.

  • Translationese

    As part of my M.Sc. studies, I’ve recently completed a small laboratory project in natural language processing. I’ve learned quite a bit from it, and had a chance to use a few of my favorite technologies.

  • The show downloading stack - part n+1

    I’ve already mentioned my show downloading stack on this blog. It’s changed a bit since - I now use Transmission rather than rtorrent, as it has the excellent transmission-daemon package which has it acting exactly the way I like (without using screen). Also, it now E-mails me when a torrent is done downloading. So while this may be how TV works for you:

  • Developing TransportDroidIL for Android

    Here are a few words on developing TransportDroidIL, a small utility to query Israeli public transportation sites more easily using an Android phone.

  • Home network wiring

    I don’t like wireless connections; they’re always second-best, be it in terms of security, speed, or reliability. Here’s how my apartment looks (very approximately):

  • Upcoming features in TransportDroidIL

    Hello everyone, TransportDroidIL 1.0 will be released this month. It has quite a few new features:

  • SMS and why it annoys me

    Don’t get me wrong. I love being able to communicate textually with friends, coworkers and family. It’s ideal for a noisy pub; a somewhat-private conversation on a crowded bus; telling something to someone who may be asleep, so they see it first thing when they wake up; making quick responses while in a meeting without being rude (well, at least at my workplace it’s considered perfectly acceptable). It’s also very handy when you want to tell someone something they ought to write down, such as a phone number or something they should remember to buy. My problem isn’t with the concept of mobile textual messaging - it’s with SMS, the “Short Message Service”, as provided by Israeli carriers (and possibly worldwide).

  • DD-WRT awesomeness

    Since I’ve last posted, I’ve moved to a new apartment. First order of business

    • get a working internet connection. This is extra-challenging when your primary machine doesn’t even have a wireless network card.
  • Transport Droid IL

    After a couple of days’ messing with it, I’m releasing it: Transport Droid IL! It’s a handy little app for querying Egged’s site, as well as the new Ministry of Transportation site, on transportation information. This is pretty beta, but seems to work well enough.

  • Setting up Hebrew Android fonts on your AVD emulator

    There are several good guides for installing Gilad Ben-Yossef’s excellent Hebdroid fonts on physical Android devices, but those don’t really work with the Android SDK’s emulator - changes to the system directory aren’t persistent. Here’s how to get around that:

  • Android

    I’ve recently “bought” a Samsung Galaxy Android phone (the older i7500, not the newer i9000 “S”) model. It’s a seriously serious upgrade from my old Nokia 6120 Classic, and as I broke the 6120’s screen and reverted back to my trusty old Nokia 6070 (which I couldn’t even get to run the GMail app), I was quite a happy camper switching to a modern phone.

  • My music player has sunk

    My Meizu Mini M6 has died a tragic death as a result of being left in my shirt pocket, which in turn was - with the rest of my shirt - in the laundry. I’ve had it for three years, so this would be a good time to review.

  • Broken phone screen - data rescue

    Last weekend I broke my Nokia 6120’s screen. I have a military phone, which is far cheaper, so I’ve decided to keep it offline. However, being the sentimental guy that I am, I did want to save all of my contacts and SMS messages (in addition to the photos, which presented less of a problem). This proved to be a bit of a challenge without the screen working.

  • Loving the new Totem

    Totem is Gnome’s built-in media player, and it really annoyed me in previous versions, and had me switching to VLC. However, the version included in the Ubuntu 9.10 release candidate has two features which are very important, in my opinion. The first feature is smooth graphical integration with compositing managers (such as compiz). In previous versions, as well as VLC, once you fullscreen the window, moving the mouse (which causes the cursor and the partial interface to appear) causes a very annoying flicker. This has been fixed (at least on my box, using an NVidia card).

  • My show downloading stack

    I love watching TV, and hate it. Regular show schedules are horrible, commercial breaks are annoying, and the ability to rewind is very important. I love Hot’s VOD service (and happily pay to watch the shows I enjoy), but my true favorite for getting my entertainment is everyone’s favorite not-a-dumptruck, the internet. In this post, I will describe how I do it.

  • Timezones are fickle

    I’ve been trying to work out a system to be able to cleanly switch between IST (Israel Standard Time, GMT+2:00) and IDT (Israel Daylight savings Time, GMT+3:00) on command. The logical way to do this, in my opinion, is to have two separate files in /usr/share/zoneinfo, say IsraelIST and IsraelIDT, and copy (or link) the relevant one as /etc/localtime. The trick is creating the IsraelIDT file.

  • Using git for code review

    At my workplace, I’ve recently been using git for code review purposes. I work on code in my own git clone, and ask a peer to review it. It works somewhat like this:

  • Hardware doesn't like me

    I’m a software kind of guy. Here’s proof.

  • Whatever happened to black & white LCDs?

    I had a Game Boy once. I could play it just about anywhere, and battery life - for the time - was great. I lost it at one point, and replaced it with a Game Gear, which sucked the life out of 6 AA batteries rather quickly. The Game Boy Color was actually decent on battery life, but since it didn’t have a backlight, you had to play it at very specific angles.

  • Another SSH trick

    Ever have a machine you can only ssh into through another machine? It’s a very common situation in the Technion. Here’s one way to get around it: Assume you can directly ssh into alpha, and from alpha you can ssh into beta. Have the following code in your ~/.ssh/config:

  • Automatically starting rtorrent within screen

    These days I don’t stay at home often, but I do have an RSS/BitTorrent combo fetching me all kinds of neat stuff for me, so I can have it ready for me on the weekend. I love rtorrent, especially due to the fact that I can run it in screen, ssh home and see how things are doing (or add more torrent to the download). However, sometimes my net connection breaks down, computers gets shut off, or things like that. This week my router broke down, so I can’t even ssh home to manually start up rtorrent. My solution: A small script, which checks whether rtorrent is already running, and if not - runs it in a detached screen session. Run this with your favorite cron software.

  • Quick time tracking hack

    Gnome 2.24 adds a new Time Tracking feature, which I would have found useful. I don’t have Gnome 2.24 at work, but I do have a Unix-based operating system… Here’s my new ~/bin/track:

  • Delegating methods in Ruby

    Sometimes, when constructing a compound object, we are interested in exporting functionality while retaining encapsulation. For example, suppose we have a Secretary class:

  • Tracking TTime

    Ditz was lost in the mists of time, and I guess if ttime were maintained, issues would be tracked using Github.

  • Three things I didn't know Ruby does

    Edit: I was misled!

  • Security project

    This site gets indexed by the almighty google. This link is part of a security project I’m doing for my CS degree.

  • Gettext oddities with Ruby

    I was having a lot of trouble with gettext in Ruby, mostly due to lacking documentation. Here are some useful things I figured out while writing TTime. I ended up having a single gettext_settings.rb, included from every file which uses gettext. Here it is (with some extra notes)

  • That "Life" category there

    I has it. Sorta.

  • Been working on TTime

    I’ve found myself working on TTime, the Technion Timetable Scheduler, quite a bit lately. Lots of cool stuff went in:

  • Tunelling even more stuff over SSH

    Today at the CS department of the Technion is a particularily Bad Network Day (TM) for laptop users; none of the wired connections at the farm work, and wireless doesn’t seem to working for HTTP at all.

  • Valgrind Fail

    I neglected to post this here somehow, it’s about a month old by now…

  • Scheduling

    So, I see I forgot to post my schedule for this semester…

  • Things I learned today

    1. You can use git on a VFAT disk (for example, a USB key) without all of the annoying mode issues, by using the following setting in .git/config:
  • Deskbar and Firefox 3

    Deskbar has a really neat plugin which allows you to search your browsing history and bookmarks. Firefox 3 has switched the storage format to an sqlite-based one. I’ve been working on a new plugin to make use of that - so far it’s very enjoyable to use :)

  • Hebrew spell-checking in Pidgin

    This one took me a while to figure out, which is reason enough to post it here.

  • Faster Languages

    Due to an exercise in an AI course, I’m forced to confront an old nemesis - C++. Part of the reason is that the exercise contains a time-limited tournament, and the code needs to run very quickly. Another reason is, I guess, the fact that C++ serves as a sort of lowest common denominator in the course (which used, by the way, to be taught in LISP, along with the language).

  • My alarm clock

    YNet was running a story on how to use your computer as an alarm clock. Here’s what I do, for our commandline junkies :)

  • Nokia 6120 Classic

    I’ve switched to a Nokia 6120 Classic, and I’ve switched my carrier over to Orange. I’m very happy with it: The price is right, at 0 NIS a month (if your monthly bill adds up to over 100 NIS without it, which it does). It’s very small, but has a nice screen and a respectable 2 megapixel camera. It’s “3.5G”, which means it has a very fast internet connection (I’ve clocked over 50kbyte/sec), and the Symbian S60 operating system lets me use it well - it comes with a very, very nice webkit-based browser and RSS reader, and a fast GMail client is a few clicks away.

  • Egged Getter 0.1

    The Egged Getter has been lost in the mists of time. However, it’s code has largely been integrated into TransportDroidIL. An old version of the Python code has been pasted at the end of this post.

  • Sour chewing gum

    On an online board, friends posted a photo from a party a while back, as I’m chewing some extra-sour chewing gum:

  • Means of control

    New URL - not interesting. You’d notice by now, as you’ve been redirected. Guess my new E-mail. OpenID - interesting, but I don’t have anything particularily interesting to say about it right now.

  • Vacation

    The most recent events in my life which I would consider to be vacations would be the second Lebanon war and my basic training. I love the Technion, but I think it’s high time for some R&R. With no upcoming tests hovering over my head, homework pressure low-to-nonexistent, and my girlfriend’s birthday Murphy’s-law-bendingly coinciding with her getting some leave, this is a perfect opportunity to try my hand at a real vacation.

  • Computability - Typed Lectures and Tutorials

    All links in this post have been lost to the mists of time. I’ve kept it here out of pure nostalgia.

  • Encrypted my Wi-fi

    Reading some backlog on this blog, I found the following gem:

  • On Threading vs. Processing

    Writing multi-threaded applications in Python is often a headache because of the Global Interpreter Lock - only one Python thread can run at any given moment, which makes multi-threading useful only in the case where all modules but one actually run C code. However, thanks to the impressive new Python Magazine, I’ve stumbled across a package called processing, paraphrasing python’s built-in threading package. Essentially, the package provides an API identical to Python’s threading, but uses processes and pipes (or other mechanisms on non-posix operating systems) instead. What the magazine does not cover is the fact that this can also benefit GUI applications; updating a progressbar in the application doesn’t need to slow down heavy computations being done in a separate thread. To show how easy the integration is, take the following example which shows usage of either threads or processes at the user’s choice:

  • Tough Question

    My girlfriend just asked me what just might be the hardest question I’ve heard all semester; What do I like better, The Simpsons or beer?

  • Really liking this git thing

    I’ve been a very big proponent of Subversion so far, especially as a tool for collaborating on coding homework. However, I’ve recently been trying out Linus’s git. It’s very nice so far, and really seems to be catching on. Some good points:

  • Exception handling, decorators, and python

    Lately I’ve been working on a project that has me using DBus a lot. After trying to figure out how to work DBus with C, and seeing how easy it is to do in Python, we figured we’d try to use embedded Python to do this. Fortunately, it’s very simple to use - especially thanks to this guide.

  • Two reasons Apple suck

    First of all, new iPods won’t work on Linux. Now, while it’s very obvious that the idea is to block competition against other music vendors, that makes it even less legitimate. Good thing we’re starting to see some very nice cheap players out there - I’ve been rather impressed with the Meizu M6 MiniPlayer.

  • NaNuchKa

    Despite having a critical midterm Sunday, as well as being sick, I could not, and should not have, give up on the NaNuchKa show. Some of the best music I’ve ever heard, no doubt, and with the unexpectedly intimate setting, I had the opportunity to get to know the truly incredible Yula after the show. They’re playing in Tel-Aviv today, at the Koltura, where I was supposed to… Fantastic music, at any rate. Keep your ears open!

  • Some things make you feel good

    Some things renew your faith in people, in the time you spend with them. Amazingly small things, considering their grand scope. Making things worse is known to be easy, and rebuilding is one of the hardest things we have to do in life. But sometimes, when things turn out to be completely different than they seem - new perspective is gained, old perspective is found again, and like something out of an old Disney cartoon, kitschy clouds of gloom make way for kitschy rays of sunshine. Complete with the smiling sun and everything. Like freakin’ Roger Rabbit :)

  • All hail the cow!

    Paradox the cow

  • Some music posted to myspace

    Recording this morning was excellent! Awesome studio, not expensive at all, and a whole lot of fun. We’ve posted one song at our myspace page, and it seems that Lior has found an apt name for the CD (hint) ;)

  • Some band stuff

    This Saturday we’re going to record our material, and hopefully a cover we’ve been working on - Venom’s excellent “School Daze”. We took some photos yesterday, visible here: http://www.myspace.com/switchblade777/photos/albums/my-photos/8265381

    1. Link modified to accomodate mists of time. 

  • Myspace sucks

    Life is good, for the most part. And as a technology enthusiast, there are many new and cool things to see online. For example, there’s the new Schools site, part of the Vaya project which helps Israeli schools use Linux; this site uses the up-and-coming Lahak CMS, built on the Django framework, and looks very promising to the eyes of the bidi-lingual webmaster.

  • On the matter of a really long vacation

    By now I’ve lost count of how long ago my last class was. The strike has begun immediately after passover, and is certainly beginning to take its toll. For one thing, I have no homework deadlines - a rare situation indeed for the Technion student. Furthermore, contemplations are rising about whether or not this coming summer semester will be held, as the current semester will most likely leak into it. This is of special interest to me, as I’m behind on my degree, which is problematic because of my military scholarship. This is shaping up to be the second time in which, while I’ve been authorized by the military to take a summer semester for completion, I am not able to. However, one cannot trivially dismiss this strike; in a country which is known worldwide mostly for its technological exports and frequent bloodbaths, one shouldn’t take the matter of tuition lightly.

  • Grub menu.lst editor

    A lot of people ask me how to change the default operating system booted after installing Linux. The answer they get in Ubuntu’s case, “Edit /boot/grub/menu.lst, it’s self-explanatory”, is often unsatisfactory. Attached is the solution :)

  • Yasmin back up

    Why was it down, you ask? Well, it was out here in the lab, because of a shortage of network ports in the server room. From the acpid log:

  • IPython

    The more I use Python, the nicer it becomes. I’m currently working on a project for a course, which involves somewhat heavy-duty database and algorithm work. Python is my language of choice for it - let’s hope it works out well.

  • Using Jabber from within the Technion

    A very neat find for those of you who want to use Jabber from within the Technion, but with your client of choice rather than a web-based one: Many Jabber servers, including Google Talk, support using Port 443 over SSL. Since the Technion does not block outbound SSL connections, this will work there as well. Be sure to mark the appropriate ‘Use old SSL protocol’ option in your jabber client (that’s what it’s called in gaim and pidgin, at any rate).

  • Before reinstalling your server for RAID

    Check that the RAID it supports is actual Raid. My experience today:

  • Bass guitar

    I brought my Fender Squier Jazz Bass up to my Technion apartment. I hope it won’t have too much of an adverse effect on my studying… playing it (loud) is great for stress, and I’m taking a jazz improvisation course next semester.

  • Really liking the whole Python thing

    I’ve converted my Antigibberish script1 (converts “broken hebrew” into proper hebrew, useful for sent-offline ICQ messages) to Python… it’s quite a nice language, and the interpreter is FAST! I’m really torn between it and Ruby :(

    1. Used to have a copy of antigibberish.py, but it’s been lost in 

  • Here's hoping

    ```ruby def factor(grade, params = {}) return 100 if params.empty? # Optimistic, eh?

  • Internet in Haifa Bay Central

    In the Haifa Bay Central bus station (מרכזית המפרץ), it’s possible to get an internet connection. HTTPS works automatically, and setting the proxy to proxy.technion.ac.il:8080 works for HTTP. I was unsuccessful in using corkscrew to get SSH connections to tunnel over it as well, but perhaps there is still a way.

  • Beautiful ideas

    This man has some beautiful design ideas for the Linux desktop.

  • Why Vista worries me

    I’ve heard the latest Security Now, regarding the debate between Dave Marsh and Peter Guttman on DRM in Windows Vista. While a few good points were made, the major one - in my opinion - was not.

  • I know where waldo is

    Well, penny knows. But I have proof she knows…

  • On Vista

    Everyone knew this was going to be an interesting one to watch. Die-hard Microsoft fans were sure Vista would be the final nail in the Open Source coffin, die-hard Linux fans were sure that the release would be Microsoft’s demise. Myself - I’m sitting and enjoying the show.

  • Courtney Love on Piracy

    This is absolutely antique (2000), but it’s good to hear an artist with a clue.

  • Pmount-hal + cd

    If you’re like me, and don’t use Gnome or KDE, then you probably use the pmount or pmount-hal applications to mount removable media. Here’s a neat thing to add to your .bash_aliases:

  • I do NOT kick puppies!

    I do type mesmerizingly fast, though… :)

  • I might need these tomorrow...

    My lecture slides. Have a peek if you like :)

  • Samurai Jack - Ingenious!

    When approaching a port, the Scotsman:

  • Waiting for the bus

    I’m going home for the weekend, as usual. Unfortunately, the first bus of my route comes by at highly unpredictable times - I’ve had it be an hour late on me once. There are plenty of Wi-fi networks around the station - either WPA, WEP or MAC-whitelisted… fortunately, someone was using the latter long enough for me to catch him with Kismet. Thank you, stranger! :)

  • 3D effects for coders?

    My new work desktop has a GeForce 4 MX, so I naturally installed Beryl on it. The graphics card has relatively little RAM, so it finds handling my 1280x1024 resolution difficult when additional texture memory is needed - so using something like Firefox really slows it down when Beryl is activated, making me keep it off most of the time. However, for coding, I’m finding that Beryl is very useful - it actually helps me that the code windows are transparent, so that I can see what’s underneath them, and the “Expose” effect still leaves text legible, which is great for reading off a lot of terminals at once. So is Beryl… a programmer’s tool?

  • Software Perfection - Lost in the details

    Sometimes imperfections in Software drive me nuts. It’s what drove me away from Windows. It’s what keeps me switching back and forth between desktop environments. It’s what has me wasting a lot of time getting the software to do what I want, instead of getting anything done. I even have two particularily good examples.

  • Alright, American Dad!

    Just finished downloading an episode of American Dad off Bittorrent. TV has ancient episodes of Family Guy. Took about an hour though… I tells ya, I’d pay for this kind of service if it were faster… ;)

  • As for Python

    Myself, I’m a Ruby hacker. I send everyone within earshot to TryRuby, code my sites using Rails, am surprised that I’m using a php-based blog… you get the picture. Ruby is sometimes called the Japanese Python, and comparisons are inevitable. I know very little about Python, but I do know that…

subscribe via RSS