HNHacker News
TopNewBestAskShowJobs

LoonyPandora

312 karma · joined April 9, 2010

London, UK / Austin, TX.

Perl guy by profession. Graphic Designer by training.

submissionscomments
LoonyPandora··on POST Tunneling: HTTP DELETE and PUT requests with JQuery and Django-Piston
Whilst a nice little article, I need to point out a factual error.

    The problem with consuming a REST API with client-side
    Javascript with AJAX is that most browsers only give
    access to two HTTP request methods - GET and POST
All modern-ish browsers as far back as Firefox 3 and IE 6 support other HTTP methods when called via JavaScript [1]. It's HTML forms where support for different methods is not present. If you have an app that relies on JS you can just use the relevant methods in your .ajax() call.

You can check what methods your browser supports here [2] (JS heavy page, may slow down your browser)

[1] http://www.mnot.net/javascript/xmlhttprequest/

[2] http://annevankesteren.nl/2007/10/http-method-support

LoonyPandora··on The Great Web Framework Shootout – On GitHub
I'm disappointed that there are no Perl frameworks at all!

I've submitted a pull request[1] to rectify this gross oversight. Even though this benchmark is not particularly scientific, it still provides some meaningful data.

[1] https://github.com/seedifferently/the-great-web-framework-sh...

LoonyPandora··on Twitter launches new GitHub page
Because it is wrong. Time is a difficult problem to solve, it doesn't move at a constant rate, the length of days and years change. You simply cannot set a constant and have it be "correct".

It may be more performant to set time ranges as constants, but you will get in to trouble unless you know exactly what you are doing. The people at Twitter who wrote the code will be aware of the trade-offs they have made, but what happens when Jo Random developer forks it on GitHub without thinking it through because "it's fast and Twitter use it - it must be good!"

For example:

    T_1_MONTH = 2592000
Not all months have 30 days.

    T_1_SOLAR_YEAR = 31558150
A solar year, is (roughly) 31556925.25218 seconds[1].

[1]http://www.wolframalpha.com/input/?i=seconds+in+a+solar+year

LoonyPandora··on London riots / UK riots: verified areas
I don't want to turn this into a rumour thread, the news sites can keep people up to date.

I just want people to keep in mind that the news will be sensationalist, and not to think that the entire city is in flames.

LoonyPandora··on London riots / UK riots: verified areas
I'm a Londoner near some of the affected areas. The sky is not falling, London is not degenerating into lawlessness, and from what I can see from my flat window, police are responding quickly.

Other areas may be different, but London is a very large city - commenters should remember that in discussions.

LoonyPandora··on Progressive Internet Explorer
There is a branch of PIE that supports text-shadow which makes it even more useful.

I used it on my site re-design because we have multiple text-shadows creating a graphical effect on our logo without images.

It works really well and performance doesn't suffer noticeably. In fact with multiple box-shadows IE8 was faster to scroll than Safari 5.0!

LoonyPandora··on Giant body of water found in space, black hole claims it was just hydrating
There is a link to the press release[1] the bottom left, next to where it says "source" - All Engadget posts have it in the same place. Seemingly it's not prominent enough, but the attribution is certainly there.

[1] http://www.nasa.gov/topics/universe/features/universe2011072...

LoonyPandora··on Facebook Launches "Facebook For Every Phone" – Java Based Mobile App
They must've soft-launched this, as I've been using it on my feature phone for at least a month.

I assumed it was just an old app that they made before smart phones dominated the market.

It's a really nice little app.

LoonyPandora··on Evolving the Node.js Brand
404 at the moment - perhaps published instead of saved as a draft?

Google Cached Version: http://webcache.googleusercontent.com/search?sourceid=chrome...

LoonyPandora··on Using bcrypt to secure passwords in Perl
Have a look at Authen::Passphrase::BlowfishCrypt [1]. it handles a lot of my suggestions automatically and is more suited to your general-case than my code is.

[1] http://search.cpan.org/~zefram/Authen-Passphrase-0.007/lib/A...

LoonyPandora··on Using bcrypt to secure passwords in Perl
I also blogged about this topic on blogs.perl.org the other week with some code examples that work a little better [1].

Your code appears to work, but is subtly broken in a few ways. Firstly since you don't return the hash in the "standard" format ("$2a", "$", two digits, "$", salt as 22 base 64 digits, '.', and 31 base 64 digits for the pass), one can't tell what work factor was used to create the hash - making it hard to verify a password. Secondly the salt isn't sufficiently random, there are modules out there that provide more randomness for cryptographic applications such as this.

It's nice to see people blogging about this kind of thing for perl, but it's important that the code is correct.

[1] http://blogs.perl.org/users/james_aitken/2011/07/safely-stor...

LoonyPandora··on Show HN: My weekend project, QR-codes for everybody
I think you need a little more instruction. What does this do?

My first thought was that it would generate a QR code for any string you provide, through url hacking. (i.e anything after the domain name is used as the string to encode) - This doesn't seem to be the case.

Very little instruction on the website, nothing on twitter, and no info here… Could you shed a little light please?

EDIT: As tiwilliam informed me, it uses the HTTP referer to create a QR code that contains a link back to that same HTTP referer. If it is not present, the default is lilqr.com.

It's a nice idea, but I don't see the value in having a QR code that links to the page you are already on? A bit more explanation is still necessary :)

