meyerweb.com

Skip to: site navigation/presentation
Skip to: Thoughts From Eric

Archive: 'Questions' Category

Transiently Damaged PDF Attachments

I have this very odd problem that seems to be some combination of PDF, Acrobat, Outlook, Thunderbird, and maybe even IMAP and GMail.  I know, right?

The problem is that certain PDFs sent to me by a single individual won’t open at first.  I’ll get one as an email attachment.  I drag the attachment to a folder in my (Snow Leopard) Finder and double-click it to open.  The error dialog I immediately get from Acrobat Professional is:

There was an error opening this document. The file is damaged and could not be repaired.

Preview, on the other hand, tells me:

The file “[redacted]” could not be opened.  It may be damaged or use a file format that Preview doesn’t recognize.

When this happens, I tell the person who sent me the file that The Problem has happened again.  She sends me the exact same file as an attachment.  Literally, she just takes the same file she sent before and drags it onto the new message to send to me again.

And this re-sent file opens without incident.  Every time.  Furthermore, extra re-sends open without incident.  I recently had her send me the same initially damaged file five times, some attached to replies and others to brand-new messages.  All of them opened flawlessly.  The initially damaged file remained damaged.

Furthermore, if I go through the GMail web interface, I can view the initial attached PDF (the one my OS X applications say is damaged) through the GMail UI without trouble.  If I download that attachment to my hard drive, it similarly opens in Acrobat (and Preview) without trouble.

A major indication of damage: that first download is a different size than all the others.  In the most recent instance, the damaged file is 680,302 bytes.  The undamaged files are all 689,188 bytes.  If only I knew why it’s damaged the first time, and not all the others!

So far, I’ve yet to see this happen with PDFs from anyone else, but then I receive very few attached PDFs from people other than this one (our events manager at An Event Apart, who sends and receives PDFs and Office documents like they’re conversational speech—an occupational hazard of her line of work), and it only seems to happen with PDFs of image scans that she’s created.  Other types of PDFs, whether she generated them or not, seem to come through fine; ditto for other file types, like Word documents.  I’d be tempted to blame the scanning software, but again: the exact same file is damaged the first time, and fine on every subsequent re-attachment.

I’ve done some Googling, and found scattered advice on ways clear up corrupted-PDF-attachment problems in Thunderbird.  I’ve followed these pieces of advice, and nothing has helped.  In summary, I have so far:

  1. Set mail.server.default.fetch_by_chunks to false.
  2. Set mail.imap.mime_parts_on_demand to false.
  3. Set mail.server.default.mime_parts_on_demand to false.
  4. Tried the Thunderbird extension OPENATTACHMENTBYEXTENSION.  That failed, and so I immediately uninstalled it because handling files by extension alone is just asking to be pwned, regardless of your operating system or personal level of datanoia.  (I wouldn’t have left it installed had it worked; I just wanted to see if it did work as a data point.)

Here’s what I know about the various systems in play here:

  • I’m using Thunderbird 11.0.1 on OS X 10.6.8.
  • The attachments are always sent via Outlook 2010 on Windows 7.
  • The software used for the scanning is the HP scanning software that was installed with the scanner.  Scans are saved to the hard drive, renamed, and then manually attached to the email.  On resend, the same file is manually attached to the email.
  • My email account is a GMail IMAP account.

So.  Any ideas?

Degree of Influence

A brief followup to “A Question of Degree“:  I received the following message from the person who first asked the question:

I just spent the last hour or so reading through the comments and, let me tell you, I can’t express how much they helped me! It is now clearly obvious to me that finishing my CS degree is the way to go. A CS degree can make me a better web developer by teaching me about algorithm design and analysis, performance issues, and just how to think like an engineer. Also, since the web changes constantly, a degree will help me embrace those changes. It will always be there for me to fall back on if the web industry doesn’t work out for me.

Thank you to everyone who contributed to the discussion, either in the comments here or elsewhere on the net.  You made a positive difference in this world.  Take pride in that, for it is the most important thing any of us can do.

A Question of Degree

I recently found myself asked for advice, which feels odd even at the best of times, and this was (it seemed to me) of a particularly serious nature.  I’m curious to know what you think is the proper answer.

A few days back, I got e-mail with the following questions:

…in your opinion, how useful is a computer science degree for a career in web development? I’m a second year CS major, and considering dropping out because I don’t see the value in it anymore. It’s just taking away my time from learning and doing what I love most–developing web apps. Will dropping out hurt me later on?

I chewed on it for a day or so and then ended up writing the following in response:

