Archive

Archive for the ‘Uncategorized’ Category

More Etech

March 7th, 2006

Had to take a series of breaks in order to re-do news on Upcoming.org, and now that that’s done, I can return to concentrating on the stuff going on at Etech.

Some of the morning presentations were interesting, including Ray Ozzie’s bridging prototype that enabled copy and paste of structured data through autodetecting microformats and allowing suction into and annotation within the operating system’s clipboard. I’m of the mind that this will provide bountiful functionality for MS to harvest into MS Office by running a clipboard enhancer by default in conjunction with IE7. I think that in order to compete, other PIM apps would also need enhancers running in your taskbar, which seems like a gateway into more taskbar hell. Good idea, but i’m worried about the implications.

The multitouch demo was pretty awesome. I especially liked the multiple video feeds being manipulated in realtime in an unlimited desktop.

Last.fm is doing some pretty awesome stuff, and I think we got a hint into some pretty complex deduplication and validation technology and know-how that these guys have in the area of music. Imagine all the different ways for the public to title and share their music… to be able to say that you’ve got about 8 million “clean” titles is a pretty impressive accomplishment.

I’m sitting in on the playsh – the Playful Shell presentation currently and will write more as time goes on.

Uncategorized

Cal’s morning talk, continued

March 6th, 2006

I zoned out over the development process part, to work on some Upcoming stuff. Sorry about that.

Now we’re on Unicode 101. Short discussion of charset vs. encoding, a few examples of ASCII, UCS2/UTF-16, and UTF-8. “charset” in HTTP headers and meta’s is a misnomer, should be “encoding”. Rationale discussion using substr… my preferred example is in truncation of db strings. Truncating a string that’s in a different language will completely bust a non-unicode implementation. Some of the probs with MySQL are on older (3.0 and 4.0 versions), so those aren’t huge issues for us. Javascript mostly handles UTF-8 successfully, except for the escape() function, so we have to implement our own UTF-8 escape() function.

UTF-8 and email. Content type headers only apply to content blocks. Headers need inline encoding, ex: “=?utf-8?Q?…” Defined in RFC 1342. “Q” is similar to quoted-printable, B is base 664. This allows non-ASCII in the subject line.

Any junk that you receive, you assume is Latin-1 that is misidentified.

Filtering done only at the outside, possibly except for “signed data.” I don’t really understand his example here, so i’ll ask later. You never want chars below 0×20. Apart from normalized carriage returns. Carriage returns mess up XML attributes, though.

He has a Filtering PCRE sample, but there’s a mistake, and he recommends using iconv to convert from UTF-8 to UTF-8.

Discusses HTML and javascript filtering. Some common XSS hacks. Promotes lib_filter. :)

Dealing with email – receiving email is useful, very handy to support mobile blogging, support tracking. Discusses uses of pipes from /etc/aliases.

Mime in a nutshell – defines some content types, multipart mail can contain sub parts. For mail with attachments, main part is in text, rest is in binary.

Mail::mimeDecode – what Flickr mail parser is based on. Not too broken for their use, heh. application/ms-tnef – that’s MS’s winmail.dat. Only used by Outlook (transport neutral encapsulation format). A packed list of files and metadata. The spec was buried on the MS site, and is fairly easy to unpack if you know the spec. Some code somewhere may document or handle it.

Incoming email isn’t necessarily latin-1 or utf-8. Forcing a character set is kind of lame. Can find out the intended charset from email’s content-type header. Spec states they must state the content-type unless they’re latin1. Fortunately, iconv does the heavy lifting.

Wireless messages suck, because they do special casing but then also append crap at the end often. Attachments as images but text/plain mime type. Wireless carriers also append additional images which are their logo and extra spacer gifs. The worst offenders send links to images instead of actual images. Sometimes slashes are doubled up, so they break automated grabs. Try to capture weird emails and add them to a test suite, along with expected results.

The desired system is a closed test system with easily repeatable regression tests.

That completes the pre-lunch session, so we’re off to lunch.

Uncategorized

Arrived at Etech

March 6th, 2006

So I just got in to San Diego yesterday, and i’ll be here til Friday. I’ve brought along the ol’ Powerbook so I can get some Freetag hacking on in the evenings. I’m currently attending Cal’s Flickr scaling presentation, which is pretty detailed, and the audience seems to be pretty engaged.

Interesting points so far:

  • A nice, quick overview of available software load balancers.
  • Not much of a discussion so far of the dynamic structure of Flickr’s API, but some hints that the approach lies between monolithic functions and full OOP (a difficult balance to achieve).
  • Short discussion of usefulness of Layer 7 caching. Separation of hashed content in caches and ACLs would probably allieviate some of the performance issues that we regularly see on Upcoming. Luckily, we are at the point where we are starting to optimize some of our process, and so far, the one major point i’d make is to avoid left joins whenever possible.