LoonyPandora··on GitHub for Mac
It's a good first attempt, but it's not quite there yet and won't replace gitbox in my workflow.

The big problem is that it will only work with the origin remote [1]. This means no pulling in upstream changes, then pushing it to your fork - doing this on multiple branches with the command line is a pain, and something a GUI would be great for.

The interface feels a little half baked too, e.g why the multiple overlapping sidebars - one blue, one black, why not just merge them?

[1]http://mac.github.com/help

LoonyPandora··on Ask HN: I hate the code in my popular open source app; do I put it on my resume?
Agree with people here. Absolutely yes.

True Story: I was in the same boat. Usually people have never used it, but google for it to verify it's real - and are suitably impressed.

However, one day I interviewed at a company who had not only heard of it, but actually used it in production! I couldn't help but blurt out "Really? The code is horrible isn't it." - This turned the tide of the interview, as it showed the interviewers I had the ability to objectively review code and learn from my mistakes.

I was hired, but had to suffer being the butt of all jokes for a long time.

LoonyPandora··on Apple Inc. - Employee Purchase Program
This is for employees of other companies to buy Apple gear with the corporate discount. Like a bonus scheme, but instead of gift vouchers you get an online store.

Though when I was at Apple, the student discount was more than the staff discount.

LoonyPandora··on Nokia Pure: Nokia's New Official Font
Erik Spiekermann isn't very happy about the new typeface. He did the original, and says this one is bland [1]. Though it is, the old face was shockingly dated and needed replacing [2].

Nokia Pure is a nice readable typeface, very appropriate for use on mobile devices, elegant in it's own way - but too bland. They should've saved some money and just said "Frutiger".

At least they aren't setting their logo in it.

[1] https://twitter.com/espiekermann/status/51173410415452160

[2] http://twitpic.com/4edrh7

LoonyPandora··on Russian peasant multiplication
Schemes like this multiplication technique are fascinating, the patterns one can see are beautiful. The fact they are not taught in schools is scandalous. Their use is actively discouraged.

My Dad bought me a book about the Trachtenberg System of Basic Mathematics[1] when I was a kid, it had all sorts of funky new ways to solve maths problems just like this. My primary school hated it, they marked me down for not showing my working and doing it the wrong way. I was brilliant at maths mainly because of this book, but didn't get the extra marks for doing it the "right" way.

http://en.wikipedia.org/wiki/Trachtenberg_system

LoonyPandora··on Evil Packaging on OSX with Xcode and Metasploit
Gist of the article is that if you create an OS X installer package with a malicious postflight script, you can do naughty things.

Not new information - by design the postflight script can do anything that a regular shell script can do. If I recall correctly, this is how the fake Office 2004 "trojan" did it's work.

LoonyPandora··on Features everyone must borrow from Facebook
Make sure your product is better than your competitor's. You shouldn't be scared of a customer doing a fair comparison of your product against someone else's.
LoonyPandora··on Analyzing Xbox serial numbers
Sounds quite similar to the serial number format used on Apple products until recently. First 2 characters were the country / factory of manufacture, 3rd digit was the year, 4th and 5th were the week. The next three were the machines actual unique serial number, and the final three were a model identifier.

Seems to be pretty common to store this information in "plain text" in the serial number. I'm sure it has advantages over just giving every product a UUID and having a lookup in a database somewhere, perhaps in doing product recalls - you can specify a range of numbers that are affected?

LoonyPandora··on Bookmarklet for Reloading just CSS on a page
I've been using this one for many many years. Is your version better / more efficient in any way?

http://david.dojotoolkit.org/recss.html

LoonyPandora··on Ask HN: Any desperate things you did just to keep your startup alive?
I went on the "super noodle diet" - Which consisted of eating 2 packets of instant noodles per day, seasoned with lots of pepper to make it seem more filling. As a treat on a Sunday I had a 99p pizza too! I paid for this with the contents of my penny jar. When that had run out, I survived for another week on cornflakes with golden syrup instead of milk, which were the only things I had in my cupboard.

I lost ~30lbs in the 2 months I was doing this. In the end the startup failed, I swallowed my pride and got my old job back, the one I'd left a year previous to work full time on my startup.

LoonyPandora··on Tell HN: booking.com is looking for 40+ Perl programmers (in Amsterdam)
Working with both Ovid and Avar makes this a great opportunity to learn from two big-hitters in the perl world.
LoonyPandora··on Ubuntu 10.10 (Maverick Meerkat) Release Candidate
I'm not sure what you mean by "Helvetica-like". OS X Uses Lucida Grande as a system font, which is quite different to Helvetica (Lucida Grande == Humanist, Helvetica == Neo Grotesque)

I can't vouch for Windows, but if memory serves it's system font is also a humanist style.

LoonyPandora··on Mojolicious Web Framework in Perl
TIMTOWTDI (for the non perl guys, there is more than one way to do it - the motto of Perl)

Mojolicious is very cool, has strong leadership, direction, and is very opinionated.

I prefer Dancer, and believe it fills a slightly different niche - but the competition between both can only be a good thing.

LoonyPandora··on Google launching a Chrome OS tablet on Verizon, goes on sale November 26
Note the author of the article states in the comments:

> Hardware is pure speculation -- my source didn't have any details for me. Launch date and carrier he did have

So don't get too excited about the specs, they are plucked from the ether.

← PreviousPage 2 of 2