I wish I could give you a definitive answer, but the honest truth is that I’m conflicted.  I’m not the only one, either: a recent survey of 26,000+ web professionals indicated that just over half felt their education had some relevance to what they do (http://aneventapart.com/alasurvey2009/#roe).

To use myself as an example, I got my degree (in History, as it happens), but that was before there was such a thing as a career in web development.  The same is true for a lot of the people I think of as contemporary to me; that is, people about my age.  Almost none of them have CS degrees, and many don’t have degrees at all.  I got my job as webmaster of a respected research school because I worked there already and nobody else had ever heard of the web.  I doubt very much that, were I just now exiting school and entering the market, I could do anything like that.

On the other hand, I will say that in the computer field in general, and web in particular, very few people seem to care what degree you do or don’t have.  But here’s the rub: these days, it might be that having a CS degree is what gets you that first job or two.

On the other other hand, if you build some killer web apps, nobody will care about your schooling.  They’ll care about your portfolio.  I don’t know if that lies in front of you, of course.  Maybe it does.  Or maybe it’s a good idea to finish schooling so that you’ll be paper qualified for jobs that say “Requires CS degree or equivalent” if you need to seek them out.

So, to get back to your original question, “It is unless it isn’t” is about the best I can do.  As someone who values education very highly and knows a degree can be an asset in job-seeking, my instinct is to tell you to finish your degree.  As someone who has a lot of contact with successful people who didn’t do that, my intellect requires me to say it’s not critical.

A day past when I sent it, I still don’t feel any less torn.  (And in re-reading what I wrote, I can see my indecision in the writing: scattered, whipping from one side to the other.  Man, did that one ever need an editor!)  I don’t really need to know what people think of what I said, but I’m really curious to know what you would advise this young person.  Leave your thoughts in the comments, if you please, and I’ll make sure word of your input gets passed along to the student who wrote me.  Thanks!

Addendum 12 Nov 10: please see “Degree of Influence” to see how things turned out.

Digging in the Mud

There’s something about the Diggbroglio that has left me scratching my head:  how is it that so many people are up in arms about the DiggBar when they’ve had nothing to say about the framing bars of StumbleUpon, FaceBook, etc. etc.?

Now, please note that I’m not saying the DiggBar, or any other framing bar, is cool and we should all love it.  I’m not.  I absolutely, completely, totally get all the reasons why framing bars are bad for breaking bookmarking and navigating and search engines and copyright and hijacking content and so on.  But that’s precisely why I’m so confused, because we’ve known for years now that framing bars are bad mojo—and yet StumbleUpon, for example, is based on bars.  There is a browser extension/plugin StumbleUpon thingy you can install, but there’s also a web-based framing bar thing (see this link, for example) that they offer, and I bet people use.  You don’t have to be a member to use it: I hit that link in a browser that allows cross-site frame loading and I get the bar and the page it’s framing, and I’ve never been a StumbleUpon member.  The source shows it’s using iframes to make it happen.  So far as I can tell, it’s not really different from the DiggBar.

So why do we have people writing JavaScript and PHP and Ged-knows-what-else that specifically busts out of the DiggBar framing, instead of busting out of all framing?  After all, site framing is universally agreed to be objectionable; even yet-to-be-discovered life forms orbiting distant stars think it’s a bad idea.  So why is one instance of it being targeted while the rest are tolerated?  Why are we all not just using if (top != self) {top.location.replace(self.location.href);} and other-language equivalents?  Yes, I know, some of you do just that, but why isn’t everyone?

Perhaps because I have yet to eradicate a stubborn streak of faith in the rationality of my peers, I assume that there’s some technical difference here that I’m missing and that, once understood, would let me understand the source of the outcry.  So can someone please explain to me, or point at an explanation that states, the technical ways in which the DiggBar is worse enough than already-extant framing bars that it’s triggered this outrage?  Again, nobody has to enumerate the complete list of the DiggBar’s sins; I understand.  A list of any different and more egregious sins would be just fine, though.

Also, if anyone comes up with a way to bust out of the frames while still preserving the bar—that is, correcting the problems framing bars cause while preserving their functionality for the people who want to use them—that would be extra-cool.  After all, people who use those services like the bars.  If we could let them browse the web the way they prefer while fixing bookmark/SEO/etc. problems framing bars can cause, that would be a win all the way around.

Update 14 Apr 09: looks like Porter‘s trying to keep the bar without the framing.

Update 16 Apr 09: in his post about Digg changing the way the DiggBar will work, John Gruber lists (by way of quoting Digg VP John Quinn’s post about it) the two things that made the DiggBar extra-objectionable (at least in his eyes).  Thanks, John!

Time and Motion

I was reading an article on cosmology, as I am sometimes wont to do, and it brought back to me one of those questions that I’ve had for a while now, concerning the redshifting of light from distant galaxies as it relates to the history and expansion of the universe.

For those of you not familiar with this topic, the general idea here is that when we look at galaxies outside our own, the light they give off is shifted toward the redder end of the electromagnetic spectrum, which means the wavelengths are getting longer.  According to our present understanding of physics, the simplest explanation for this observation that the further away a galaxy is, the faster it is receding from us—thus redshifting the light it gives off, thanks to the Doppler effect.  It turns out that the amount of redshifting is directly and linearly proportional to the distance of the galaxy, a ratio named the Hubble constant in honor of Edwin Hubble, the man who first made this observation.  (He’s also the namesake of the Hubble Space Telescope, of course.)

It seems to me that this explanation  either overlooks or glosses over one kind of important point: we don’t see those galaxies as they are right now.  In fact, we’re seeing them as they were in the past, and the further out we look, the further back in time we’re looking.  If a galaxy is a five million light-years distant, then we see it as it was five million years ago.  Double the distance, and double the amount of time involved, which would seem to mean that greater redshifts are as much a product of how far back in time we’re looking as they are distance.

So why is it that distance is regarded as the primary factor here?  Why don’t we assume that the universe’s expansion is actually slowing down, given that the closer things are (and therefore the more recent they are), the less quickly they’re receding, whereas the really distant (and therefore much, much older) galaxies were receding more quickly back then?

I’ve no doubt this has been explained one way or another by people way smarter than me, but some Googling yielded no decent results—just about everything I came up with challenged the Hubble constant on various and sundry grounds, not all of them sensical (at least to me).  Nothing I found addressed this specifically.  Though I figure the explanation is straightforward enough, I don’t seem to be using the right search terms to find it.  Anyone got any help for me here?

August 2014
SMTWTFS
July  
 12
3456789
10111213141516
17181920212223
24252627282930
31  

Archives

Feeds

Extras