Especially droll was this quote about mixing of Presentation and Databases: “That would be like putting HTML directly in your database and serving it directly. That would be insane.”

One nagging question I have: Where can I sample a trifle in the US, Northern California, specifically?

Tech, Uncategorized

Save House of Cosby’s!

March 3rd, 2006

Yesterday, Andy received a Cease and Desist from Bill Cosby’s lawyers that ordered him to remove a parody of Bill Cosby called “House of Cosby’s,” which was created by amateurs. As this is pretty clearly a parody of a public figure, the legal threat is tantamount to legal bullying on the behalf of Bill Cosby. Any comedian should understand that parody and satire are protected under free speech, and those who would attempt to silence that are simply hurting themselves.

To show my support, i’ve created a “Save House of Cosby’s” banner that you can grab from here and post on your website. I’m not a graphic designer, but hopefully it does make you curious. Link it to: http://www.waxy.org/archive/2006/03/03/litigati.shtml Hopefully it will help spread awareness about the stand that Andy is taking on this issue. Save House of Cosby's!

Uncategorized

The Return to del.icio.us Luky Charms

February 16th, 2006

In addition to sounding better than “MyWeb2.0 Luky Charms”, del.icio.us allows you to export your bookmarks easily. MyWeb2.0 does not.

I’d rather write off all the bookmarks i’ve created in the meantime than be tied down to a single service.

MyWeb2.0 does a few snazzy things that I liked. Saving a copy of your bookmarked pages in the cache was nice. The ability to publish links to groups of users was nice. But ultimately, it was easy to export from del.icio.us to test my own dogfood, but the realization that I could never go the other way led me to cut my losses and switch back.

Uncategorized

Powerbook died.

October 26th, 2005

Unfortunately, my powerbook died yesterday while I was looking for a place to move. I will probably send it in for repairs, but that will have to wait until after my move. Until then, I apologize if i’m very late getting back to anyone emailing or otherwise. See you from Sunnyvale!

Uncategorized

Projects Index

October 1st, 2005

I usually forget to make a projects page on my blog, so I finally got around to making it. You can get to it from the top links now. Hopefully I will be announcing two new projects that have been under active development within the next month, so keep tabs on this blog and that project page for updates. :)

Uncategorized

Life Updates

September 3rd, 2005

As of this past Friday, i’m officially fully self-employed. I’ll be spending half my time working on projects for consulting clients, and the rest of my time catching up on life and personal projects that i’ve put off for far, far too long. Even though i’m excited about the opportunities and the freedom, I still miss a lot of the people I met at my last job a great deal, and I have no regrets about the time I spent employed as a web programmer.

I typically don’t blog about any personal items on this blog, but recently i’ve been completely sideswiped by this big change in my life, combined with what’s going on in the world right now, especially in New Orleans. Recent events with Hurricane Katrina and the subsequent, predictable flooding of the city, have been heartwrenching to observe. It seems like today, Saturday, the military is finally getting people out of the Superdome.

I’ve made a donation to the Red Cross through a new service that the USC Credit Union is offering, in which you can transfer funds directly into the R.C.’s Katrina response fund. This is definitely the worst natural disaster i’ve seen in my adult life, and it’s heartbreaking to see the plight of the poor Louisianans who did not have the ability to evacuate. If you’ve been thinking about helping, I encourage you to donate directly to the Red Cross if you have the means.

Uncategorized

Traffic Court Arraignment on my bday, yay!

June 30th, 2005

So months ago, I was ticketed on Southbound Raymond street, when turning left onto California, where the gold line train was passing by. Why, you ask?

I look on my ticket, and it says “DISOBEY FLASH RED NO LEFT TURN SIGN.”

At that intersection in Pasadena, there’s a traffic control signal with a bizarre local concoction of a white left turn arrow with a red crossout circle around it, that the police officer informed me was a no left turn sign. The civic code and section I was ticketed under? CVC 22101d, which specifically states that “When official traffic control devices are placed as required in subdivisions (b) or (c), it shall be unlawful for any driver of a vehicle to disobey the directions of such official traffic control devices.”

Which sounds great – i’m happy to comply with any and all official traffic control devices. You know what, though? The California vehicle code specifically states in Section 21100.1 that “any traffic control device erected by it on or after January 1, 1981, shall conform to the uniform standards and specifications adopted by the Department of Transportation pursuant to Section 21400.” (Emphasis mine)

