jlm-blog
~jlm

24-May-2014

Do not use for lunch

Filed under: humor — jlm @ 10:27

Safeway advertisement

24-Apr-2014

Economics is the dismal science because people don’t think it’s a science

Filed under: econ — jlm @ 11:13

So, here I am, reading this article on the FDA proposing rules on “e-cigs”, and come across this:

Some smokers use e-cigarettes as a way to quit smoking tobacco, or to cut down. However, there’s not much scientific evidence showing e-cigarettes help smokers quit or smoke less, and it’s unclear how safe they are.

… Tobacco company executives have noted that they are eating into traditional cigarette sales, and their companies have jumped into the business.

That sure sounds like economic evidence that they help people to smoke tobacco less.

23-Apr-2014

TC on SF

Filed under: sfba — jlm @ 16:08

Do you enjoy long, complicated analyses of city policy? Here’s an excellent one on San Francisco’s distress from TechCrunch.

14-Mar-2014

The thing about sides

Filed under: politics — jlm @ 10:17

Dianne Feinstein, my senator, has been making waves as of late after discovering the CIA had been spying on her congressional staff. The waves are not so much on the merits of the charge, but due to the history of the person making them: Sen. Feinstein has until now been a vociferous booster for the US’s intelligence agencies, and their intelligence-gathering operations, both foreign and domestic. She was, for example, perhaps the Democrat most vocally in favor of granting the phone companies unqualified immunity for participation in bulk wiretapping of their customers. Had that immunity not halted the lawsuits back in 2008, part of the scope of the intelligence community’s bulk domestic spying would have come out in discovery long before Edward Snowden popped up on the radar, and perhaps the CIA, NSA, etc. would not have been so bold these last six years in exceeding their authority under the FISA.

So now Sen. Feinstein has gotten bit, and is indignant that it’s from the very snake she has been feeding and protecting. My surprise is that this is to Feinstein’s surprise! There’s an old saying — just because you’re on their side doesn’t mean they’re on your side. Seems my very honorable senator is rapidly becoming acquainted with the application of that proverb, somehow managing to get into the US Senate without having been!

28-Dec-2013

Happy Christmas from Edward Snowden

Filed under: politics — jlm @ 12:46

A holiday message from our currently most famous fugitive.

And may your new year be private.

16-Dec-2013

Good job, China. Awful job, media.

Filed under: science — jlm @ 11:34

China has pulled off the first Moon landing in 37 years and just deployed a lunar rover. Nice job!

You wouldn’t know it if you just get your news from the L.A. Times or S.F. Chronicle, though. What the hell, news media? This is not newsworthy?!

16-Nov-2013

… and also the wrong things with the wrong people

Filed under: web — jlm @ 18:21

G+ advertises user control over sharing on post complaining of G+ unauthorized oversharing

<SOURCE>

 
"That's what we call Irony!"

23-Dec-2012

Addressing the fragile base class problem

Filed under: programming — jlm @ 21:47

I’ve been thinking about the fragile base class problem lately. (Yes, I know it’s almost Christmas. My mind works mysteriously.) I started thinking by analogy to APIs, which the interface a superclass gives a subclass in fact is, even if it’s not called that. So, the superclass’s API changes, breaking the subclass, just like a regular API’s change can break a client. How do we deal with this with regular APIs? If we are to make a compatibility-breaking change (which introducing any member into a superclass potentially is), we version the API so that a client requesting version 1 semantics gets them while only clients written against the newer semantics will request version 2. We could do the same kind of thing with class inheritance if we mark everything with revision numbers, which we reference when inheriting.

class base@2 {
    void start@1();
    void stop@1();
    void idle@2();
};

class child@1 extends base@1 {
    void idle@1();
    void park@1();
};

Here’s our classic case of a fragile base class. child subclassed base and defined the new method idle(), then later base was extended with its own method idle(). Normally, this would cause a problem — the new stop() implementation might call idle() perhaps, and child’s idle() won’t be written with overriding a then-nonexistent base::idle() in mind. But with these revision markings, we say that child only overrides methods marked as being in revision 1 of base. So, when stop() calls idle(), it gets base::idle, not child::idle, and when park() calls idle(), the call resolution goes the other way.

The problem I see with this though, is that when going to an indirect superclass, it can be unclear which revision that should be.

class grandparent@3 {
    void method@2();
};

class parent@2 extends grandparent@2;

class child@1 extends parent@1 {
    void method@1();
};

Uh-oh. Should child’s method() override grandparent’s? If parent@1 extended grandparent@2, then yes. But if it extended grandparent@1, then no. So do we need to list the parent class revisions of every revision of the child class? I’d hope there’d be a better way. Perhaps we’d be relying on an IDE to handle the revision numbers for us, keeping them updated is just a dumb task, so in that case the IDE could maintain the manifest of parent revisions too.

20-Nov-2012

How not to do automatic updates

Filed under: linux — jlm @ 10:47

Today’s attempt at upgrading packages produced this:

Reading package lists... Error!
E: Encountered a section with no Package: header
E: Problem with MergeList /var/lib/apt/lists/extras.ubuntu.com_ubuntu_dists_precise_main_i18n_Translation-en
E: The package lists or status file could not be parsed or opened.

The contents of that file?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
   <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">  
   <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
   <META HTTP-EQUIV="refresh" CONTENT="0;url=https://login.wifiportal.co.nz">
   <TITLE>Welcome to FIVO Hotspot, Product of Natcom LTD NZ</TITLE>
</HEAD>
<BODY>

</BODY>
</HTML>

I don’t have unattended upgrades enabled on my Ubuntu laptop. Nevertheless, there’s something which goes around and replaces files in /var/lib/apt with whatever junk it gets from whatever network it happens to be connected to at random times. Can I be the only person who thinks this is a Really Bad Idea?

21-Sep-2012

Pre-desecrated ikons

Filed under: animals — jlm @ 12:10

A distressing report from National Geographic: Elephant poaching for ivory is growing alarmingly, devastating elephant populations, and the demand for elephant ivory is for making holy objects. I don’t understand this at all. How can anything made from the illegal killing of an African elephant for its tusks’ ivory be holy? How is that poaching for making ikons not sacrilege to Christians and Buddhists? How can the buyers worship using an ikon made from such desecration?

Powered by WordPress