May 2007
Monthly Archive
Thu 31 May 2007
Posted by brian under
Helio ,
Rants[33] Comments
Even though they strung me along for nearly six months I was willing to forgive and forget since they were willing to give me a refund; in the last couple weeks I got a voicemail from William who told me that he was seeking authorization from me to put the money back on my credit card, and if not he’d send out a check. I called back to see what was up with that, and I was told by Tuscekia that I would not be receiving a refund because the phone was received late and because it was in poor condition. WTF!? I thought that late phone thing was a dead horse and we’d cleared it out after being told several times that it was not a problem. And what’s this about poor condition - I’d never been told that before.
So I dug a little deeper, and asked for the supervisor, who was Josh. Josh told me that he was sorry, but there was nothing he could do. He explained that the Fulfillment Center determines the condition and arrival date of returned merchandise and that it was they who declared it late and in poor condition. He further explained that they do this as soon as the phone arrives, which by my count is December 13 but by their reckoning is March 17. “So”, I asked, “if the phone’s condition was marked in your system since March 17th then why has everyone I’ve talked to since then said nothing about the phone’s condition being an issue and that I should eventually receive a refund?” All he had to say for himself was that he was sorry for the misinformation, but there was nothing he could do. I told him that I returned the phone in perfect condition, and even mentioned that I left the little plastic thing that covered the screen so it wouldn’t get scratched - and of that I have proof. He suggested I follow up with FedEx since, by assuming that both Helio and me are right, FedEx - the only other party involved - must be wrong.
So I asked FedEx.com for the information about the shipment, and was told again that it was received on December 13th. Not only that, but they let me download the proof of delivery in PDF complete with the name and signature of the person who accepted the package! FedEx++, what a refreshingly well-run business compared to Helio. I didn’t even have to talk to anyone or spend more than two minutes and I had all the information I wanted, save for some advice on how to deal with Helio.
What now? Well Josh suggested that I call them back if I got the information from FedEx, so that’s what I’ll do. If they still refuse then I’m just glad that the internet and law suits exist for venting and financial recourse, respectively.
UPDATE: I called back and got Bern, who was helpful and sympathetic. He spoke with a 2nd tier rep, keeping me on hold for the most part. He said that he recognized that I was in the right and that he would work the the other rep to get my refund approved, but that it’d need 3rd tier approval before it’d be signed off on (whatever that means). He then said the words I’ve come to know well: “It’ll take a few weeks to process, not to exceed 59 days.” Yeah, well.. no offense, but we’re at 170 days here, and tacking on yet another 59 days puts it up to 229, or about seven and a half months. Not to mention that a the “not to exceed 59 days” has not meant shit so far, and I somehow doubt it will in the future either.
I don’t doubt that some of the individual customer service reps I’ve spoken to do want to help, but I’m beginning to feel like Helio has a corporate policy of stalling refunds for as long as possible in hopes that the customer will just give up.
Sat 12 May 2007
Posted by brian under
Ruby[2] Comments
I started reading Giles Bowkett’s blog a little while ago. He has a lot of rants, and it’s fun. I would have commented on his blog but it seems to be restricted. In a recent article he criticized someone for their custom dynamic finder, attacking them on a number of fronts: SQL performance, architecture design, and readability. But he forgot to check his code in irb, claiming that:
#merge() is a Hash method. It adds new keys to an existing hash based on another existing hash. Unfortunately, it does so destructively. If you have two values defined for the :conditions key in two distinct hashes and you merge them, only one :conditions value will survive the harrowing ordeal. #merge() is Darwinian - it’s survival of the fittest in there.
Amusing, but wrong:
>> h={:conditions => "true"}
=> {:conditions=>"true"}
>> g=h.merge(:conditions => "false", ‘order’ => ‘email desc’)
=> {:conditions=>"false", ‘order’=>"email desc"}
>> h
=> {:conditions=>"true"}
>> g
=> {:conditions=>"false", ‘order’=>"email desc"}
You were thinking of update and merge!. Also, he quotes Assaf as saying:
`*opts` is a bug, lacking an understanding of how Ruby handles arguments. `*opts` refers to all other arguments you pass, the vararg equivalent. But when you call `find_by_email(”…”, :limit=>5, ‘order’=>”name”)` the last two “arguments” (limit and order) are actually keys in a hash that’s passed as a single argument. So anything you pass to find_by_email, the original, that falls inside *opts, would be passed to find after the last argument it expects (the hash of options), which should, if implemented correctly, cause find to fail with an error.
That’s correct up to the last sentence. Let’s look at the code in question:
class User < ActiveRecord::Base
def self.find_by_email(email, *opts)
with_scope(:find => { :conditions => [‘lower(email) = lower(?)‘, email] }) do
find(:first, *opts)
end
end
end
This will work. There’s nothing wrong with using the splat operator here other than the fact that it’s going to make this method slower than it out to be. Here’s a better implementation:
class User < ActiveRecord::Base
def self.find_by_email(email, options={})
with_scope(:find => { :conditions => [‘lower(email) = lower(?)‘, email] }) do
find(:first, options)
end
end
end
C’mon Giles, you’re better than this.
Mon 7 May 2007
Posted by brian under
Ruby[17] Comments
Figuring out what’s wrong in Ruby can be a pain. That dynamic typing that you find so nice while writing code can sometimes work against you when reading it — and troubleshooting it. What most of us end up resorting to is basically one step up from how most JS debugging happens: puts.
While this is annoying, it doesn’t have to be this way. Ruby comes with a debugger, but it is slow on non-trivial applications. The best alternative is a gem called Ruby Debug, which is fast and has a bunch of goodies. I come from the GUI-debugging world of VS.NET and IDEA, so getting into Ruby Debug was a little bit of a challenge for me at first. If you come from the gdb world you should feel right at home.
Watch the Ruby Debug Basics screencast
from the screencast: fib.rb
def fib(n)
@fib_cache ||= [1, 1]
@fib_cache[n] ||= fib(n-1) + fib(n-2)
end
puts fib(20)
Next screencast will cover debugging a Rails application.
Sun 6 May 2007
Posted by brian under
GeneralNo Comments
So I hopped on the Tumblr bandwagon a while ago, but I didn’t tell anyone. I was waiting to see whether I’d be able to fit this particular bandwagon into my workflow, and I think I have. I’ll start posting short stuff I find interesting or amusing on my tumblelog, and continue using this blog for my own writing.
Wed 2 May 2007
Posted by brian under
GeneralNo Comments
Someone cracked HD-DVD, finding the particular hex key used to defeat the encryption. When the key was posted on Digg they took it down — presumably in response to a lawsuit or a cease and desist from the MPAA. In response Digg’s users posted tons of stories all linking to or containing the key (more).
While I fully believe that content owners should be able to make money from their content, I think that the steps they’ve taken to restrict the use of the content is absurd. Very recently a subset of the music on the iTunes Store was made available at higher quality and without DRM. That’s a huge step forward, in my opinion.
To the RIAA/MPAA: People don’t want to be pirates, they want convenience — and DRM is not convenient. Yes, you will lose some sales to piracy, but your real customers will appreciate not being treated as criminals.
Oh, and here’s the key: 09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0. If you’d like to protest the MPAA’s stupidity in trying to control this key and show your support for Digg, who is now going to fight it, I suggest you put the code somewhere. Let’s make it ubiquitous! I’m using it as my AIM status message.