Wow, it sounds like there are some uniform standards, which sounds reasonable to me – legally require all traffic control devices to behave the same way, so drivers know how to behave and what to expect! But this particular sign, erected under 22101(d), violates the uniform standards in two important ways.

For that, we take a look at the aforementioned Section 21400. If we look just at CVC 21450(a), it states, “Whenever traffic is controlled by official traffic control signals showing different colored lights, or colored lighted arrows, successively, one at a time, or in combination, only the colors green, yellow, and red shall be used, except for pedestrian control signals, and those lights shall indicate and apply to drivers of vehicles and pedestrians as provided in this chapter.” Just for completeness’ sake, CVC 21450(b) states that the section becomes operative on Jan 1, 2005.

Then, if we go look at CVC 21457(a), which governs Flashing Signals, we see the following: “Flashing red (stop signal): When a red lens is illuminated with rapid intermittent flashes, a driver shall stop at a clearly marked limit line, but if none, before entering the crosswalk on the near side of the intersection, or if none, then at the point nearest the intersecting roadway when the driver has a view of approaching traffic on the intersecting roadway before entering it, and the driver may proceed subject to the rules applicable after making a stop at a stop sign.”

Aha! So I behaved correctly according to the CVC, because I was at a full stop due to a red light before I ever entered the crosswalk. The FLASHING RED NO LEFT TURN SIGN, if interpreted according to the CVC, actually is supposed to behave like a stop sign – which is actually how I entered the intersection – after a complete stop.

Basically, this sign is not an official traffic control device as required by CVC 22101(d). Even if we interpret it as a flashing red left arrow (which breaks the 3 color requirement), we can see that I followed the CVC requirements for what to do in the case of a flashing red left arrow. The officer who gave me the ticket was erroneous, and I am not guilty of the infraction I am accused of.

That is the defense that I plan on presenting at traffic court, and I believe it is a strong one, supported by photos of the intersection taken later (In fact, when I returned to the intersection, the sign was no longer a flashing sign! Sounds like somebody realized it was wrong!). I also have the accompanying sections in the CVC printed out, and I additionally have this interesting article in which Lt. Mills acknowledges that the DOT was reviewing the signal to see if there is a “less confusing configuration.”

The reason I post about it today are numerous. One, to gather my thoughts about my defense. Two, to present this information to anyone else who was ticketed in this intersection. Three, to encourage the City of Pasadena to replace these with simple solid red left arrow lights that conform with the CVC uniform standards. Fourth, to complain about constructively criticize the lasuperiorcourt.org Court Date scheduling system.

First of all, if the scheduling system cannot find any possible dates for your preference, that’s it. It’s an un-back-up-able pop-up window, and there’s no back button. You’ve got to completely start over and try again.

Second, if you find a date, but you don’t think it will work, you have to hit cancel. But if you hit cancel, it bumps you out again, instead of looking for another perference.

Third, the telephone registration system is not much better – it suffers from the same problems, and even worse than leaving you hanging, it actually hangs up on you if it can’t find you any dates. Forget about the 5 minutes you spent answering the mind-numbingly redundant text prompts listing the name and address of each location surrounded by perfectly pronounced drivel speech (I reconize the need for clear enunciation, especially for non-native English speakers). So even though the web system is flawed, it’s still better than wasting spending your time on the phone system.

Fourth, and most egregious, the only available court date was at 8:30 AM on my birthday. I have a hard, hard time, after all i’ve been through, believing that this was not somehow calculated from the birthday that I entered when I began filling out the form, in a subversive attempt to evilly discourage me from appearing at court. But I understand that the world isn’t all about me, so I accept it with a sigh. At least it’s only where I plead, and not where I present this case.

What else do you expect from a government that manages its programmers with lines-of-code quotas?

Update: I regret a lot of the upset comments that I originally wrote here. During my actual appearance at trial, the ticket was dismissed primarily for reasons other than my argument outlined above – what I can say is that the court system did treat me fairly; although I understand how upset I was originally at this charge, and the unfortunate scheduling of arraignment and court date, the system did end up working in my favor in this case, and it helped a great deal to look at the issue objectively and without emotion. The emotion that did seep into my handling of the case (that I wrote into this original post) did not help at all with the law.

Another Update!: I went to court and presented the argument that I built, and the traffic ticket was dismissed eventually! See more details here.

Uncategorized

Idiot PHP Reminder of the Day

May 3rd, 2005

Don’t use require_once within functions. Especially when you iterate multiple times over that function. Use require or include instead, because the successive calls won’t import the additional code any more.

Uncategorized